Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 322083 - Lexer matches print'(a)',' ...' incorrectly
Summary: Lexer matches print'(a)',' ...' incorrectly
Status: NEW
Alias: None
Product: PTP
Classification: Tools
Component: Photran.For Internal Use (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P5 normal (vote)
Target Milestone: ---   Edit
Assignee: Photran Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-08-08 11:56 EDT by Maarten Becker CLA
Modified: 2011-03-18 00:05 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Maarten Becker CLA 2010-08-08 11:56:05 EDT
Build Identifier: 20100617-1415

The error appears if there is no blank between print statemtent and the format:

Example:
print'(a)',' Hello'

Error: Unexpected character constant ...


But print* (without blank) is working

Reproducible: Always
Comment 1 Jeffrey Overbey CLA 2011-03-17 12:44:28 EDT
Thanks for the bug report.

Internally, the problem seems to be that the lexer is matching the rule
    {Ident}?"'"
which is intended to match string literals with a kind, e.g.,
    ascii_'This is a string'

I don't see an immediate/easy way to fix this, but I'm keeping this open so we can come back to it later...