definition of the term "syntactic form"

3.7k views Asked by At

In the book "Types and Programming Languages" Benjamin C. Pierce uses the concept/term syntactic form (see image) , however he does not give an explicit definition for it. I was trying to look for the definition of this term on the Internet but I found nothing illuminating.

Could somebody point out some reference (book) where this term is defined , or give the definition for it?

Is a sentence defined by the grammar a syntactic form ?

In what other books is the term syntactic form used ?

Is syntactic form the same as term (defined on page 24) ? If not, what is the difference between these two concepts.

enter image description here

enter image description here

2

There are 2 answers

3
rici On BEST ANSWER

You're probably over-thinking this; the language isn't really intended to be precise. (The grammar for t, on the other hand, is meant to be precise.) I'm not even sure how I would say that -- I think I would have said "syntactic construct" or "syntactic rule" --; he means that all you need to know about the language can be summarized in the recognition of a handful of patterns (which he then lists).

If the book were about formal language theory, the more precise description would probably be "production" (really, the right-hand side of the production) or possibly "AST node", although I'd view an AST node as being a semantic unit derived from the syntax.

Since this is a book about semantics, he will proceed to apply semantics to each syntagma (to use a word for the concept which sounds like it should be more formal).

0
AudioBubble On

"In computer science, the syntax of a computer language is the set of rules that defines the combinations of symbols that are considered to be a correctly structured document or fragment in that language." -Wikipedia.

So syntactic form, in this case, is the forms that C allows it's symbols to take. For instance, in a language like Scheme, you'd have #t and #f for true or false, where in C you represent these as true and false. Some languages allow you to use 1 and 0 as true and false. The values can differ greatly depending on the language you're using. So for C, you're looking at how C represents it's functionality. Of course it's not just limited to true and false. Things like how you represent an integer, or a function apply as well. Basically how you represent anything in C applies to "syntactic form".