diff options
author | marha <marha@users.sourceforge.net> | 2012-02-06 08:33:58 +0100 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-02-06 08:33:58 +0100 |
commit | ebb6162f9cbc1af0fac0b670b5aa38c8bb7a7446 (patch) | |
tree | 30d7b35b3c3d34b4539b57e1d92951ac5c8a3dfe /mesalib/src/glsl/glsl_parser_extras.h | |
parent | 68320ff05946f092b6836754c6267b1dff2f4633 (diff) | |
parent | ada3d2c30b5a7a1a79e128b7326d50c3bab77a8a (diff) | |
download | vcxsrv-ebb6162f9cbc1af0fac0b670b5aa38c8bb7a7446.tar.gz vcxsrv-ebb6162f9cbc1af0fac0b670b5aa38c8bb7a7446.tar.bz2 vcxsrv-ebb6162f9cbc1af0fac0b670b5aa38c8bb7a7446.zip |
Merge remote-tracking branch 'origin/released'
Diffstat (limited to 'mesalib/src/glsl/glsl_parser_extras.h')
-rw-r--r-- | mesalib/src/glsl/glsl_parser_extras.h | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/mesalib/src/glsl/glsl_parser_extras.h b/mesalib/src/glsl/glsl_parser_extras.h index ee714637d..ce207ecda 100644 --- a/mesalib/src/glsl/glsl_parser_extras.h +++ b/mesalib/src/glsl/glsl_parser_extras.h @@ -42,6 +42,20 @@ enum _mesa_glsl_parser_targets { struct gl_context; +struct glsl_switch_state { + /** Temporary variables needed for switch statement. */ + ir_variable *test_var; + ir_variable *is_fallthru_var; + ir_variable *is_break_var; + class ast_switch_statement *switch_nesting_ast; + + /** Table of constant values already used in case labels */ + struct hash_table *labels_ht; + class ast_case_label *previous_default; + + bool is_switch_innermost; // if switch stmt is closest to break, ... +}; + struct _mesa_glsl_parse_state { _mesa_glsl_parse_state(struct gl_context *ctx, GLenum target, void *mem_ctx); @@ -154,13 +168,8 @@ struct _mesa_glsl_parse_state { /** Loop or switch statement containing the current instructions. */ class ast_iteration_statement *loop_nesting_ast; - class ast_switch_statement *switch_nesting_ast; - bool is_switch_innermost; // if switch stmt is closest to break, ... - /** Temporary variables needed for switch statement. */ - ir_variable *test_var; - ir_variable *is_fallthru_var; - ir_variable *is_break_var; + struct glsl_switch_state switch_state; /** List of structures defined in user code. */ const glsl_type **user_structures; |