TechWhirl (TECHWR-L) is a resource for technical writing and technical communications professionals of all experience levels and in all industries to share their experiences and acquire information.
For two decades, technical communicators have turned to TechWhirl to ask and answer questions about the always-changing world of technical communications, such as tools, skills, career paths, methodologies, and emerging industries. The TechWhirl Archives and magazine, created for, by and about technical writers, offer a wealth of knowledge to everyone with an interest in any aspect of technical communications.
My friend who first brought syntax diagrams into my life prefers to stay
anonymous, but offers the following:
*** begin inclusion
The common method of syntax presentation with the brackets, braces,
color glossys with the circles and arrows, is called the Baccus Nour
(sic) format, most people call it BNR.
The syntax diagrams (SD) were developed at IBM. (The term "railroad
diagram" comes from the fact that they look like the schematics that
rail roads use to map out their lines.)
Each method has advantages. Basically, I found that SD diagrams worked
well for command languages, especially where the order of options wasn't
important. (A command language begins with an identifier, followed by
the options.) For example, "LIST FOR Free WHILE InStock" might also be
wrtten "LIST WHILE InStock FOR Free"
BNR worked better for function based languages (like C/C++). There the
order of the arguments is fixed, and there are usually few options. BNR
also has the advantage of "looking" more like the actual command that
gets typed in. " LIST [FOR <for-condition>] [WHILE <while-condition>]
Where BNR breaks down is when you have options within options: "one or
the other" situations. It becomes confusing to keep track of what is
available and where. SDs are good because they graphically spell out
which options go with which other arguments. For example:
"LIST {[FOR <for-condition>] | [WHILE <while-condition>]}"
To be most effective, SDs need arrows to indicate when something is
available.
LIST -+------------>+--+--+-> FOR <for-condition> -----+--+-->
+-> <scope> ->+ | +-> WHILE <while-condition> -+ |
+<---------------------------------+
But for complex commands, the diagrams can be HUGE and take up a whole
page.