News for hackers. Stuff that matters.
Re:Rust on AVR: Safer microcontrollers almost here by jononor on Saturday February 11, 2017 @12:29PM (#13623590)
For embedded code, I'd recommend that all application code should be compiled with the `--deny unsafe-code` option. Then the compiler will stop you. A separate module for the I/O code providing is the only place where one should use `unsafe`. Extra care must be taken here, in code review and in testing.
Re:Rust on AVR: Safer microcontrollers almost here by milesrout on Sunday February 12, 2017 @02:01AM (#13627190)
Do you have any idea how impossible it is to do anything useful without unsafe in Rust on a microcontroller?
Re:Rust on AVR: Safer microcontrollers almost here by jononor on Sunday February 12, 2017 @07:29AM (#13628050)
About as hard as on desktop? I mean, many of the core datastructures commonly used there are implemented using unsafe. This does not mean that the application code must or should be riddled with unsafe code blocks... For a very simple example see https://github.com/hackndev/zinc/blob/master/examples/blink_...
Re:Rust on AVR: Safer microcontrollers almost here by pjmlp on Sunday February 12, 2017 @06:38AM (#13627909)
If Ada, Pascal and Basic can, so can Rust.

Every case where this is not true is a bug.