You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When converting to ziggy format (JSON->Ziggy being the one mapping currently implemented), would it make more sense to construct a ziggy.Ast object rather than directly writing Ziggy snippets as bytes (via std.ArrayList(u8).writer())?
The main advantage I can see for writing directly is that the writer for the final destination (file/stdout) could be passed through giving streaming output as conversion is performed and reducing memory usage. However, this is not currently done, the writer is simply associated with an ArrayList(u8).
Pros:
Less error prone(?)
Get proper formatting by simply printing the AST
Cons:
Memory impact?
I'd be happy to have a go at this change if there's interest.
The text was updated successfully, but these errors were encountered:
When converting to ziggy format (JSON->Ziggy being the one mapping currently implemented), would it make more sense to construct a
ziggy.Ast
object rather than directly writing Ziggy snippets as bytes (viastd.ArrayList(u8).writer()
)?The main advantage I can see for writing directly is that the writer for the final destination (file/stdout) could be passed through giving streaming output as conversion is performed and reducing memory usage. However, this is not currently done, the writer is simply associated with an
ArrayList(u8)
.Pros:
Cons:
I'd be happy to have a go at this change if there's interest.
The text was updated successfully, but these errors were encountered: