zenilib: zenilib/jni/external/angle/src/compiler/preprocessor/Preprocessor.h Source File

zenilib 0.5.3.0

- Main Page
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Preprocessor.h
Go to the documentation of this file.
1 //
2 // Copyright (c) 2011 The ANGLE Project Authors. All rights reserved.
3 // Use of this source code is governed by a BSD-style license that can be
4 // found in the LICENSE file.
5 //
6
7 #ifndef COMPILER_PREPROCESSOR_PREPROCESSOR_H_
8 #define COMPILER_PREPROCESSOR_PREPROCESSOR_H_
9
10 #include <stddef.h>
11
12 #include "pp_utils.h"
13
14 namespace pp
15 {
16
17 class Diagnostics;
18 class DirectiveHandler;
19 struct PreprocessorImpl;
20 struct Token;
21
22 class Preprocessor
23 {
24 public:
25 Preprocessor(Diagnostics* diagnostics, DirectiveHandler* directiveHandler);
26 ~Preprocessor();
27
28 // count: specifies the number of elements in the string and length arrays.
29 // string: specifies an array of pointers to strings.
30 // length: specifies an array of string lengths.
31 // If length is NULL, each string is assumed to be null terminated.
32 // If length is a value other than NULL, it points to an array containing
33 // a string length for each of the corresponding elements of string.
34 // Each element in the length array may contain the length of the
35 // corresponding string or a value less than 0 to indicate that the string
36 // is null terminated.
37 bool init(size_t count, const char* const string[], const int length[]);
38 // Adds a pre-defined macro.
39 void predefineMacro(const char* name, int value);
40
41 void lex(Token* token);
42
43 private:
44 PP_DISALLOW_COPY_AND_ASSIGN(Preprocessor);
45
46 PreprocessorImpl* mImpl;
47 };
48
49 } // namespace pp
50 #endif // COMPILER_PREPROCESSOR_PREPROCESSOR_H_
51
pp::Preprocessor::init
bool init(size_t count, const char *const string[], const int length[])
Definition: Preprocessor.cpp:51
pp::Preprocessor
Definition: Preprocessor.h:22
pp
png_sPLT_entryp pp
Definition: pngrutil.c:1375
pp::Preprocessor::~Preprocessor
~Preprocessor()
Definition: Preprocessor.cpp:46
name
EGLImageKHR EGLint * name
Definition: eglext.h:284
length
GLsizei GLsizei * length
Definition: gl2ext.h:792
count
GLint GLsizei count
Definition: gl2ext.h:1011
pp::Preprocessor::predefineMacro
void predefineMacro(const char *name, int value)
Definition: Preprocessor.cpp:66
pp::Diagnostics
Definition: DiagnosticsBase.h:19
pp_utils.h
value
EGLSurface EGLint void ** value
Definition: eglext.h:301
pp::Token
Definition: Token.h:18
pp::Preprocessor::lex
void lex(Token *token)
Definition: Preprocessor.cpp:84
pp::DirectiveHandler
Definition: DirectiveHandlerBase.h:21
pp::Preprocessor::Preprocessor
Preprocessor(Diagnostics *diagnostics, DirectiveHandler *directiveHandler)
Definition: Preprocessor.cpp:40