diff --git a/homepage/knowledge/c78.html b/homepage/knowledge/c78.html index dffc9f5..281d1f8 100644 --- a/homepage/knowledge/c78.html +++ b/homepage/knowledge/c78.html @@ -73,7 +73,7 @@ snippet.c:4:53: error: invalid digit "9" in octal constant
This is because in C (both pre-standardization and post-ANSI) integer constants with leading zeroes are parsed as octal (base 8) numbers.
-In pre-ANSI C, 8
and 9
were valid octal digits corresponding to 010
(b8) and 11
(0b8).
+In pre-ANSI C, 8
and 9
were valid octal digits corresponding to 010
(b8) and 011
(b8).
This is documented in The C Programming Language, Appendix A, subsection 2.4.1, and evidenced by the preceding code block.
The following is output of the compiled program in UNIX V6 on an emulated PDP-11: