Comment by nixpulvis
6 hours ago
I've always been conflicted on them. I like that they allow me to be more explicit about things which are read from input or parsed out as strings vs internal parts of my program (I rarely call .to_sym), but I've also lost time to being careless and indexing hash maps with the wrong type.
Overall, I think I'm glad they exist.
I've had to fix so many errors over the years due to string/symbol mismatch in function calls and/or hash access, and never once have I benefited from the extra optimizations that the guaranteed singular allocation of symbols have given me where I wasn't able to get the same benefit from a frozen string literal.
If it was up to me I'd get rid of them, but I know I have an unpopular opinion and it's really only a thought experiment.