Comment

Comment by WalterBright

D uses "phat pointers" for strings, aka a length/pointer pair. Over the years, this has proven to be simple, efficient, and resistant to errors. It means array bounds checking can be automatically done. It enables efficient slicing.

String literals also have an extra 0 appended, making it transparently easy to still pass strings to C functions like printf.

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton