diff options
author | Eric Anholt <[email protected]> | 2013-06-12 16:10:33 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2013-06-21 10:04:29 -0700 |
commit | 2b049aa53e12accf2c5be88d1d9b66dbcab47bfb (patch) | |
tree | a2037519d6f2dac013c53460d894d8a39cddd012 /src/glsl/ir_print_visitor.cpp | |
parent | d0abac22c3d963a0f02a41c7527fbb18071ea7c4 (diff) |
glsl: Make _mesa_print_ir() available from anything including ir.h.
No more forgetting to #include "ir_print_visitor.h" when doing temporary
debug code, or forgetting and leaving it in after removing your temporary
debug code. Also, available from C code so you don't need to move the
caller to C++ just to call it (see also: ir_to_mesa.cpp).
Reviewed-by: Kenneth Graunke <[email protected]>
Reviewed-by: Paul Berry <[email protected]>
Diffstat (limited to 'src/glsl/ir_print_visitor.cpp')
-rw-r--r-- | src/glsl/ir_print_visitor.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/glsl/ir_print_visitor.cpp b/src/glsl/ir_print_visitor.cpp index f01019c9877..ca973a5f38e 100644 --- a/src/glsl/ir_print_visitor.cpp +++ b/src/glsl/ir_print_visitor.cpp @@ -38,6 +38,7 @@ ir_instruction::print(void) const deconsted->accept(&v); } +extern "C" { void _mesa_print_ir(exec_list *instructions, struct _mesa_glsl_parse_state *state) @@ -69,6 +70,8 @@ _mesa_print_ir(exec_list *instructions, printf("\n)"); } +} /* extern "C" */ + ir_print_visitor::ir_print_visitor() { indentation = 0; |