This will take some time to fix. This has been broken for a while. It started in 1.87 but it didn't cause a syntax error until 1.90. It's still present in 2.3. I'm not sure why it went away and came back recently during this development cycle.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
This turned out to be a lot easier to fix than I thought. I have a fix here: https://github.com/IOBYTE/cppcheck/tree/Martin but it will conflict with an uncommitted PR so I will wait for it to be committed first.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
the latest cppcheck creates a new syntax error.
old commit: f48e195c31f8f7de60826036f2fc797c9e7f942c (working)
new commit: d3d2e16137dccf9269f1f2d017606be24ab31d39 (syntax error)
The code is:
The message is:
21-02-10.cpp:1:42: error: syntax error [syntaxError]
auto operator<<(std::ostream &s, const Pr<st> p) -> std::ostream &
^</st>
Could you please check?
Thanks,
Martin
I'll look into it.
This will take some time to fix. This has been broken for a while. It started in 1.87 but it didn't cause a syntax error until 1.90. It's still present in 2.3. I'm not sure why it went away and came back recently during this development cycle.
I created a ticket here: https://trac.cppcheck.net/ticket/10173
This turned out to be a lot easier to fix than I thought. I have a fix here: https://github.com/IOBYTE/cppcheck/tree/Martin but it will conflict with an uncommitted PR so I will wait for it to be committed first.