Skip to content

Commit 8bc6001

Browse files
committed
Fixes #2280 -- add enumerable prototypal properties to autocompletion.
1 parent e433098 commit 8bc6001

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

lib/coffee-script/repl.js

+9-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/repl.coffee

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ completeAttribute = (text) ->
4747
val = Script.runInThisContext obj
4848
catch error
4949
return
50-
completions = getCompletions prefix, Object.getOwnPropertyNames Object val
50+
completions = getCompletions prefix, (key for key of Object(val))
5151
[completions, prefix]
5252

5353
# Attempt to autocomplete an in-scope free variable: `one`.

0 commit comments

Comments
 (0)