ecere/sys/JSON: Fixed serialization of bit classes
authorJerome St-Louis <jerome@ecere.com>
Sun, 15 Feb 2015 21:16:45 +0000 (16:16 -0500)
committerJerome St-Louis <jerome@ecere.com>
Sun, 15 Feb 2015 21:17:20 +0000 (16:17 -0500)
ecere/src/sys/JSON.ec

index 1b94380..a6bebd7 100644 (file)
@@ -878,10 +878,16 @@ bool WriteValue(File f, Class type, DataValue value, int indent)
    {
       WriteArray(f, type, value.p, indent);
    }
-   else if(type.type == normalClass || type.type == noHeadClass || type.type == structClass || type.type == bitClass)
+   else if(type.type == normalClass || type.type == noHeadClass || type.type == structClass)
    {
       _WriteJSONObject(f, type, value.p, indent);
    }
+   else if(type.type == bitClass)
+   {
+      Class dataType;
+      dataType = eSystem_FindClass(__thisModule, type.dataTypeString);
+      WriteNumber(f, dataType, value, indent);
+   }
    else if(type.type == systemClass)
    {
       WriteNumber(f, type, value, indent);