/share/doc/psd/15.yacc/ssd
https://bitbucket.org/freebsd/freebsd-head/ · #! · 76 lines · 76 code · 0 blank · 0 comment · 0 complexity · 0be5e51468f71119e3a3ecf6294321b5 MD5 · raw file
- .\" Copyright (C) Caldera International Inc. 2001-2002. All rights reserved.
- .\"
- .\" Redistribution and use in source and binary forms, with or without
- .\" modification, are permitted provided that the following conditions are
- .\" met:
- .\"
- .\" Redistributions of source code and documentation must retain the above
- .\" copyright notice, this list of conditions and the following
- .\" disclaimer.
- .\"
- .\" Redistributions in binary form must reproduce the above copyright
- .\" notice, this list of conditions and the following disclaimer in the
- .\" documentation and/or other materials provided with the distribution.
- .\"
- .\" All advertising materials mentioning features or use of this software
- .\" must display the following acknowledgement:
- .\"
- .\" This product includes software developed or owned by Caldera
- .\" International, Inc. Neither the name of Caldera International, Inc.
- .\" nor the names of other contributors may be used to endorse or promote
- .\" products derived from this software without specific prior written
- .\" permission.
- .\"
- .\" USE OF THE SOFTWARE PROVIDED FOR UNDER THIS LICENSE BY CALDERA
- .\" INTERNATIONAL, INC. AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR
- .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- .\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- .\" DISCLAIMED. IN NO EVENT SHALL CALDERA INTERNATIONAL, INC. BE LIABLE
- .\" FOR ANY DIRECT, INDIRECT INCIDENTAL, SPECIAL, EXEMPLARY, OR
- .\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- .\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
- .\" BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- .\" WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- .\" OR OTHERWISE) RISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
- .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- .\" @(#)ssd 8.1 (Berkeley) 6/8/93
- .\"
- .\" $FreeBSD$
- .SH
- Appendix D: Old Features Supported but not Encouraged
- .PP
- This Appendix mentions synonyms and features which are supported for historical
- continuity, but, for various reasons, are not encouraged.
- .IP 1.
- Literals may also be delimited by double quotes ``"''.
- .IP 2.
- Literals may be more than one character long.
- If all the characters are alphabetic, numeric, or \_, the type number of the literal is defined,
- just as if the literal did not have the quotes around it.
- Otherwise, it is difficult to find the value for such literals.
- .IP
- The use of multi-character literals is likely to mislead those unfamiliar with
- Yacc, since it suggests that Yacc is doing a job which must be actually done by the lexical analyzer.
- .IP 3.
- Most places where % is legal, backslash ``\e'' may be used.
- In particular, \e\e is the same as %%, \eleft the same as %left, etc.
- .IP 4.
- There are a number of other synonyms:
- .DS
- %< is the same as %left
- %> is the same as %right
- %binary and %2 are the same as %nonassoc
- %0 and %term are the same as %token
- %= is the same as %prec
- .DE
- .IP 5.
- Actions may also have the form
- .DS
- ={ . . . }
- .DE
- and the curly braces can be dropped if the action is a
- single C statement.
- .IP 6.
- C code between %{ and %} used to be permitted at the
- head of the rules section, as well as in the
- declaration section.