Another quick note, Tony:

 There are plenty of embedded environments where if you're allowed to use
>> C++ at all, it's only a limited subset, anything involving exceptions or
>> RTTI is often not supported. It's tough to audit 3rd-party libraries for
>> these kinds of restrictions, and achieve any kind of code reuse or
>> non-trivial complexity.
>>
>
At least the "auditing for restrictions" part of that problem ~seems like
it should be easy in a well designed language.  I want to just declare an
environment and have the compiler throw errors if anything inside it
violates the restrictions I care about for whatever my personal definition
of what a "realtime" or "typesafe" or "pure functional" language subset is.


Something along the lines of: "#[deny(managed_heap_memory)]":

https://github.com/rust-lang/rust/issues/9984

Of course as you point out there is the other part of the problem
"achieving code reuse and complexity", which is much harder.

Reply via email to