Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
thebiochemic3012342di feel that's good that it is like that though. Because now you're don't confuse a String that is encoded with the Operating Systems Encoding with a regular String, that is encoded with UTF-8. If you want a regular string, you just lossy convert it to a regular string (losing the stuff that is not displayable) and can safely display the resulting string without thinking: "wait what format was this char* again". The cool part about this is additionally, that when the format of two different types is the same under the hood, the compiler will just optimize that away. So it's fast, and doesn't crash.
It's kinda the same thing as why you'd use Enums instead of just integers. -
Demolishun34966342dMaybe this is a ref to telling people to consider memory safety in coding decisions. I dunno, everything is a byte to me. So I think "I" am the problem here.
-
IntrusionCM14751342dIf I try to estimate how many times I had to explain encodings...
Wasn't char explicitly ASCII only?
Encoding is where the fun / torture begins.
Related Rants
Exactly my point regarding rust. Marvel was found by jestdottehh btw. I'm sure this one wasn't posted or well known yet
joke/meme
muahaha
rust
exactly
char
jestdottii
haha
dotteh
c
hehe
jest