Ocaml uses 0o for octal. Seem consistent and works well enough.
0o
Common Lisp uses #o as a prefix, e.g. #o0, which seems fine too.
#o
#o0
“Considered Harmful” Essays Considered Harmful: https://meyerweb.com/eric/comment/chech.html
When was the last time you productively used an octal number-representation?
Whenever I terminate a C string with a null character.
I’m curious, why do you need octal for that? 0, 0x0, 0b0, and 00 all act the exact same, don’t they?
0
0x0
0b0
00
It’s a joke, because 0 is an octal literal.
I think it’s unlikely a future C standard will drop the 0 prefix.
Ocaml uses
0ofor octal. Seem consistent and works well enough.Common Lisp uses
#oas a prefix, e.g.#o0, which seems fine too.“Considered Harmful” Essays Considered Harmful: https://meyerweb.com/eric/comment/chech.html
Whenever I terminate a C string with a null character.
I’m curious, why do you need octal for that?
0,0x0,0b0, and00all act the exact same, don’t they?It’s a joke, because
0is an octal literal.I think it’s unlikely a future C standard will drop the 0 prefix.