Community
Participate
Working Groups
Build Identifier: LR parser doesn't support some C++ 0x features yet, but its test suite inherits all of test cases from CDT core parser test suite, so we need to override these unsupported test cases for now. Reproducible: Always
Created attachment 181857 [details] Applied to org.eclipse.cdt.core.lrparser.tests in head stream
*** Bug 335250 has been marked as a duplicate of this bug. ***
Created attachment 187532 [details] This patch includes the above 181857 attached patch Applied to org.eclipse.cdt.core.lrparser.tests in head stream
Created attachment 187538 [details] Patch applied to 702 stream Patch applied to 702 stream
I've committed the patches to nobble the tests. Are you responsible for the XLC tests as well?
*** cdt cvs genie on behalf of jblackburn *** Bug 328867 - Override some C++ 0x test cases in LR parser test suite in head stream [*] LRTests.java 1.16 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.tests/src/org/eclipse/cdt/core/lrparser/tests/LRTests.java?root=Tools_Project&r1=1.15&r2=1.16 [*] LRTemplateTests.java 1.9 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.tests/src/org/eclipse/cdt/core/lrparser/tests/LRTemplateTests.java?root=Tools_Project&r1=1.8&r2=1.9 [*] LRCPPSpecTest.java 1.12 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.tests/src/org/eclipse/cdt/core/lrparser/tests/LRCPPSpecTest.java?root=Tools_Project&r1=1.11&r2=1.12 [*] LRCPPTests.java 1.12 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.tests/src/org/eclipse/cdt/core/lrparser/tests/LRCPPTests.java?root=Tools_Project&r1=1.11&r2=1.12 [*] LRCPPTests.java 1.11.2.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.tests/src/org/eclipse/cdt/core/lrparser/tests/LRCPPTests.java?root=Tools_Project&r1=1.11&r2=1.11.2.1
(In reply to comment #5) > I've committed the patches to nobble the tests. > Are you responsible for the XLC tests as well? Thanks James, for checking the patch in. It covers the XLC tests as well.
Great that's made a big difference! A few still remain: https://hudson.eclipse.org/hudson/job/cdt-nightly/lastCompletedBuild/testReport/
(In reply to comment #8) > Great that's made a big difference! A few still remain: > https://hudson.eclipse.org/hudson/job/cdt-nightly/lastCompletedBuild/testReport/ Hmm... It passed all tests in my workspace.. I will take a look at it tomorrow.
(In reply to comment #9) > (In reply to comment #8) > > Great that's made a big difference! A few still remain: > > https://hudson.eclipse.org/hudson/job/cdt-nightly/lastCompletedBuild/testReport/ > Hmm... It passed all tests in my workspace.. I will take a look at it tomorrow. Because I have just caused a junit-failure, I came accross the remaining failures in the LR-parser test. They are due to a failling assertion. To see it you need to enable assertions using the option -ea. The particular assertion shall help to detect cases where the parser attempts to compute the string-representation for a template-id. However, this is ok when used for reporting a problem-binding, I have changed org.eclipse.cdt.core.lrparser.tests.ParseHelper accordingly.
(In reply to comment #10) > (In reply to comment #9) > > (In reply to comment #8) > > > Great that's made a big difference! A few still remain: > > > https://hudson.eclipse.org/hudson/job/cdt-nightly/lastCompletedBuild/testReport/ > > Hmm... It passed all tests in my workspace.. I will take a look at it tomorrow. > Because I have just caused a junit-failure, I came accross the remaining > failures in the LR-parser test. They are due to a failling assertion. To see it > you need to enable assertions using the option -ea. > The particular assertion shall help to detect cases where the parser attempts > to compute the string-representation for a template-id. However, this is ok > when used for reporting a problem-binding, I have changed > org.eclipse.cdt.core.lrparser.tests.ParseHelper accordingly. I still can't see these failures in my workspace. Is it because I didn't enable assertion option -ea? How can I enable this option?
(In reply to comment #11) > (In reply to comment #10) > > (In reply to comment #9) > > > (In reply to comment #8) > > > > Great that's made a big difference! A few still remain: > > > > https://hudson.eclipse.org/hudson/job/cdt-nightly/lastCompletedBuild/testReport/ > > > Hmm... It passed all tests in my workspace.. I will take a look at it tomorrow. > > Because I have just caused a junit-failure, I came accross the remaining > > failures in the LR-parser test. They are due to a failling assertion. To see it > > you need to enable assertions using the option -ea. > > The particular assertion shall help to detect cases where the parser attempts > > to compute the string-representation for a template-id. However, this is ok > > when used for reporting a problem-binding, I have changed > > org.eclipse.cdt.core.lrparser.tests.ParseHelper accordingly. > I still can't see these failures in my workspace. Is it because I didn't enable > assertion option -ea? How can I enable this option? I guess I see the reasons. The test failures James mentioned from yesterday afternoon build maybe because of the delay of cdt cvs code checking in, my patch was not in cvs yet when the build started. The test failure Markus mentioned is a new one and has been fixed in XLC parser helper class by Markus. There is one xlc parser failure left in the latest build, but it is passed in my workspace. Let's see next build if we can resolve all these xlc parser failures.
-ea is a VM argument you can pass it to the JVM in the launch configuration.
Created attachment 187864 [details] patch to fix the last LR test failures, for Head stream I see the problem, '#' is not a legal token in LR parser but is a valid token in GNU parser, when LR parser tries to map it, the token mapper asserts false for an invalid token (#), the AssertionError is caught by the test. To get around of it, I add a catch block in the test case to bypass this false alarm.
(In reply to comment #14) > I see the problem, '#' is not a legal token in LR parser but is a valid token > in GNU parser, when LR parser tries to map it, the token mapper asserts false > for an invalid token (#), the AssertionError is caught by the test. > > To get around of it, I add a catch block in the test case to bypass this false > alarm. How is this a false alarm? If the scanner is returning this token then the parser needs to deal with it somehow. Is this not a real issue that needs to be fixed?
(In reply to comment #15) > (In reply to comment #14) > > I see the problem, '#' is not a legal token in LR parser but is a valid token > > in GNU parser, when LR parser tries to map it, the token mapper asserts false > > for an invalid token (#), the AssertionError is caught by the test. > > > > To get around of it, I add a catch block in the test case to bypass this false > > alarm. > How is this a false alarm? If the scanner is returning this token then the > parser needs to deal with it somehow. Is this not a real issue that needs to be > fixed? LR parsers have dealt with '#', but just treat it as an invalid token. This is because LR parsers reuse GNU parser's preprocessor to handle the preprocessing. The reason why the test case is failed because DOMToGPPTokenMap asserts 'false' when it sees an unknown GNU token, like '#', I guess this is a special case which is not considered well by the mapper - it should not be so assertive for this case actually. I will create another patch to update DOMToGPPTokenMap by removing the assert call for '#', like: case tPOUND : return TK_Invalid; default: assert false : "token not recognized by the GPP parser: " + token.getType(); //$NON-NLS-1$ return TK_Invalid; Please let me know if you think this is a better solution. Mike: can you please also see if this fix is reasonable?
Created attachment 187876 [details] The patch I mentioned, apply to Head stream
(In reply to comment #17) > Created attachment 187876 [details] > The patch I mentioned, apply to Head stream Talked with Mike, He agreed with the fix in the above patch.
Created attachment 188087 [details] Token map fix patch to 70 stream
Thanks John I've applied your latest patches to HEAD and cdt_7_0
Created attachment 188451 [details] patch applied to token maps of isocpp and xlc parser
Comment on attachment 188451 [details] patch applied to token maps of isocpp and xlc parser Applied patch to cdt_7_0 and HEAD. Thanks John. Also updated copyright year.
*** cdt cvs genie on behalf of vkong *** Bug 328867 for John Liu [*] DOMToISOCPPTokenMap.java 1.6.4.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser/src/org/eclipse/cdt/core/dom/lrparser/cpp/DOMToISOCPPTokenMap.java?root=Tools_Project&r1=1.6&r2=1.6.4.1 [*] XlcCPPTokenMap.java 1.5.2.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/xlc/org.eclipse.cdt.core.lrparser.xlc/parser/org/eclipse/cdt/core/lrparser/xlc/XlcCPPTokenMap.java?root=Tools_Project&r1=1.5&r2=1.5.2.1 [*] feature.xml 1.7.2.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.feature/feature.xml?root=Tools_Project&r1=1.7&r2=1.7.2.1 [*] MANIFEST.MF 1.13.4.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser/META-INF/MANIFEST.MF?root=Tools_Project&r1=1.13&r2=1.13.4.1 [*] MANIFEST.MF 1.4.6.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/xlc/org.eclipse.cdt.core.lrparser.xlc/META-INF/MANIFEST.MF?root=Tools_Project&r1=1.4&r2=1.4.6.1 [*] feature.xml 1.9 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.feature/feature.xml?root=Tools_Project&r1=1.8&r2=1.9 [*] MANIFEST.MF 1.14 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser/META-INF/MANIFEST.MF?root=Tools_Project&r1=1.13&r2=1.14 [*] DOMToISOCPPTokenMap.java 1.7 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser/src/org/eclipse/cdt/core/dom/lrparser/cpp/DOMToISOCPPTokenMap.java?root=Tools_Project&r1=1.6&r2=1.7 [*] MANIFEST.MF 1.5 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/xlc/org.eclipse.cdt.core.lrparser.xlc/META-INF/MANIFEST.MF?root=Tools_Project&r1=1.4&r2=1.5 [*] XlcCPPTokenMap.java 1.6 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/xlc/org.eclipse.cdt.core.lrparser.xlc/parser/org/eclipse/cdt/core/lrparser/xlc/XlcCPPTokenMap.java?root=Tools_Project&r1=1.5&r2=1.6 [*] feature.xml 1.4.2.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.sdk.feature/feature.xml?root=Tools_Project&r1=1.4&r2=1.4.2.1 [*] feature.xml 1.7 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.sdk.feature/feature.xml?root=Tools_Project&r1=1.6&r2=1.7 [*] DOMToGPPTokenMap.java 1.6 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser/src/org/eclipse/cdt/core/dom/lrparser/gnu/DOMToGPPTokenMap.java?root=Tools_Project&r1=1.5&r2=1.6 [*] DOMToGPPTokenMap.java 1.5.6.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser/src/org/eclipse/cdt/core/dom/lrparser/gnu/DOMToGPPTokenMap.java?root=Tools_Project&r1=1.5&r2=1.5.6.1
*** cdt cvs genie on behalf of vkong *** Bug 328867 for John Liu [*] DOMToISOCPPTokenMap.java 1.6.4.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser/src/org/eclipse/cdt/core/dom/lrparser/cpp/DOMToISOCPPTokenMap.java?root=Tools_Project&r1=1.6&r2=1.6.4.1 [*] XlcCPPTokenMap.java 1.5.2.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/xlc/org.eclipse.cdt.core.lrparser.xlc/parser/org/eclipse/cdt/core/lrparser/xlc/XlcCPPTokenMap.java?root=Tools_Project&r1=1.5&r2=1.5.2.1 [*] feature.xml 1.7.2.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.feature/feature.xml?root=Tools_Project&r1=1.7&r2=1.7.2.1 [*] MANIFEST.MF 1.13.4.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser/META-INF/MANIFEST.MF?root=Tools_Project&r1=1.13&r2=1.13.4.1 [*] MANIFEST.MF 1.4.6.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/xlc/org.eclipse.cdt.core.lrparser.xlc/META-INF/MANIFEST.MF?root=Tools_Project&r1=1.4&r2=1.4.6.1 [*] feature.xml 1.9 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.feature/feature.xml?root=Tools_Project&r1=1.8&r2=1.9 [*] MANIFEST.MF 1.14 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser/META-INF/MANIFEST.MF?root=Tools_Project&r1=1.13&r2=1.14 [*] DOMToISOCPPTokenMap.java 1.7 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser/src/org/eclipse/cdt/core/dom/lrparser/cpp/DOMToISOCPPTokenMap.java?root=Tools_Project&r1=1.6&r2=1.7 [*] MANIFEST.MF 1.5 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/xlc/org.eclipse.cdt.core.lrparser.xlc/META-INF/MANIFEST.MF?root=Tools_Project&r1=1.4&r2=1.5 [*] XlcCPPTokenMap.java 1.6 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/xlc/org.eclipse.cdt.core.lrparser.xlc/parser/org/eclipse/cdt/core/lrparser/xlc/XlcCPPTokenMap.java?root=Tools_Project&r1=1.5&r2=1.6
*** cdt cvs genie on behalf of vkong *** Bug 328867 update plugin/feature versions [*] feature.xml 1.4.2.1 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.sdk.feature/feature.xml?root=Tools_Project&r1=1.4&r2=1.4.2.1 [*] feature.xml 1.7 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.sdk.feature/feature.xml?root=Tools_Project&r1=1.6&r2=1.7
*** cdt cvs genie on behalf of vkong *** Bug 328867 update plugin/feature versions [*] buildsite.xml 1.38.2.7 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/all/org.eclipse.cdt.releng/buildsite.xml?root=Tools_Project&r1=1.38.2.6&r2=1.38.2.7 [*] buildsite.xml 1.43 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/all/org.eclipse.cdt.releng/buildsite.xml?root=Tools_Project&r1=1.42&r2=1.43
Created attachment 190795 [details] lrparsers.tests patch to overwrite some new test cases
(In reply to comment #27) > Created attachment 190795 [details] > lrparsers.tests patch to overwrite some new test cases Applied. I see there is another patch previously posted that is not marked iplog+. Did that one get committed previously? If so it should be flagged.
*** cdt cvs genie on behalf of crecoskie *** Bug 328867 - Override some C++ 0x test cases in LR parser test suite in head stream [*] LRTemplateTests.java 1.10 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.tests/src/org/eclipse/cdt/core/lrparser/tests/LRTemplateTests.java?root=Tools_Project&r1=1.9&r2=1.10 [*] LRCPPTests.java 1.14 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/lrparser/org.eclipse.cdt.core.lrparser.tests/src/org/eclipse/cdt/core/lrparser/tests/LRCPPTests.java?root=Tools_Project&r1=1.13&r2=1.14
I don't see the test cases failing anymore, should this bug be closed?
(In reply to comment #30) > I don't see the test cases failing anymore, should this bug be closed? Agreed.