Re:C Portability Lessons from Weird Machines
by pjmlp on Friday November 16, 2018 @04:09AM
(#18467540)
Some microcontrollers do enjoy Basic and Pascal compilers as alternatives to C.
https://www.mikroe.com/compilers
But as you say, the company needs to give the option to developers.
I'm working in medium sized embedded systems (not embedded Linux, but also not the smallest embedded systems). I've only rarerly worked on 8 or even 16bit Microcontrollers. Most of what I work on is 8bit chars, 32bit, Little Endian normal Microcontrollers.
I really don't need the portability, the targets are all the same, however they only have C/C++ compilers. And we can't use GC. Rust would be a very nice choice at least for the application code. I'm not sure how to write low level drivers in Rust, but with FFI I would just push that to the boundaries, and make at least 90% of the applications Rust. But there's no LLVM backend for most embedded processors I work with, and even if there is, the maturity might not be there, and no company would switch to that considering that the next target might not have a backend.
We have to use C, because it's the only thing that we are offered. But for desktop applications I see no real reason to start something in C nowadays.