X3 skipper in separate translation unit issue

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

X3 skipper in separate translation unit issue

Orient
I implemented grammar (include/insituc/parser/grammar.hpp, include/insituc/parser/implementation/grammar.hpp) and skipper grammar (include/insituc/parser/skipper.hpp, include/insituc/parser/implementation/skipper.hpp) in separate translation units (repository, compiler: clang++ -stdlib=libc++ -std=gnu++1z, version 3.6 (maybe 3.5 workable too) and libc++, Qt needed for qmake only at the moment). All of this looks correct, and grammar works correctly (src/tst/runtime/jit_compiler/jit_compiler.pro passes all the tests, but without comments in source files).
But if I add comments to input (test/cases/*.txt), then parsing failed (somewhere into Boost.Spirit X3).
What is wrong? I can't find the source of the errors.
Reply | Threaded
Open this post in threaded view
|

Re: X3 skipper in separate translation unit issue

Orient
I found the solution. x3::char_ - "*/" does not works as intended (just copied from Boost.Spirit V2 source). I replaced with x3::char_ - (x3::char_('*') | x3::char_('/')) and now all working correct.
Reply | Threaded
Open this post in threaded view
|

Re: X3 skipper in separate translation unit issue

TONGARI J
2014-10-02 18:25 GMT+08:00 Orient <[hidden email]>:
I found the solution. x3::char_ - "*/" does not works as intended (just
copied from Boost.Spirit V2 source). I replaced with x3::char_ -
(x3::char_('*') | x3::char_('/')) and now all working correct.

That seems strange to me, even in Qi, "*/" is not the same as char_("*/"), which you intended.

------------------------------------------------------------------------------
Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer
Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS Reports
Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper
Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer
http://pubads.g.doubleclick.net/gampad/clk?id=154622311&iu=/4140/ostg.clktrk
_______________________________________________
Spirit-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/spirit-general
Reply | Threaded
Open this post in threaded view
|

Re: X3 skipper in separate translation unit issue

Orient
It may well be that in Qi version it was qi::char_ - qi::char_("*/"), but
x3::char_("*/") was not allowed, when I migrating the code from Qi to X3.
What means qi::char_ - "*/" I don't know though.



--
View this message in context: http://boost.2283326.n4.nabble.com/X3-skipper-in-separate-translation-unit-issue-tp4668070p4668120.html
Sent from the spirit-general mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer
Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS Reports
Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper
Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer
http://pubads.g.doubleclick.net/gampad/clk?id=154622311&iu=/4140/ostg.clktrk
_______________________________________________
Spirit-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/spirit-general
Reply | Threaded
Open this post in threaded view
|

Re: X3 skipper in separate translation unit issue

Orient
In reply to this post by TONGARI J
It may well be that in Qi version it was qi::char_ - qi::char_("*/"), but x3::char_("*/") was not allowed, when I migrating the code from Qi to X3. What means qi::char_ - "*/" I don't know though.
TONGARI J wrote
2014-10-02 18:25 GMT+08:00 Orient <[hidden email]>:

> I found the solution. x3::char_ - "*/" does not works as intended (just
> copied from Boost.Spirit V2 source). I replaced with x3::char_ -
> (x3::char_('*') | x3::char_('/')) and now all working correct.
>

That seems strange to me, even in Qi, "*/" is not the same as char_("*/"),
which you intended.

------------------------------------------------------------------------------
Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer
Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS Reports
Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper
Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer
http://pubads.g.doubleclick.net/gampad/clk?id=154622311&iu=/4140/ostg.clktrk
_______________________________________________
Spirit-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/spirit-general