Type object

In addition to several reasonable sentences, we can also derive nonsense like “Computers run cheese” and “This am a lies”. These sentences don’t make semantic sense, but they are syntactically correct because they are of the sequence of subject, verb-phrase, and object. Formal grammars are a tool for syntax, not semantics. We worry about semantics at a later point in the compiling process. In the syntax analysis phase, we verify structure, not meaning.

[1]  Jean E. Sammet,et al.  Programming languages - history and fundamentals , 1969, Prentice-Hall series in automatic computation.

[2]  Noam Chomsky,et al.  On Certain Formal Properties of Grammars , 1959, Inf. Control..

[3]  J. C. Martin,et al.  Introduction to Languages and the Theory of Computation" 3rd Ed , 1991 .

[4]  John W. Backus,et al.  The syntax and semantics of the proposed international algebraic language of the Zurich ACM-GAMM Conference , 1959, IFIP Congress.

[5]  Alfred V. Aho,et al.  Compilers: Principles, Techniques, and Tools , 1986, Addison-Wesley series in computer science / World student series edition.