mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 09:37:34 +00:00
AK: Add JsonValue(const char*).
This should obviously become a string, but if we don't have it, constructing from a string literal ends up creating a boolean value.
This commit is contained in:
parent
1a761ea4fd
commit
4147394dcb
2 changed files with 6 additions and 0 deletions
|
@ -76,6 +76,11 @@ JsonValue::JsonValue(unsigned value)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
JsonValue::JsonValue(const char* cstring)
|
||||||
|
: JsonValue(String(cstring))
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
JsonValue::JsonValue(double value)
|
JsonValue::JsonValue(double value)
|
||||||
: m_type(Type::Double)
|
: m_type(Type::Double)
|
||||||
{
|
{
|
||||||
|
|
|
@ -34,6 +34,7 @@ public:
|
||||||
JsonValue(unsigned);
|
JsonValue(unsigned);
|
||||||
JsonValue(double);
|
JsonValue(double);
|
||||||
JsonValue(bool);
|
JsonValue(bool);
|
||||||
|
JsonValue(const char*);
|
||||||
JsonValue(const String&);
|
JsonValue(const String&);
|
||||||
JsonValue(const JsonArray&);
|
JsonValue(const JsonArray&);
|
||||||
JsonValue(const JsonObject&);
|
JsonValue(const JsonObject&);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue