toJSON(): Support some more types
This commit is contained in:
parent
ae522f930d
commit
b0f7f9c98f
|
@ -44,6 +44,16 @@ void toJSON(std::ostream & str, long n)
|
|||
str << n;
|
||||
}
|
||||
|
||||
void toJSON(std::ostream & str, unsigned int n)
|
||||
{
|
||||
str << n;
|
||||
}
|
||||
|
||||
void toJSON(std::ostream & str, int n)
|
||||
{
|
||||
str << n;
|
||||
}
|
||||
|
||||
void toJSON(std::ostream & str, double f)
|
||||
{
|
||||
str << f;
|
||||
|
|
|
@ -12,6 +12,8 @@ void toJSON(std::ostream & str, const char * s);
|
|||
void toJSON(std::ostream & str, unsigned long long n);
|
||||
void toJSON(std::ostream & str, unsigned long n);
|
||||
void toJSON(std::ostream & str, long n);
|
||||
void toJSON(std::ostream & str, unsigned int n);
|
||||
void toJSON(std::ostream & str, int n);
|
||||
void toJSON(std::ostream & str, double f);
|
||||
void toJSON(std::ostream & str, bool b);
|
||||
|
||||
|
|
Loading…
Reference in a new issue