MaulingMonkey / ialloc

Allocator interface traits for Rust
Apache License 2.0
2 stars 0 forks source link

Merge `nzst::*` and `zsty::*` into `fat::*`? #16

Closed MaulingMonkey closed 1 year ago

MaulingMonkey commented 1 year ago

Motivating example:

let u32 = ABox::new_in(42_u32, Malloc);
let zst = ABox::new_in((),     Malloc);

It would be nice if the former compiled while the latter didn't. This cannot be particularly well accomplished by separating nzst::* from zsty::*. For another example, these should both compile:

let u32 = ABox::new_in(42_u32, DangleZst(Malloc));
let zst = ABox::new_in((),     DangleZst(Malloc));

TODO

MaulingMonkey commented 1 year ago

c781389 ABox: ZST checks