From bf496862be1ba863285aa2c1a2262b2d764c3e53 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Thu, 29 Jul 2010 14:36:59 -0700 Subject: glsl2: When dumping IR for debug, indent nested blocks. No more trying to match parens in my head when looking at the body of a short function containing an if statement. --- src/glsl/ir_print_visitor.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/glsl/ir_print_visitor.h') diff --git a/src/glsl/ir_print_visitor.h b/src/glsl/ir_print_visitor.h index 3db42e24ca..4feeb8c184 100644 --- a/src/glsl/ir_print_visitor.h +++ b/src/glsl/ir_print_visitor.h @@ -38,9 +38,8 @@ extern void _mesa_print_ir(exec_list *instructions, class ir_print_visitor : public ir_visitor { public: ir_print_visitor() - : deref_depth(0) { - /* empty */ + indentation = 0; } virtual ~ir_print_visitor() @@ -48,6 +47,8 @@ public: /* empty */ } + void indent(void); + /** * \name Visit methods * @@ -76,7 +77,7 @@ public: /*@}*/ private: - int deref_depth; + int indentation; }; #endif /* IR_PRINT_VISITOR_H */ -- cgit v1.2.3