It's amazing how underestimated the Object Pascal language is. Certain people or rivals want to write it off or declare it's "dead", yet the language (including various dialects) are still going strong.
This is the modern Object Pascal. Here's the Turbo Pascal syntax: <a href="https://en.wikipedia.org/wiki/Object_Pascal#Heap_based_allocation" rel="nofollow">https://en.wikipedia.org/wiki/Object_Pascal#Heap_based_alloc... - if we're comparing something that was around the same time as C++.
baranul · · focus · HN ↗
pjmlp · · focus · HN ↗
Otherwise it would still be a big contender.
Everything that Zig offers over C as selling point was already there in Object Pascal.
ape4 · · focus · HN ↗
pjmlp · · focus · HN ↗
cyberax · · focus · HN ↗
But it _did_ have range checks for array access.
cisc · · focus · HN ↗
What's an example of the pain?
cyberax · · focus · HN ↗
cisc · · focus · HN ↗
<a href="https://docwiki.embarcadero.com/RADStudio/Florence/en/Pointers_and_Pointer_Types_(Delphi)#Overview_of_pointers" rel="nofollow">https://docwiki.embarcadero.com/RADStudio/Florence/en/Pointe...
<a href="https://castle-engine.io/modern_pascal#_pointers" rel="nofollow">https://castle-engine.io/modern_pascal#_pointers
cyberax · · focus · HN ↗
cisc · · focus · HN ↗
Object Pascal's pointer syntax is detailed in the links I gave you.
[deleted] · · focus · HN ↗
[deleted]
cyberax · · focus · HN ↗
pjmlp · · focus · HN ↗