Skip to content

Commit 0c4cb30

Browse files
getting rid of excessive spaces after Class.name = "Class" assignment
1 parent 8d5f800 commit 0c4cb30

File tree

6 files changed

+8
-30
lines changed

6 files changed

+8
-30
lines changed

lib/coffee-script/lexer.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/coffee-script/nodes.js

Lines changed: 2 additions & 29 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/coffee-script/optparse.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/coffee-script/rewriter.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/coffee-script/scope.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/nodes.coffee

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -942,7 +942,8 @@ exports.Class = class Class extends Base
942942
@ensureConstructor name
943943
@body.spaced = yes
944944
@body.expressions.unshift @ctor unless @ctor instanceof Code
945-
@body.expressions.unshift new Literal "#{name}.name = '#{name}'" if decl
945+
if decl
946+
@body.expressions.unshift new Assign (new Value (new Literal name), [new Access new Literal 'name']), (new Literal "'#{name}'")
946947
@body.expressions.push lname
947948
@addBoundFunctions o
948949

0 commit comments

Comments
 (0)