kazuho / picojson

a header-file-only, JSON parser serializer in C++
BSD 2-Clause "Simplified" License
1.12k stars 221 forks source link

new ( this ) value ( x ); won't compile on visual studio 2010 #64

Open v71 opened 9 years ago

v71 commented 9 years ago

new ( this ) value ( x ); this line is causing me problems, i cannot replace in any way , is the picojson supposed to work only in c++11 ? i still have visual studio 2010 , and the compiler stops with a c2059 error ( invalid token ), how can i walk aorund this problem ? thanks

kazuho commented 9 years ago

Picojson is written in / is compatible with C++03.

Looking at #29, picojson should have been compatible with MSVC 2010 after the fix for the issue was merged.

Would you mind double-checking your configuration? To me the error seems like a C++ parser issue. It might be that you are trying to include picojson.h from a non-C++ source file?

v71 commented 9 years ago

Its not a parser problem i am compiling with visual studio 2010 ( c++ ) and visual studio doesn't complain about language specifications, you can write both c and c++ source code, if this is what you mean, it simply stops at that line.Probably visual studio doesn't recognize that kind of placement new procedure. Thanks for replying

----- Original Message ----- From: Kazuho Oku To: kazuho/picojson Cc: vincenzo p. Sent: Monday, January 26, 2015 7:25 AM Subject: Re: [picojson] new ( this ) value ( x ); won't compile on visual studio 2010 (#64)

Picojson is written in / is compatible with C++03.

Looking at #29, picojson should have been compatible with MSVC 2010 after the fix for the issue was merged.

Would you mind double-checking your configuration? To me the error seems like a C++ parser issue. It might be that you are trying to include picojson.h from a non-C++ source file?

— Reply to this email directly or view it on GitHub.