Opened 5 years ago

Last modified 2 years ago

#17485 new defect

Comment // at end of file causes error 307 in build

Reported by: NJM-Goals Owned by:
Priority: undecided Milestone: 1.15
Component: BuildSystem Version: 1.9.1
Keywords: Cc:
Blocked By: Blocking:

Description

A comment at the end of a file causes error 307. error(307) Failed to evaluate module tagged as pure AMD (fell back to processing with regular expressions). module: xxx/yyy; error: SyntaxError?: missing } after function body

It doesn't matter if the comment is directly behind the semicolon of a define call or in a separate line. A comment with /* */ does not cause this error. A new line behind the last prevents this error. The text " any comment" (without quotation marks) also causes this error.

Reproduceable with Dojo Boilerplate (https://github.com/csnover/dojo-boilerplate) with a at the end of Dialog.js (attached)

Attachments (1)

Dialog.js (387 bytes) - added by NJM-Goals 5 years ago.
Dialog.js from Dojo Boilerplate with a comment at the end that causes the Build System to print error 307

Download all attachments as: .zip

Change History (5)

Changed 5 years ago by NJM-Goals

Attachment: Dialog.js added

Dialog.js from Dojo Boilerplate with a comment at the end that causes the Build System to print error 307

comment:1 Changed 5 years ago by NJM-Goals

Corrected Description:

It doesn't matter if the comment is directly behind the semicolon of a define call or in a separate line. A comment with /* */ does not cause this error. A new line behind the last // prevents this error. The text "// any comment" (without quotation marks) also causes this error.

Reproduceable with Dojo Boilerplate (​https://github.com/csnover/dojo-boilerplate) with a // at the end of Dialog.js (attached)

comment:2 Changed 5 years ago by xorfacx

still present in 1.9.3

comment:3 Changed 3 years ago by dylan

Milestone: tbd1.12

comment:4 Changed 2 years ago by dylan

Milestone: 1.131.15

Ticket planning... move current 1.13 tickets out to 1.15 to make it easier to move tickets into the 1.13 milestone.

Note: See TracTickets for help on using tickets.