Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: downloads/boost_1_34_1/boost/wave/cpplexer/re2clex/scanner.hpp @ 35

Last change on this file since 35 was 29, checked in by landauf, 17 years ago

updated boost from 1_33_1 to 1_34_1

File size: 3.1 KB
Line 
1/*=============================================================================
2    Boost.Wave: A Standard compliant C++ preprocessor library
3
4    http://www.boost.org/
5   
6    Copyright (c) 2001 Daniel C. Nuffer.
7    Copyright (c) 2001-2007 Hartmut Kaiser.
8    Distributed under the Boost Software License, Version 1.0. (See accompanying
9    file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
10=============================================================================*/
11
12#if !defined(SCANNER_HPP_F4FB01EB_E75C_4537_A146_D34B9895EF37_INCLUDED)
13#define SCANNER_HPP_F4FB01EB_E75C_4537_A146_D34B9895EF37_INCLUDED
14
15#include <boost/wave/wave_config.hpp>
16#include <boost/wave/cpplexer/re2clex/aq.hpp>
17
18// this must occur after all of the includes and before any code appears
19#ifdef BOOST_HAS_ABI_HEADERS
20#include BOOST_ABI_PREFIX
21#endif
22
23///////////////////////////////////////////////////////////////////////////////
24namespace boost {
25namespace wave {
26namespace cpplexer {
27namespace re2clex {
28
29struct Scanner;
30typedef unsigned char uchar;
31typedef int (* ReportErrorProc)(struct Scanner const *, char const *, ...);
32
33typedef struct Scanner {
34    uchar* first;   /* start of input buffer */
35    uchar* act;     /* act position of input buffer */
36    uchar* last;    /* end (one past last char) of input buffer */
37    uchar* bot;     /* beginning of the current buffer */
38    uchar* top;     /* top of the current buffer */
39    uchar* eof;     /* when we read in the last buffer, will point 1 past the
40                       end of the file, otherwise 0 */
41    uchar* tok;     /* points to the beginning of the current token */
42    uchar* ptr;     /* used for YYMARKER - saves backtracking info */
43    uchar* cur;     /* saves the cursor (maybe is redundant with tok?) */
44    uchar* lim;     /* used for YYLIMIT - points to the end of the buffer */
45                    /* (lim == top) except for the last buffer, it points to
46                       the end of the input (lim == eof - 1) */
47    unsigned int line;          /* current line being lex'ed */
48    unsigned int column;        /* current token start column position */
49    unsigned int curr_column;   /* current column position */
50    ReportErrorProc error_proc; /* must be != 0, this function is called to
51                                   report an error */
52    char const *file_name;      /* name of the lex'ed file */
53    aq_queue eol_offsets;
54    bool enable_ms_extensions;   /* enable MS extensions */
55    bool act_in_c99_mode;        /* lexer works in C99 mode */
56    bool detect_pp_numbers;      /* lexer should prefer to detect pp-numbers */
57    bool enable_import_keyword;  /* recognize import as a keyword */
58    bool single_line_only;       /* don't report missing eol's in C++ comments */
59} Scanner;
60
61///////////////////////////////////////////////////////////////////////////////
62}   // namespace re2clex
63}   // namespace cpplexer
64}   // namespace wave
65}   // namespace boost
66
67// the suffix header occurs after all of the code
68#ifdef BOOST_HAS_ABI_HEADERS
69#include BOOST_ABI_SUFFIX
70#endif
71
72#endif // !defined(SCANNER_HPP_F4FB01EB_E75C_4537_A146_D34B9895EF37_INCLUDED)
Note: See TracBrowser for help on using the repository browser.