Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Why do you mention AVR? AVR-GCC has C++ support, that's what made the original Arduino (before they switched to ARM) approachable to beginners.


> AVR-GCC has C++ support

It's a very restricted subset of C++ that has almost no advantages over plain C, and some number of disadvantages.


- templates instead of macros

- constexpr instead of macros

- if constexpr instead of macros

- stronger type checking

- type inference

- strong type enumerations

- namespacing instead of pre-historic naming prefixes

- classes as means to enforce type invariants

I see some advantages.


List of typical 8 bit CPUs, and I was thinking only about commercial compilers.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: