1<html lang="en"> 2<head> 3<title>Traditional Mode - The C Preprocessor</title> 4<meta http-equiv="Content-Type" content="text/html"> 5<meta name="description" content="The C Preprocessor"> 6<meta name="generator" content="makeinfo 4.13"> 7<link title="Top" rel="start" href="index.html#Top"> 8<link rel="prev" href="Preprocessor-Output.html#Preprocessor-Output" title="Preprocessor Output"> 9<link rel="next" href="Implementation-Details.html#Implementation-Details" title="Implementation Details"> 10<link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage"> 11<!-- 12Copyright (C) 1987, 1989, 1991, 1992, 1993, 1994, 1995, 1996, 131997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 142008, 2009, 2010, 2011 15Free Software Foundation, Inc. 16 17Permission is granted to copy, distribute and/or modify this document 18under the terms of the GNU Free Documentation License, Version 1.3 or 19any later version published by the Free Software Foundation. A copy of 20the license is included in the 21section entitled ``GNU Free Documentation License''. 22 23This manual contains no Invariant Sections. The Front-Cover Texts are 24(a) (see below), and the Back-Cover Texts are (b) (see below). 25 26(a) The FSF's Front-Cover Text is: 27 28 A GNU Manual 29 30(b) The FSF's Back-Cover Text is: 31 32 You have freedom to copy and modify this GNU Manual, like GNU 33 software. Copies published by the Free Software Foundation raise 34 funds for GNU development. 35--> 36<meta http-equiv="Content-Style-Type" content="text/css"> 37<style type="text/css"><!-- 38 pre.display { font-family:inherit } 39 pre.format { font-family:inherit } 40 pre.smalldisplay { font-family:inherit; font-size:smaller } 41 pre.smallformat { font-family:inherit; font-size:smaller } 42 pre.smallexample { font-size:smaller } 43 pre.smalllisp { font-size:smaller } 44 span.sc { font-variant:small-caps } 45 span.roman { font-family:serif; font-weight:normal; } 46 span.sansserif { font-family:sans-serif; font-weight:normal; } 47--></style> 48<link rel="stylesheet" type="text/css" href="../cs.css"> 49</head> 50<body> 51<div class="node"> 52<a name="Traditional-Mode"></a> 53<p> 54Next: <a rel="next" accesskey="n" href="Implementation-Details.html#Implementation-Details">Implementation Details</a>, 55Previous: <a rel="previous" accesskey="p" href="Preprocessor-Output.html#Preprocessor-Output">Preprocessor Output</a>, 56Up: <a rel="up" accesskey="u" href="index.html#Top">Top</a> 57<hr> 58</div> 59 60<h2 class="chapter">10 Traditional Mode</h2> 61 62<p>Traditional (pre-standard) C preprocessing is rather different from 63the preprocessing specified by the standard. When GCC is given the 64<samp><span class="option">-traditional-cpp</span></samp> option, it attempts to emulate a traditional 65preprocessor. 66 67 <p>GCC versions 3.2 and later only support traditional mode semantics in 68the preprocessor, and not in the compiler front ends. This chapter 69outlines the traditional preprocessor semantics we implemented. 70 71 <p>The implementation does not correspond precisely to the behavior of 72earlier versions of GCC, nor to any true traditional preprocessor. 73After all, inconsistencies among traditional implementations were a 74major motivation for C standardization. However, we intend that it 75should be compatible with true traditional preprocessors in all ways 76that actually matter. 77 78<ul class="menu"> 79<li><a accesskey="1" href="Traditional-lexical-analysis.html#Traditional-lexical-analysis">Traditional lexical analysis</a> 80<li><a accesskey="2" href="Traditional-macros.html#Traditional-macros">Traditional macros</a> 81<li><a accesskey="3" href="Traditional-miscellany.html#Traditional-miscellany">Traditional miscellany</a> 82<li><a accesskey="4" href="Traditional-warnings.html#Traditional-warnings">Traditional warnings</a> 83</ul> 84 85 </body></html> 86 87