Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
cperciva
on June 3, 2010
|
parent
|
context
|
favorite
| on:
Interviewing programmers: coding test example expl...
Huh, you're right. I wonder when they changed that.
nuxi
on June 3, 2010
|
next
[–]
They didn't, it's there from at least ANSI C89 (ISO C90): "A byte with all bits set to 0, called the null character, shall exist in the basic execution character set; it is used to terminate a character string literal."
JoachimSchipper
on June 3, 2010
|
parent
|
next
[–]
I think the rationale is in EBCDIC support; the C standard didn't want to/couldn't mandate ASCII, and therefore could not use the ASCII NUL character.
I honestly don't know whether POSIX/SUS mandates ASCII.
nuxi
on June 4, 2010
|
root
|
parent
|
next
[–]
As far as I understand, no:
http://www.opengroup.org/onlinepubs/000095399/xrat/xbd_chap0...
JoachimSchipper
on June 4, 2010
|
root
|
parent
|
next
[–]
I read that as "ASCII must be supported, do whatever else you want". But I don't want to spend
too
much time on this...
jonsen
on June 3, 2010
|
prev
[–]
NUL is in ASCII an abbreviation for null.
Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: