4 ms·
> Forsaking C means forsaking anything below the level of abstraction at which one happens to currently work. This is mostly true today, but I hope that over t
by elihu 9y ago
> Forsaking C means forsaking anything below the level of abstraction at which one happens to currently work.
This is mostly true today, but I hope that over time we'll see more languages fill the gap between hardware and high-level languages. There's no fundamental reason why that middle layer has to be in C, we just have had a shortage of viable alternatives.
- inetknght 9y agoIf you truly believe that then I think it's time for you to go learn about some new languages. C++, Go, Rust... these are very viable alternatives to C.
- notriddle 9y agoC++ and Rust, yes, but not Go. Go is a lot closer to Java than it is to C++, since its growable stacks and garbage collector require marshaling overhead to call out to languages that don't know about them.
- asveikau 9y agoHmm, I thought a growable stack via a guard page that allocates more stack on a fault was common in C-based languages. (Though this would be an OS feature rather than a language one.) I routinely put very large buffers on stacks in C and C++ and don't generally run into problems unless I accidentally do infinite recursion.
- Rusky 9y ago> I thought a growable stack via a guard page that allocates more stack on a fault was common in C-based languages. It is, but that's not how Go's growable stack works. Go's is grown by the language runtime and relocated when necessary, using its GC infrastructure, so you really can't put non-Go stack frames on it.
- pcwalton 9y agoThere's no shortage of viable alternatives. C++ is significantly more popular than C these days, and the gap widens every year.
- AlexandrB 9y agoThe problem is you can't learn all of C++. I've been coding in it for the better part of a decade and I still run into weird corners that don't make sense regularly. C is much more compact.
- waynecochran 9y agoAmen. Every time I think I have my head wrapped around C++ a new version comes out or Scott Meyers writes a book and I realize how ignorant I am about C++. No one really know all of C++. I bet Stroustrap occasionally sees some C++ code and says "huh ... I didn't know you could do that."
- kqr 9y ago> "huh ... I didn't know you could do that." To be fair, that is not an entirely uncommon thing to say when watching a user work with something you made.