summaryrefslogtreecommitdiffstats
path: root/src/glsl/ast.h
diff options
context:
space:
mode:
authorPaul Berry <stereotype441@gmail.com>2014-01-31 09:50:37 -0800
committerPaul Berry <stereotype441@gmail.com>2014-02-04 09:06:09 -0800
commit56790856b303ad5ba86d7eb261ade91edaa3ee0b (patch)
tree5009ee06b838c62e8f2b35f49b30c765635e5441 /src/glsl/ast.h
parent933be19cdf97aed977cd656e5c15c99cbdb52b7f (diff)
downloadexternal_mesa3d-56790856b303ad5ba86d7eb261ade91edaa3ee0b.zip
external_mesa3d-56790856b303ad5ba86d7eb261ade91edaa3ee0b.tar.gz
external_mesa3d-56790856b303ad5ba86d7eb261ade91edaa3ee0b.tar.bz2
glsl: Make condition_to_hir() callable from outside ast_iteration_statement.
In addition to making it public, we also need to change its first argument from an ir_loop * to an exec_list *, so that it can be used to insert the condition anywhere in the IR (rather than just in the body of the loop). This will be necessary in order to make continue statements work properly in do-while loops. Cc: mesa-stable@lists.freedesktop.org Acked-by: Carl Worth <cworth@cworth.org> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Matt Turner <mattst88@gmail.com>
Diffstat (limited to 'src/glsl/ast.h')
-rw-r--r--src/glsl/ast.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/glsl/ast.h b/src/glsl/ast.h
index 0bda28d..2d6f3a2 100644
--- a/src/glsl/ast.h
+++ b/src/glsl/ast.h
@@ -888,14 +888,13 @@ public:
ast_node *body;
-private:
/**
* Generate IR from the condition of a loop
*
* This is factored out of ::hir because some loops have the condition
* test at the top (for and while), and others have it at the end (do-while).
*/
- void condition_to_hir(class ir_loop *, struct _mesa_glsl_parse_state *);
+ void condition_to_hir(exec_list *, struct _mesa_glsl_parse_state *);
};