diff options
author | Ian Romanick <ian.d.romanick@intel.com> | 2011-02-10 10:26:42 -0800 |
---|---|---|
committer | Ian Romanick <ian.d.romanick@intel.com> | 2011-02-21 13:07:29 -0800 |
commit | 497baf4e4a6a0a2f247c7bfb9bf69a2b93c2c19f (patch) | |
tree | 37859f056fb13140fabe45a26bb129ddd0014fc3 /src/glsl | |
parent | 5a1fbf0f70a1c2d444f61494f86e26ca866c31d5 (diff) |
Use C-style system headers in C++ code to avoid issues with std:: namespace
Diffstat (limited to 'src/glsl')
-rw-r--r-- | src/glsl/ast_expr.cpp | 5 | ||||
-rw-r--r-- | src/glsl/ast_type.cpp | 3 | ||||
-rw-r--r-- | src/glsl/glsl_parser_extras.h | 2 | ||||
-rw-r--r-- | src/glsl/glsl_types.cpp | 2 | ||||
-rw-r--r-- | src/glsl/glsl_types.h | 4 | ||||
-rw-r--r-- | src/glsl/hir_field_selection.cpp | 2 | ||||
-rw-r--r-- | src/glsl/ir.h | 4 | ||||
-rw-r--r-- | src/glsl/ir_import_prototypes.cpp | 1 | ||||
-rw-r--r-- | src/glsl/ir_print_visitor.cpp | 3 | ||||
-rw-r--r-- | src/glsl/ir_validate.cpp | 3 | ||||
-rw-r--r-- | src/glsl/link_functions.cpp | 4 | ||||
-rw-r--r-- | src/glsl/linker.cpp | 4 | ||||
-rw-r--r-- | src/glsl/loop_controls.cpp | 2 | ||||
-rw-r--r-- | src/glsl/lower_mat_op_to_vec.cpp | 3 | ||||
-rw-r--r-- | src/glsl/main.cpp | 2 | ||||
-rw-r--r-- | src/glsl/opt_constant_propagation.cpp | 2 | ||||
-rw-r--r-- | src/glsl/opt_constant_variable.cpp | 3 | ||||
-rw-r--r-- | src/glsl/opt_dead_code.cpp | 2 | ||||
-rw-r--r-- | src/glsl/opt_dead_code_local.cpp | 2 | ||||
-rw-r--r-- | src/glsl/opt_dead_functions.cpp | 2 | ||||
-rw-r--r-- | src/glsl/opt_structure_splitting.cpp | 3 | ||||
-rw-r--r-- | src/glsl/opt_swizzle_swizzle.cpp | 2 | ||||
-rw-r--r-- | src/glsl/opt_tree_grafting.cpp | 2 | ||||
-rw-r--r-- | src/glsl/s_expression.cpp | 3 |
24 files changed, 8 insertions, 57 deletions
diff --git a/src/glsl/ast_expr.cpp b/src/glsl/ast_expr.cpp index 974beb9f61..e624d11cf3 100644 --- a/src/glsl/ast_expr.cpp +++ b/src/glsl/ast_expr.cpp @@ -20,12 +20,9 @@ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER * DEALINGS IN THE SOFTWARE. */ -#include <cstdio> -#include <cassert> +#include <assert.h> #include "ast.h" -using std::printf; - const char * ast_expression::operator_string(enum ast_operators op) { diff --git a/src/glsl/ast_type.cpp b/src/glsl/ast_type.cpp index 5ddfeec872..c680ae5f67 100644 --- a/src/glsl/ast_type.cpp +++ b/src/glsl/ast_type.cpp @@ -21,14 +21,11 @@ * DEALINGS IN THE SOFTWARE. */ -#include <cstdio> #include "ast.h" extern "C" { #include "program/symbol_table.h" } -using std::printf; - void ast_type_specifier::print(void) const { diff --git a/src/glsl/glsl_parser_extras.h b/src/glsl/glsl_parser_extras.h index 8d4fca7877..10cb673c69 100644 --- a/src/glsl/glsl_parser_extras.h +++ b/src/glsl/glsl_parser_extras.h @@ -31,7 +31,7 @@ #ifdef __cplusplus -#include <cstdlib> +#include <stdlib.h> #include "glsl_symbol_table.h" enum _mesa_glsl_parser_targets { diff --git a/src/glsl/glsl_types.cpp b/src/glsl/glsl_types.cpp index f4d9242b25..76b4f3e4cb 100644 --- a/src/glsl/glsl_types.cpp +++ b/src/glsl/glsl_types.cpp @@ -21,7 +21,7 @@ * DEALINGS IN THE SOFTWARE. */ -#include <cstdio> +#include <stdio.h> #include <stdlib.h> #include "main/core.h" /* for Elements */ #include "glsl_symbol_table.h" diff --git a/src/glsl/glsl_types.h b/src/glsl/glsl_types.h index ab6858faac..61bf5e0cfd 100644 --- a/src/glsl/glsl_types.h +++ b/src/glsl/glsl_types.h @@ -26,8 +26,8 @@ #ifndef GLSL_TYPES_H #define GLSL_TYPES_H -#include <cstring> -#include <cassert> +#include <string.h> +#include <assert.h> extern "C" { #include "GL/gl.h" diff --git a/src/glsl/hir_field_selection.cpp b/src/glsl/hir_field_selection.cpp index 995f284fa5..3c33127b5f 100644 --- a/src/glsl/hir_field_selection.cpp +++ b/src/glsl/hir_field_selection.cpp @@ -27,8 +27,6 @@ #include "ast.h" #include "glsl_types.h" -using std::strcmp; - ir_rvalue * _mesa_ast_field_selection_to_hir(const ast_expression *expr, exec_list *instructions, diff --git a/src/glsl/ir.h b/src/glsl/ir.h index 74a8b06b1a..f2f902c0a7 100644 --- a/src/glsl/ir.h +++ b/src/glsl/ir.h @@ -26,8 +26,8 @@ #ifndef IR_H #define IR_H -#include <cstdio> -#include <cstdlib> +#include <stdio.h> +#include <stdlib.h> #include "ralloc.h" #include "glsl_types.h" diff --git a/src/glsl/ir_import_prototypes.cpp b/src/glsl/ir_import_prototypes.cpp index be5e0c1d3d..3585bf6b24 100644 --- a/src/glsl/ir_import_prototypes.cpp +++ b/src/glsl/ir_import_prototypes.cpp @@ -27,7 +27,6 @@ * * \author Ian Romanick */ -#include <cstdio> #include "ir.h" #include "glsl_symbol_table.h" diff --git a/src/glsl/ir_print_visitor.cpp b/src/glsl/ir_print_visitor.cpp index be76945a21..82ccc722fa 100644 --- a/src/glsl/ir_print_visitor.cpp +++ b/src/glsl/ir_print_visitor.cpp @@ -25,9 +25,6 @@ #include "glsl_types.h" #include "glsl_parser_extras.h" -using std::printf; -using std::strncmp; - static void print_type(const glsl_type *t); void diff --git a/src/glsl/ir_validate.cpp b/src/glsl/ir_validate.cpp index b0dd6c21f8..44d7549ea2 100644 --- a/src/glsl/ir_validate.cpp +++ b/src/glsl/ir_validate.cpp @@ -39,9 +39,6 @@ #include "program/hash_table.h" #include "glsl_types.h" -using std::abort; -using std::printf; - class ir_validate : public ir_hierarchical_visitor { public: ir_validate() diff --git a/src/glsl/link_functions.cpp b/src/glsl/link_functions.cpp index 861fa39b51..5851c14d62 100644 --- a/src/glsl/link_functions.cpp +++ b/src/glsl/link_functions.cpp @@ -21,10 +21,6 @@ * DEALINGS IN THE SOFTWARE. */ -#include <cstdlib> -#include <cstdio> -#include <cstdarg> - #include "main/core.h" #include "glsl_symbol_table.h" #include "glsl_parser_extras.h" diff --git a/src/glsl/linker.cpp b/src/glsl/linker.cpp index 6c003bb025..7db5c5e8d5 100644 --- a/src/glsl/linker.cpp +++ b/src/glsl/linker.cpp @@ -63,10 +63,6 @@ * * \author Ian Romanick <ian.d.romanick@intel.com> */ -#include <cstdlib> -#include <cstdio> -#include <cstdarg> -#include <climits> #include "main/core.h" #include "glsl_symbol_table.h" diff --git a/src/glsl/loop_controls.cpp b/src/glsl/loop_controls.cpp index 9eaa50f22d..9acbadc50e 100644 --- a/src/glsl/loop_controls.cpp +++ b/src/glsl/loop_controls.cpp @@ -21,7 +21,7 @@ * DEALINGS IN THE SOFTWARE. */ -#include <climits> +#include <limits.h> #include "main/compiler.h" #include "glsl_types.h" #include "loop_analysis.h" diff --git a/src/glsl/lower_mat_op_to_vec.cpp b/src/glsl/lower_mat_op_to_vec.cpp index bdc53a1f81..8cbbfa713c 100644 --- a/src/glsl/lower_mat_op_to_vec.cpp +++ b/src/glsl/lower_mat_op_to_vec.cpp @@ -35,9 +35,6 @@ #include "ir_expression_flattening.h" #include "glsl_types.h" -using std::abort; -using std::printf; - class ir_mat_op_to_vec_visitor : public ir_hierarchical_visitor { public: ir_mat_op_to_vec_visitor() diff --git a/src/glsl/main.cpp b/src/glsl/main.cpp index 6f05529314..096da93dce 100644 --- a/src/glsl/main.cpp +++ b/src/glsl/main.cpp @@ -20,8 +20,6 @@ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER * DEALINGS IN THE SOFTWARE. */ -#include <cstdlib> -#include <cstdio> #include <getopt.h> #include "ast.h" diff --git a/src/glsl/opt_constant_propagation.cpp b/src/glsl/opt_constant_propagation.cpp index 814f6e61f1..4425f42119 100644 --- a/src/glsl/opt_constant_propagation.cpp +++ b/src/glsl/opt_constant_propagation.cpp @@ -41,8 +41,6 @@ #include "ir_optimization.h" #include "glsl_types.h" -using std::memset; - class acp_entry : public exec_node { public: diff --git a/src/glsl/opt_constant_variable.cpp b/src/glsl/opt_constant_variable.cpp index 9dca0ff8e7..3fa7c3badc 100644 --- a/src/glsl/opt_constant_variable.cpp +++ b/src/glsl/opt_constant_variable.cpp @@ -37,9 +37,6 @@ #include "ir_optimization.h" #include "glsl_types.h" -using std::calloc; -using std::free; - struct assignment_entry { exec_node link; int assignment_count; diff --git a/src/glsl/opt_dead_code.cpp b/src/glsl/opt_dead_code.cpp index f47b9613e1..cb500d2d10 100644 --- a/src/glsl/opt_dead_code.cpp +++ b/src/glsl/opt_dead_code.cpp @@ -32,8 +32,6 @@ #include "ir_variable_refcount.h" #include "glsl_types.h" -using std::printf; - static bool debug = false; /** diff --git a/src/glsl/opt_dead_code_local.cpp b/src/glsl/opt_dead_code_local.cpp index f67b463374..39962bd602 100644 --- a/src/glsl/opt_dead_code_local.cpp +++ b/src/glsl/opt_dead_code_local.cpp @@ -38,8 +38,6 @@ #include "ir_optimization.h" #include "glsl_types.h" -using std::printf; - static bool debug = false; class assignment_entry : public exec_node diff --git a/src/glsl/opt_dead_functions.cpp b/src/glsl/opt_dead_functions.cpp index d72eb6115e..ceb79080a7 100644 --- a/src/glsl/opt_dead_functions.cpp +++ b/src/glsl/opt_dead_functions.cpp @@ -32,8 +32,6 @@ #include "ir_expression_flattening.h" #include "glsl_types.h" - using std::strcmp; - class signature_entry : public exec_node { public: diff --git a/src/glsl/opt_structure_splitting.cpp b/src/glsl/opt_structure_splitting.cpp index 8686da06af..014407c0be 100644 --- a/src/glsl/opt_structure_splitting.cpp +++ b/src/glsl/opt_structure_splitting.cpp @@ -38,9 +38,6 @@ #include "ir_rvalue_visitor.h" #include "glsl_types.h" -using std::printf; -using std::strcmp; - static bool debug = false; // XXX using variable_entry2 here to avoid collision (MSVC multiply-defined diff --git a/src/glsl/opt_swizzle_swizzle.cpp b/src/glsl/opt_swizzle_swizzle.cpp index 8d0e1051d8..bc442fa869 100644 --- a/src/glsl/opt_swizzle_swizzle.cpp +++ b/src/glsl/opt_swizzle_swizzle.cpp @@ -32,8 +32,6 @@ #include "ir_optimization.h" #include "glsl_types.h" -using std::memset; - class ir_swizzle_swizzle_visitor : public ir_hierarchical_visitor { public: ir_swizzle_swizzle_visitor() diff --git a/src/glsl/opt_tree_grafting.cpp b/src/glsl/opt_tree_grafting.cpp index a85ba82340..1ef940f9c7 100644 --- a/src/glsl/opt_tree_grafting.cpp +++ b/src/glsl/opt_tree_grafting.cpp @@ -54,8 +54,6 @@ #include "ir_optimization.h" #include "glsl_types.h" -using std::printf; - static bool debug = false; class ir_tree_grafting_visitor : public ir_hierarchical_visitor { diff --git a/src/glsl/s_expression.cpp b/src/glsl/s_expression.cpp index 77ac08ac7e..a922a50d3b 100644 --- a/src/glsl/s_expression.cpp +++ b/src/glsl/s_expression.cpp @@ -22,9 +22,6 @@ * DEALINGS IN THE SOFTWARE. */ -#include <cstdio> -#include <cstdlib> -#include <cstring> #include <assert.h> #include "s_expression.h" |