Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function s_anyVariable(data, lastType, isNumeric, isKey, isLast, nice, indent)
- -- Basically, if the type changes.
- if lastType ~= type(data) then
- -- Remember the new type. Caching the type is useless.
- lastType = type(data)
- if (!_serialize[lastType]) then
- ErrorNoHalt("vON: Unknown type "..lastType.."!");
- end;
- -- Return the serialized data and the (new) last type.
- -- The second argument, which is true now, means that the data type was just changed.
- return _serialize[lastType](data, true, isNumeric, isKey, isLast, nice, indent), lastType
- end
- -- Otherwise, simply serialize the data.
- return _serialize[lastType](data, false, isNumeric, isKey, isLast, nice, indent), lastType
- end
Advertisement
Add Comment
Please, Sign In to add comment