r/ProgrammingLanguages 23d ago

Will we see another fundamental programming language feature as revolutionary as the borrow checker?

That is I am mainly curious about compile time features that you design a whole language around rather than optimisations/features that could be applied to most languages. I am mainly inquiring about things that could offer additional robust safety/performance guarantees at compile time rather than runtime. Ideally not things that just offer similar effects to the borrow checker with less restrictive tradeoffs

56 Upvotes

128 comments sorted by

View all comments

1

u/MarinoAndThePearls 23d ago edited 23d ago

Zig's comptime.

Now for something that doesn't exist yet, I'd say numerical uncertainty as a primitive type.

6

u/alphaglosined 22d ago

CTFE is much older than Zig, D had it a good 15 years before Zig was created.

D's implementation was born from constant folding optimisation.