diff options
author | Jo-Philipp Wich <jo@mein.io> | 2020-11-19 19:59:49 +0100 |
---|---|---|
committer | Jo-Philipp Wich <jo@mein.io> | 2020-11-19 19:59:49 +0100 |
commit | 8b4d0d5d18c0b60ed3365f442385ee253981d5d4 (patch) | |
tree | 46c209a74f1de655a22242691ea5813df304b1f3 /tests/00_syntax/19_arrow_functions | |
parent | a162cf7aadacd08eb11af072bcb9dd041866b579 (diff) |
tests: prefer `let` over `local`
Promote the use of `let` to move ucode examples closer to ES syntax.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'tests/00_syntax/19_arrow_functions')
-rw-r--r-- | tests/00_syntax/19_arrow_functions | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/00_syntax/19_arrow_functions b/tests/00_syntax/19_arrow_functions index 0d7aa7a..4847d8a 100644 --- a/tests/00_syntax/19_arrow_functions +++ b/tests/00_syntax/19_arrow_functions @@ -76,11 +76,11 @@ arrow function as method has no this: true {% obj = { method: function() { - local that = this; - local arr = () => { + let that = this; + let arr = () => { print("arrow function uses outher this: ", that == this, "\n"); }; - local fn = function() { + let fn = function() { print("normal function has own this: ", that != this, "\n"); }; |