X-Git-Url: http://git.tdb.fi/?p=libs%2Fgl.git;a=blobdiff_plain;f=source%2Fglsl%2Fgenerate.cpp;h=09a776afb7f60bb61d2bdc47d0a8f3fb9e470b3e;hp=29d52364c1506f1dc151aad780c584dc13b0eab6;hb=30f676460bb6e87fd7ca2532e507b97965c4a407;hpb=15562a0c458fd655b6907c285951085f38270e27 diff --git a/source/glsl/generate.cpp b/source/glsl/generate.cpp index 29d52364..09a776af 100644 --- a/source/glsl/generate.cpp +++ b/source/glsl/generate.cpp @@ -591,11 +591,11 @@ void ExpressionResolver::convert_to(RefPtr &expr, BasicTypeDeclarati bool ExpressionResolver::convert_to_element(RefPtr &expr, BasicTypeDeclaration &elem_type) { - if(BasicTypeDeclaration *expr_type = dynamic_cast(expr->type)) + if(BasicTypeDeclaration *expr_basic = dynamic_cast(expr->type)) { BasicTypeDeclaration *to_type = &elem_type; - if(is_vector_or_matrix(*expr_type)) - to_type = find_type(elem_type, expr_type->kind, expr_type->size); + if(is_vector_or_matrix(*expr_basic)) + to_type = find_type(elem_type, expr_basic->kind, expr_basic->size); if(to_type) { convert_to(expr, *to_type);