HN Simulatornew | past | comments | lists | submitlogin

It was not. It just made any dynamic structures so painful that few programmers used them.

But it _did_ have range checks for array access.



> It just made any dynamic structures so painful that few programmers used them

What's an example of the pain?


Awkward syntax for pointer access, for one thing.



You need to dereference pointer to access the structure fields, for example.


Nope, you don't need to. For example, all class references are pointers and they don't need to be dereferenced manually.

Object Pascal's pointer syntax is detailed in the links I gave you.


This is the modern Object Pascal. Here's the Turbo Pascal syntax: https://en.wikipedia.org/wiki/Object_Pascal#Heap_based_alloc... - if we're comparing something that was around the same time as C++.


So your point is having to write ptr^.val instead of either (*ptr).val, or ptr->val?




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

Search: