Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: autotest/abprewrite_source.js

Issue 5417063522762752: Issue 427 - Desugar arrow functions to normal or bound functions (Closed)
Patch Set: I just decided to ignore eval and Function for now, I can open a new bug if we really want to ban t… Created May 18, 2014, 10:55 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | autotest/test_abprewrite.js.expected » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: autotest/abprewrite_source.js
===================================================================
--- a/autotest/abprewrite_source.js
+++ b/autotest/abprewrite_source.js
@@ -31,19 +31,19 @@ for (let [a, b] of fooList)
}
for (let [a, b] of fooList);
for (k of fooList)
alert(k);
-let a = function() 1;
+let a = function() { return 1 };
let b = {
- get foo() 1
+ get foo() { return 1; }
};
if (a == b)
foo();
else if (a == c)
bar();
else
bas();
@@ -70,8 +70,13 @@ function genFunc()
}
var a = function()
{
for (var i = 0; i < 10; i++)
{
yield i;
}
};
+
+let x = (y) => y + 1;
+x = y => y + 1;
+x = (a, b) => this[a] + b;
+x = (a, b) => { return () => 1; }
« no previous file with comments | « no previous file | autotest/test_abprewrite.js.expected » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld