-
-
Notifications
You must be signed in to change notification settings - Fork 6.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unexpected '\"' in middle of array #564
Comments
I cannot reproduce the error with the #include "json.hpp"
using json = nlohmann::json;
int main() {
std::string s = R"({"a":["fRKEOtRT-etHJOG-lcpJs","MGCHDafQ-LPEXCa-pCeKa","VqjmMLkX-kUShAJ-mcVOp","yuGaeMEF-dVuIMc-TOVt","JdSUVsXx-WUwiIa-HMRH","BkOjJqiu-TKweln-bPFCi","GEkNLxVo-QnHWvT-IbHoc","uKBPcJvW-MOVVpM-kyHrA","iBAlBhsE-allRcH-uqVyK","LwegSOiP-rgUozo-KnoPs","JBxqhpmF-VLGdvg-cxGG¦","hFdrSaBY-eXmTXi-NxFnF","jBfFVOMr-OOceYr-HxsKD","WbQpuAjS-iuTQyq-ddblf","jcSMtECx-LuNWfK-amqw","FiRVJpCQ-MbCvVg-WerPS","TTSDDSpI-slmIQR-frLlD","EGptPBVe-ISUDM0-lrKQO","HLImGoSu-EuxWNn-PPRum","nWUhJxjV-rTQRUy-aMWhe","TaqJPuWi-RMMJuN-xm0","ekLfFogT-STNktZ-XW0I","BDkNQNIG-AdswHQ-ulmdK","FKlKOVEP-IKJhd¦-eVMH","bKmsUMWp-JCqXtu-Hdhaw","emjvdmif-ITPENH-OytDK","FnrqvslC-WqVUXy-vcBAO","HSumNLLh-kLoqBT-TkuSS","wJBfCwwj-JKmjFa-WCSAc","tsOngmgX-jbEKHt-jvpUS","EbBRCEPs-QStfKn-AGZsM","JIhwKSGZ-TTmUgO-eJlT¦","vGeRUFPb-SXtdDP-hhbiJ","uhqsMroN-oleCps-xwboT","AnwMcNWw-aBtGsC-UPvSy"],"b":"VIbiLEW¦-nIlfGi-HQFW","c":["QFAkxppA-PcIvtc-MQdGQ"],"d":"Vwoweowjawe","e":"AEVsRDLK-obRNar-FrTn","f":"","g":0,"h":0})";
auto j = json::parse(s);
std::cout << j << std::endl;
} |
(The same holds true for the |
Thank you for your quick reply! Copying the code gives me the same error. I'm using the current version of the library. My project is build in Visual Studio 2015 (v140). I will check my setup and close the issue. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm trying to parse a string containing json, but it throws an error in the middle of an array of strings (it throws it at position 245). Any json lint tells me the json is correct.
{"a":["fRKEOtRT-etHJOG-lcpJs","MGCHDafQ-LPEXCa-pCeKa","VqjmMLkX-kUShAJ-mcVOp","yuGaeMEF-dVuIMc-TOVt","JdSUVsXx-WUwiIa-HMRH","BkOjJqiu-TKweln-bPFCi","GEkNLxVo-QnHWvT-IbHoc","uKBPcJvW-MOVVpM-kyHrA","iBAlBhsE-allRcH-uqVyK","LwegSOiP-rgUozo-KnoPs","JBxqhpmF-VLGdvg-cxGG¦","hFdrSaBY-eXmTXi-NxFnF","jBfFVOMr-OOceYr-HxsKD","WbQpuAjS-iuTQyq-ddblf","jcSMtECx-LuNWfK-amqw","FiRVJpCQ-MbCvVg-WerPS","TTSDDSpI-slmIQR-frLlD","EGptPBVe-ISUDM0-lrKQO","HLImGoSu-EuxWNn-PPRum","nWUhJxjV-rTQRUy-aMWhe","TaqJPuWi-RMMJuN-xm0","ekLfFogT-STNktZ-XW0I","BDkNQNIG-AdswHQ-ulmdK","FKlKOVEP-IKJhd¦-eVMH","bKmsUMWp-JCqXtu-Hdhaw","emjvdmif-ITPENH-OytDK","FnrqvslC-WqVUXy-vcBAO","HSumNLLh-kLoqBT-TkuSS","wJBfCwwj-JKmjFa-WCSAc","tsOngmgX-jbEKHt-jvpUS","EbBRCEPs-QStfKn-AGZsM","JIhwKSGZ-TTmUgO-eJlT¦","vGeRUFPb-SXtdDP-hhbiJ","uhqsMroN-oleCps-xwboT","AnwMcNWw-aBtGsC-UPvSy"],"b":"VIbiLEW¦-nIlfGi-HQFW","c":["QFAkxppA-PcIvtc-MQdGQ"],"d":"Vwoweowjawe","e":"AEVsRDLK-obRNar-FrTn","f":"","g":0,"h":0}
Any idea what's going on? Any help is appreciated :)
Kind regards,
Nick
The text was updated successfully, but these errors were encountered: