-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Labels
enhancementNew feature or requestNew feature or requestresearchIssue or pull request representing experimental researchIssue or pull request representing experimental research
Description
Note
This issue is for research if and to what extent this feature is possible for Struson.
It is not guaranteed that it will be implemented, but feedback is appreciated! Feel free to add comments to share tips.
This issue might be extended or adjusted over time.
Description
Support usage of Struson in no_std environments. Struson as low-level JSON library might be useful for environments without std.
Goals
- Support
no_stdenvironments- Some of the
stdtraits used by Struson might not be available (related Rust issue). Have to search for solutions for that; maybe add traits in Struson which - ifstdis available - have implementations for thestdtraits, and otherwise users need to provide their own implementations. - If this is not possible, consider at least to reduce
stddependencies (especially if it just a matter of adjustingusedeclarations) so that it is easier for users to create ano_stdfork of Struson.
- Some of the
Non-goals
- Support for no-
alloc
While closely related tono_std, support for no-alloccould be a separate independent feature (and a separate GitHub issue here) which could also be useful even ifallocis available, for example to ensure no additional allocations are performed while reading JSON. For exampleJsonStreamReadercould be created with a fixed sized value buffer, methods for readingStringwould require anallocfeature (enabled by default), and methods reading astrwould return a new error type in case the value exceeds the fixed sized value buffer.
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestresearchIssue or pull request representing experimental researchIssue or pull request representing experimental research