next up previous contents index
Next: Précédence des opérateurs Up: No Title Previous: Grammaire de C

Grammaire du préprocesseur C


control-line:
		   $\mathtt{\char93 }$ define identifier token-sequence
		   $\mathtt{\char93 }$ define identifier( identifier , ... ,identifer) token-sequence
		   $\mathtt{\char93 }$ undef identifier
		   $\mathtt{\char93 }$ include <filename>
		   $\mathtt{\char93 }$ include "filename"
		   $\mathtt{\char93 }$ include token-sequence
		   $\mathtt{\char93 }$ line constant "filename"
		   $\mathtt{\char93 }$ line constant
		   $\mathtt{\char93 }$ error token-sequence$_{\mathsf{opt}}$ 
		   $\mathtt{\char93 }$ pragma token-sequence$_{\mathsf{opt}}$ 
		   $\mathtt{\char93 }$
		   preprocessor-conditional   
 
preprocessor-conditional:
		   if-line text elif-parts else-part$_{\mathsf{opt}}$ $\mathtt{\char93 }$ endif   
 
if-line:
		   $\mathtt{\char93 }$ if constant-expression
		   $\mathtt{\char93 }$ ifdef identifier
		   $\mathtt{\char93 }$ ifndef identifier   
 
elif-parts:
		   elif-line text
		   elif-parts$_{\mathsf{opt}}$ 
 
elif-line:
		   $\mathtt{\char93 }$ elif constant-expression   
 
elif-part:
		   else-line text   
 
else-line:
		   $\mathtt{\char93 }$ else   



Jean-Philippe Chancelier
9/29/1998