Hacker News new | past | comments | ask | show | jobs | submit login

I am just answering about placing data into the stack, and that is offered by all descendents of Algol/Pascal/CLU/Mesa/Modula/Ada/... family of languages.

You can place data in the stack in all of them.

Quite a few of them allow for generics, starting with CLU.

Ada also offers RAII, although a bit more verbose than C++ way of doing it.

All of them allow reference arguments, hence no need for pointers for output parameters.




RAII is totally irrelevant to this discussion, and I clearly said I was not just talking about placing data on the stack.

> All of them allow reference arguments, hence no need for pointers for output parameters.

I wasn't very clear, the use of a C-style pointer is irrelevant: if it is being used as a reference (i.e. not owning, no need for clean-up/deallocation), then it counts as a reference. I was using the Rust terminology where 'pointer' mostly refers to 'smart pointer'.




Join us for AI Startup School this June 16-17 in San Francisco!

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

Search: