79820120

Date: 2025-11-14 14:23:31
Score: 1
Natty:
Report link

As I said, I am in the situation of developing a lib for use both in [no_std] (and also no alloc) and with-std environments, because this will be used in WASM (no_std for size reasons) and also natively, where access to std is normal.

That was my comment about having two concrete subclasses - one for use in native, and one without. In Rust this can be done with features, so that part is fine - but the core design is still missing.

Using sized arrays is out, because the size of the data is only known at run-time. Even in the no_std case, a minimal amount of "allocation" needs to happen, although it can be as simple as a bump allocator that never frees.

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Self-answer (0.5):
  • Low reputation (0.5):
Posted by: D0SBoots