3 ms·
C++ has (albeit only since version 14) the single quote as digit separator, which is (IMHO) a better choice: https://en.cppreference.com/w/cpp/language/integer_
by restalis 5y ago
C++ has (albeit only since version 14) the single quote as digit separator, which is (IMHO) a better choice: https://en.cppreference.com/w/cpp/language/integer_literal https://en.cppreference.com/w/cpp/language/integer_literal
- WalterBright 5y ago> which is (IMHO) a better choice I know C++ added it 14 years after D :-) but I'm curious why you say ' is a better choice? I never read the papers proposing the feature, but the _ hasn't caused any problems for us, and I like it better myself.
- restalis 5y agoI use the quote separator for digit grouping on any occasion, i.e. also outside of computer code. There, we usually have non-monospaced fonts, for which the use of underscores is glaringly uglier compared to use of single quotes. I don't know if you took this design decision from somewhere else or not, but it was an inspired decision nevertheless. Also, I'm glad and honoured to have a comment like yours in my history. Sorry for late reply.