Line Number - Line Numbers and Syntax Errors

Line Numbers and Syntax Errors

If a programmer introduces a syntax error into a program, the compiler (or interpreter) will inform the programmer that the attempt to compile (or execute) failed at the given line number. This simplifies the job of finding the error immensely for the programmer.

The use of line numbers to describe the location of errors remains standard in modern programming tools, even though line numbers are never required to be manually specified. It is a simple matter for a program to count the newlines in a source file and display an automatically generated line number as the location of the error. In IDEs such as Microsoft Visual Studio or Xcode, in which the compiler is usually integrated with the text editor, the programmer can even double-click on an error and be taken directly to the line containing that error.

Read more about this topic:  Line Number

Famous quotes containing the words line, numbers and/or errors:

    Writing fiction has developed in me an abiding respect for the unknown in a human lifetime and a sense of where to look for the threads, how to follow, how to connect, find in the thick of the tangle what clear line persists. The strands are all there: to the memory nothing is ever really lost.
    Eudora Welty (b. 1909)

    Out of the darkness where Philomela sat,
    Her fairy numbers issued. What then ailed me?
    My ears are called capacious but they failed me,
    Her classics registered a little flat!
    I rose, and venomously spat.
    John Crowe Ransom (1888–1974)

    Let us pardon him his hope of a vain apocalypse, and of a second coming in great triumph upon the clouds of heaven. Perhaps these were the errors of others rather than his own; and if it be true that he himself shared the general illusion, what matters it, since his dream rendered him strong against death, and sustained him in a struggle to which he might otherwise have been unequal?
    Ernest Renan (1823–1892)