News for hackers. Stuff that matters.
Re:White House urges devs to switch to memory-safe programmi... by steveklabnik on Tuesday February 27, 2024 @10:58AM (#39525597)
Out of those, Box is the only one that is, and the way that it is is not syntax: it has one exception, and that’s that you can move the contents out of it via a dereference. That’s making existing syntax semantically valid, not introducing new syntax.

In terms of syntax, you create a box with Box::new just like you might any other struct.

EDIT: anyway I'm not saying that means that your underlying issue isn't real, just that I think describing it as "syntax" makes the issue confusing to understand. It sounds to me like maybe you think Rust programs are too verbose?

There are no comments on this comment yet.