Bug 374889 - CPP language parser does not c++14 understand digit separators
Summary: CPP language parser does not c++14 understand digit separators
Status: RESOLVED NOT A BUG
Alias: None
Product: kdevelop
Classification: Applications
Component: Language Support: CPP (Clang-based) (show other bugs)
Version: 5.0.80
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: kdevelop-bugs-null
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-01-10 23:32 UTC by rjwgnr27
Modified: 2017-01-10 23:47 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description rjwgnr27 2017-01-10 23:32:49 UTC
Using C++14 digit separators, the CPP semantic analysis reports an error:

Ex:
    if ( value > 100'000'000'000'000'000ll) {
        suffix = "P";
        if (isSet(fmt, xfmt::round))
            value +=   500'000'000'000'000ll;
        value /= 1'000'000'000'000'000ll;
    } else if ( value > 100'000'000'000'000ll) {
        suffix = "T";
        if (isSet(fmt, xfmt::round))
            value +=   500'000'000'000ll;
        value /= 1'000'000'000'000ll;
    } else if ( value > 100'000'000'000ll) {

Hovering over the 'if' line, the pop-up says:
 "Problem in semantic analysis
  Location: ...
  Expected ')'..."

Hovering over the first "value += ..." I get:
 "expected ';' after expression."

Hovering over the second else-if:
  "Missing terminating ' character"
Comment 1 rjwgnr27 2017-01-10 23:47:16 UTC
Never mind, I found this as a new option under project configuration, under "Language Support", "C/C++ Parser". Setting the parser profile to C++ 14 resolves this.