Browsable Antoniol heuristic for C♯ Grammar

CC-BY

Grammar extracted by Vadim Zaytsev, see the Grammar Zoo entry for details: csharp/v3.0/antoniol/extracted
Source used for this grammar: James R. Cordy, Andrew J. Malton, Christopher Dahn, Antoniol et al heuristic to resolve all #ifs in C programs, version 1.1, May 2008

Summary

Syntax

program ::=
	line*
line ::=
	ifdef
	"//"? other_preprocessor_line newline
	"//"? any_other_line newline
ifdef ::=
	"//"? ifdef_line newline line* elsif_part* else_part? "//"? endifdef_line newline
elsif_part ::=
	"//"? elsifdef_line newline line*
else_part ::=
	"//"? elsedef_line newline line*
any_other_line ::=
	not_newline*
not_newline ::=
	long_comment
	token
long_comment ::=
	comment+
ifdef_token ::=
	ifdef_line
	elsedef_line
	elsifdef_line
	endifdef_line

GrammarLabMaintained by Dr. Vadim Zaytsev a.k.a. @grammarware. Last updated in September 2015. []