r/ProgrammingLanguages • u/funcieq • May 23 '26
Discussion How to implement String?
Currently, String in my language is just value and length because it's a temporary solution, And as the language has developed, I am now able to rewrite a lot just for it, so I want to make a decent String in my language. So my question is, which String concept annoys you the least?
47
Upvotes
View all comments
Show parent comment
1
u/Karyo_Ten May 24 '26
Ah right, but passing by reference when you mutate is idiomatic.
And appending to a string when it's not in the cacheline already sounds like something you would avoid anyway in hot path