mirror of
https://github.com/jashkenas/coffeescript.git
synced 2026-01-14 09:17:55 -05:00
improved test for #1436
This commit is contained in:
@@ -217,4 +217,7 @@ test "#1274: `{} = a()` compiles to `false` instead of `a()`", ->
|
||||
ok a
|
||||
|
||||
test "#1436: `for` etc. work as normal property names", ->
|
||||
doesNotThrow -> CoffeeScript.compile "foo.for = 'bar' of foo"
|
||||
obj = {}
|
||||
eq no, obj.hasOwnProperty 'for'
|
||||
obj.for = 'foo' of obj
|
||||
eq yes, obj.hasOwnProperty 'for'
|
||||
|
||||
Reference in New Issue
Block a user