Dictionary entry

EOF

nouncomputing

Last updated

UK/ˌiː əʊ ˈef/
US/ˌiː oʊ ˈef/

Meanings

  1. noununcountablecomputing

    A signal or condition showing that no more data can be read from a file or input stream.

    Grammar: Used as a mass noun: the program checks for EOF. Do not say 'an EOF' unless you mean a specific end-of-file marker.

    Patterns

    • check for EOF
    • return EOF
    • EOF character

    The loop stops when the reader reaches EOF.

    If the file is empty, the function returns EOF immediately.

    Always test for EOF before processing another line.

  2. nouncountablecomputing

    A key combination or control character that tells a program the input has ended.

    Grammar: Countable when talking about a particular keypress or character: send an EOF.

    Patterns

    • send an EOF
    • type EOF
    • press Ctrl-D for EOF

    On Unix you can send an EOF by pressing Ctrl-D.

    The editor didn't save because I typed an EOF by mistake.

Common combinations

EOF error
The parser threw an EOF error because the last brace was missing.
EOF marker
The file ends with a special EOF marker.
reach EOF
The stream will reach EOF after the last record.
EOF character
In some systems the EOF character is Ctrl-Z.

Synonyms and how they differ

end of file
The full phrase; use it in writing when you want to be clear to non-programmers.

Word family

end of file phrase
The expanded form of EOF, meaning the point where a file ends.
BOF abbreviation
Beginning of file; the opposite position in a file.

Commonly confused: EOF or EOL?

EOF vs EOL

EOL means end of line, not end of file. A file can have many EOLs but only one EOF.

Practice

Which sentence uses EOF correctly?

Make it your own

Write a sentence using “EOF”, then check it and compare it with the examples above.

Your sentence stays on this page and is not sent anywhere.

Explore more words