summaryrefslogtreecommitdiff
path: root/gcc/cpplib.h
diff options
context:
space:
mode:
authorNeil Booth <neil@daikokuya.demon.co.uk>2001-10-02 12:57:24 +0000
committerNeil Booth <neil@gcc.gnu.org>2001-10-02 12:57:24 +0000
commit644eddaac53831b51967cea591f0bdf3b5e770a7 (patch)
tree255137e6966135d2fff952402170da9491a088d4 /gcc/cpplib.h
parent9d19cb9582b17accc88c77131b11095ce14199bd (diff)
downloadgcc-644eddaac53831b51967cea591f0bdf3b5e770a7.tar.gz
cpphash.h: Update comments.
* cpphash.h: Update comments. (cpp_context): Update. (spec_nodes): Remove n__Pragma. * cppinit.c (cpp_create_reader): Update. (builtin_array): Add _Pragma. * cpplib.h: Update comments. (NODE_DISABLED, BT_PRAGMA): New. (cpp_start_lookahead, cpp_stop_lookahead): Remove prototypes. * cppmacro.c (struct cpp_macro): Remove disabled. (builtin_macro): Return int, handle _Pragma, push the new token on the context stack. (funlike_invocation_p): Unconstify, update. (enter_macro_context): Handle builtins here. (replace_args, push_token_context, push_ptoken_context): Update for prototype changes. (_cpp_pop_context): Update. (cpp_get_token): Don't handle buitins, nor _Pragma here. (cpp_sys_macro_p): Update. (_cpp_free_definition): Clear disabled flag. (_cpp_create_definition): Upate. * cppmain.c: Update comments. From-SVN: r45948
Diffstat (limited to 'gcc/cpplib.h')
-rw-r--r--gcc/cpplib.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/gcc/cpplib.h b/gcc/cpplib.h
index 4404a40e5ef..507126e6ad5 100644
--- a/gcc/cpplib.h
+++ b/gcc/cpplib.h
@@ -168,7 +168,7 @@ struct cpp_string
#define BOL (1 << 6) /* Token at beginning of line. */
/* A preprocessing token. This has been carefully packed and should
- occupy 12 bytes on 32-bit hosts and 16 bytes on 64-bit hosts. */
+ occupy 16 bytes on 32-bit hosts and 24 bytes on 64-bit hosts. */
struct cpp_token
{
unsigned int line; /* Logical line of first char of token. */
@@ -353,7 +353,7 @@ struct cpp_options
/* Print column number in error messages. */
unsigned char show_column;
- /* Treat C++ alternate operator names special. */
+ /* Nonzero means handle C++ alternate operator names. */
unsigned char operator_names;
/* True if --help, --version or --target-help appeared in the
@@ -400,6 +400,7 @@ extern const char *progname;
#define NODE_BUILTIN (1 << 2) /* Builtin macro. */
#define NODE_DIAGNOSTIC (1 << 3) /* Possible diagnostic when lexed. */
#define NODE_WARN (1 << 4) /* Warn if redefined or undefined. */
+#define NODE_DISABLED (1 << 5) /* A disabled macro. */
/* Different flavors of hash node. */
enum node_type
@@ -409,7 +410,8 @@ enum node_type
NT_ASSERTION /* Predicate for #assert. */
};
-/* Different flavors of builtin macro. */
+/* Different flavors of builtin macro. _Pragma is an operator, but we
+ handle it with the builtin code for efficiency reasons. */
enum builtin_type
{
BT_SPECLINE = 0, /* `__LINE__' */
@@ -418,7 +420,8 @@ enum builtin_type
BT_BASE_FILE, /* `__BASE_FILE__' */
BT_INCLUDE_LEVEL, /* `__INCLUDE_LEVEL__' */
BT_TIME, /* `__TIME__' */
- BT_STDC /* `__STDC__' */
+ BT_STDC, /* `__STDC__' */
+ BT_PRAGMA /* `_Pragma' operator */
};
#define CPP_HASHNODE(HNODE) ((cpp_hashnode *) (HNODE))
@@ -568,8 +571,6 @@ extern void cpp_forall_identifiers PARAMS ((cpp_reader *,
/* In cppmacro.c */
extern void cpp_scan_nooutput PARAMS ((cpp_reader *));
-extern void cpp_start_lookahead PARAMS ((cpp_reader *));
-extern void cpp_stop_lookahead PARAMS ((cpp_reader *, int));
extern int cpp_sys_macro_p PARAMS ((cpp_reader *));
/* In cppfiles.c */