michael@0: // michael@0: // Copyright (c) 2012 The ANGLE Project Authors. All rights reserved. michael@0: // Use of this source code is governed by a BSD-style license that can be michael@0: // found in the LICENSE file. michael@0: // michael@0: michael@0: #ifndef COMPILER_PREPROCESSOR_MACRO_H_ michael@0: #define COMPILER_PREPROCESSOR_MACRO_H_ michael@0: michael@0: #include michael@0: #include michael@0: #include michael@0: michael@0: namespace pp michael@0: { michael@0: michael@0: struct Token; michael@0: michael@0: struct Macro michael@0: { michael@0: enum Type michael@0: { michael@0: kTypeObj, michael@0: kTypeFunc michael@0: }; michael@0: typedef std::vector Parameters; michael@0: typedef std::vector Replacements; michael@0: michael@0: Macro() : predefined(false), disabled(false), type(kTypeObj) { } michael@0: bool equals(const Macro& other) const; michael@0: michael@0: bool predefined; michael@0: mutable bool disabled; michael@0: michael@0: Type type; michael@0: std::string name; michael@0: Parameters parameters; michael@0: Replacements replacements; michael@0: }; michael@0: michael@0: typedef std::map MacroSet; michael@0: michael@0: } // namespace pp michael@0: #endif // COMPILER_PREPROCESSOR_MACRO_H_