From a67330d157ffe05602a3163c946aa97e29cb6bb5 Mon Sep 17 00:00:00 2001 From: Michal Krol Date: Tue, 16 May 2006 10:01:07 +0000 Subject: Cleanup code. Change constructor prototype. --- src/mesa/shader/slang/slang_compile_variable.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'src/mesa/shader/slang/slang_compile_variable.c') diff --git a/src/mesa/shader/slang/slang_compile_variable.c b/src/mesa/shader/slang/slang_compile_variable.c index 063709b303..b62743addb 100644 --- a/src/mesa/shader/slang/slang_compile_variable.c +++ b/src/mesa/shader/slang/slang_compile_variable.c @@ -120,14 +120,16 @@ int slang_fully_specified_type_copy (slang_fully_specified_type *x, const slang_ return 1; } -/* slang_variable_scope */ +/* + * slang_variable_scope + */ -int slang_variable_scope_construct (slang_variable_scope *scope) +GLvoid +_slang_variable_scope_ctr (slang_variable_scope *self) { - scope->variables = NULL; - scope->num_variables = 0; - scope->outer_scope = NULL; - return 1; + self->variables = NULL; + self->num_variables = 0; + self->outer_scope = NULL; } void slang_variable_scope_destruct (slang_variable_scope *scope) @@ -145,8 +147,7 @@ int slang_variable_scope_copy (slang_variable_scope *x, const slang_variable_sco slang_variable_scope z; unsigned int i; - if (!slang_variable_scope_construct (&z)) - return 0; + _slang_variable_scope_ctr (&z); z.variables = (slang_variable *) slang_alloc_malloc (y->num_variables * sizeof (slang_variable)); if (z.variables == NULL) { -- cgit v1.2.3