Project Home
Project Home
Trackers
Trackers
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - C++14 Digit Separators flagged by Eclipse: (3 Items)
   
C++14 Digit Separators flagged by Eclipse  
We're building using qcc with C++14 features turned on. Everything works pretty well, but there is one annoyance.

The Momentics IDE still flags the use of digit separators as a syntax error.

So, for example, this line:

        verify_compiler<uint32_t> ( 0, 10, 0xFFFF'FFFFU );

Which compiles just fine and works as intended, gets an ugly yellow question mark in the IDE, with the flag "Bad 
character sequence encountered: 'FFFU'.

AFAICT, this is because the eclipse IDE has a built-in C++ parser, and tht is what is used by Momentics for validation.

This appears to have been fixed in Eclipse, although fairly recently:

https://bugs.eclipse.org/bugs/show_bug.cgi?id=519062

My questions: 1) is there a workaround to make just this one problem disappear? 2) Is there a Momentics update that 
makes this go away.

Maybe you have an answer 3) Configuration that does proper parsing as is, but I'm guessing that question is unanswerable
.

I'm using Version: 7.0.3.v201804261557 of Momentics. We're open to upgrading, but not unless we know this is fixed.

-Mark
Re: C++14 Digit Separators flagged by Eclipse  
It would not be possible to configure current parser to ignore this is 
this is major syntax incompatibly, it will be fixed in next major 
version of Momentics
but I cannot comment now when it will be available. I suggest not to use 
this feature as it will break internal parsing which will affect syntax 
highlighting AND indexing of source code
for purposes of navigation, refactoring, etc


On 2019-06-07 1:52 p.m., Mark Nelson wrote:
> We're building using qcc with C++14 features turned on. Everything works pretty well, but there is one annoyance.
>
> The Momentics IDE still flags the use of digit separators as a syntax error.
>
> So, for example, this line:
>
>          verify_compiler<uint32_t> ( 0, 10, 0xFFFF'FFFFU );
>
> Which compiles just fine and works as intended, gets an ugly yellow question mark in the IDE, with the flag "Bad 
character sequence encountered: 'FFFU'.
>
> AFAICT, this is because the eclipse IDE has a built-in C++ parser, and tht is what is used by Momentics for validation
.
>
> This appears to have been fixed in Eclipse, although fairly recently:
>
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=519062
>
> My questions: 1) is there a workaround to make just this one problem disappear? 2) Is there a Momentics update that 
makes this go away.
>
> Maybe you have an answer 3) Configuration that does proper parsing as is, but I'm guessing that question is 
unanswerable.
>
> I'm using Version: 7.0.3.v201804261557 of Momentics. We're open to upgrading, but not unless we know this is fixed.
>
> -Mark
>
>
>
> _______________________________________________
>
> General
> http://community.qnx.com/sf/go/post119745
> To cancel your subscription to this discussion, please e-mail general-ide-unsubscribe@community.qnx.com


Re: C++14 Digit Separators flagged by Eclipse  
> It would not be possible to configure current parser to ignore this is 
> this is major syntax incompatibly, it will be fixed in next major 
> version of Momentics
> but I cannot comment now when it will be available. I suggest not to use 
> this feature as it will break internal parsing which will affect syntax 
> highlighting AND indexing of source code
> for purposes of navigation, refactoring, etc

Definitely not the response I want to hear! C++14 is five years old, it's kind of discouraging to hear that the IDE 
needs a major release to pick up on this small feature. Worse yet that using it is going to break other features in 
Momentics. SIgh.

-Mark