Comment

Comment by zozbot234

> "why are you forcing me to waste a bunch of time doing needless bookkeeping when I create and pass around a string?"

Rust does not force you to do this. You can in fact pass around `String`, `Vec<…>` etc, and Rust will use move semantics to make it reasonably efficient. Of course using &str and &[…] is the proper "zero overhead" solution, but it does require some extra effort.

parent zozbot234 4 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton