Date: Mon, 4 Dec 2000 11:44:43 +1100 (EST) From: marka@nominum.com To: FreeBSD-gnats-submit@freebsd.org Subject: bin/23254: yacc accepts bad grammer Message-ID: <200012040044.eB40ihe41072@drugs.dv.isc.org> Resent-Message-ID: <200012040050.eB40o3D02000@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 23254
>Category: bin
>Synopsis: yacc accepts bad grammer
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Sun Dec 03 16:50:02 PST 2000
>Closed-Date:
>Last-Modified:
>Originator: Mark Andrews
>Release: FreeBSD 4.2-RELEASE i386
>Organization:
Nominum
>Environment:
FreeBSD drugs.dv.isc.org 4.2-RELEASE FreeBSD 4.2-RELEASE #0: Fri Nov 24 00:33:35 EST 2000 marka@drugs.dv.isc.org:/usr/obj/usr/src/sys/DRUGS i386
FreeBSD: src/usr.bin/yacc/skeleton.c,v 1.28 2000/01/17 02:04:06 bde Exp
>Description:
Yacc does not fail on bad grammer. This make FreeBSD a bad
development platform as yacc's on other platforms do error
on this bad grammer.
>How-To-Repeat:
Add a ";" to the end of any non-terminal rule. It should error
but doesn't.
The follow grammer fragment is bad. The fragment has been taken
from the BIND 8 source and modified to be bad by adding a semi-colon
after T_FIRST. Such a modification should cause yacc to error but
it doesn't.
zone_forward_opt: T_ONLY
{
set_zone_boolean_option(current_zone, OPTION_FORWARD_ONLY, 1);
}
| T_FIRST ;
{
set_zone_boolean_option(current_zone, OPTION_FORWARD_ONLY, 0);
}
;
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200012040044.eB40ihe41072>
