Hello,
I am new in using boost and I played a little bit with the spirit library.
I tried following code using MSVC 7.1 and boost 1.30.2
#include"stdafx.h"
#include<spirit.hpp>
using namespace boost::spirit;
rule<> GetRule()
rule<> r = anychar_p;
return r;
void Parse1()
char s[] = "ABCD";
parse(s, GetRule());
void Parse2()
rule<> r = anychar_p;
char s[] = "ABCD";
parse(s,r);
int _tmain()
Parse1();
return 0;
Parse1() throws an exception (access violation)
Parse2() works correct.
Is it a compiler problem or a problem in spirit or my problem ?
Thanks