Open WhiteBlackGoose opened 3 years ago
@Happypig375 the fact that Entity
will be serializable doesn't imply by default what exact framework or technique we will use for it. Probably, it will be similar to ToString and return a base64 format. And a MathS.Deserialize
will create an Entity
back from a serialized one.
That's my thoughts, but there should be serialization, so that you could save your formulas, or send somewhere, etc. Remember, that we don't guarantee a.ToString().ToEntity()
be parsable and equal to a
.
So why not an existing and widespread format like JSON, XML, YML, etc.?
Or not just Parse/ToString?
Maybe we will take JSON, I don't know. I just thought that maybe we want a compressed and fast format
Just Stringize/Parse should be compressed enough, right? I don't know about fast though, but shouldn't be much slower.
Like I said, a.ToString().ToEntity()
!= a
. Say, is 1 + 2 + 3
same as (1 + 2) + 3
or 1 + (2 + 3)
? For this one we have ExplicitOutput
setting, but in general, it might be not parsable back. Also, we need to check how slower it is to parse than to convert from a binary expression.
And make FieldCache non-serializable