add 'null' support to json parser
This commit is contained in:
parent
3b3407aef6
commit
637dfa66c2
@ -241,6 +241,8 @@ dv::value Parser::parseValue() {
|
|||||||
return INFINITY;
|
return INFINITY;
|
||||||
} else if (literal == "nan") {
|
} else if (literal == "nan") {
|
||||||
return NAN;
|
return NAN;
|
||||||
|
} else if (literal == "null") {
|
||||||
|
return nullptr;
|
||||||
}
|
}
|
||||||
throw error("invalid keyword " + literal);
|
throw error("invalid keyword " + literal);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user