This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | /*/ wrongly colored as RE | ||
---|---|---|---|
Product: | javascript | Reporter: | Martin Schovanek <mschovanek> |
Component: | Editor | Assignee: | Torbjorn Norbye <tor> |
Status: | VERIFIED FIXED | ||
Severity: | blocker | CC: | pjiricka |
Priority: | P3 | ||
Version: | 6.x | ||
Hardware: | All | ||
OS: | All | ||
Issue Type: | DEFECT | Exception Reporter: |
Description
Martin Schovanek
2007-11-06 10:12:53 UTC
I am no sure about your evaluation. Parser have the same opinion, type in a .js: var x=/*/; and run it. Scripting Engine throws: 'Unterminated comment in ....' error /*/ should be really interpreted as an unfinished comment (Idea and Aptana parse it in this way); regexp in JavaScript sample fixed /cvs/scripting/javascript/src/org/netbeans/modules/languages/javascript/JavaScriptExample.js,v <-- JavaScriptExample.js new revision: 1.3; previous revision: 1.2 Still reproducible in NB 6.1 build 682. I can't reproduce this. Petr, can you show me your entire source file? If I have just "/*/" in the source file it's shown as an error (along with a parser error message). If I have var x=/*/; as also shown in this bug, I also get the same. I have the same behavior. But the question is whether unfinished comments should be gray (as finished comments are), or whether they should be black. I thought the issue complained about /*/ not being gray. But perhaps that is not the desired behavior and the current behavior is correct. Feel free to close if you think there is no bug. I think the bug was that in 6.0 the editor failed to recognize /*/ as an error, it was shown as a valid regular expression. This is no longer the case. I'm not sure that we should show /*/ as a comment since it's not a valid comment. V. |