X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fglsl%2Fresolve.cpp;fp=source%2Fglsl%2Fresolve.cpp;h=82c0a367dfd2e70f89d04e9b9335cb4df23c2ded;hb=ac876d8c2ea01e0383709a8a045c3e592c9564eb;hp=115624c496639e5413077779e28aabd9c2321ce6;hpb=215d5bed27ad3de92557ae1b631695a036d29741;p=libs%2Fgl.git diff --git a/source/glsl/resolve.cpp b/source/glsl/resolve.cpp index 115624c4..82c0a367 100644 --- a/source/glsl/resolve.cpp +++ b/source/glsl/resolve.cpp @@ -1089,6 +1089,11 @@ void ExpressionResolver::visit(FunctionCall &call) { TypeDeclaration *arg_type = call.arguments[i]->type; TypeDeclaration *param_type = call.declaration->parameters[i]->type_declaration; + if(arg_type==param_type) + continue; + else if(!arg_type || !param_type) + return; + BasicTypeDeclaration *arg_basic = dynamic_cast(arg_type); BasicTypeDeclaration *param_basic = dynamic_cast(param_type); if(arg_basic && param_basic) @@ -1097,8 +1102,6 @@ void ExpressionResolver::visit(FunctionCall &call) if(compat==RIGHT_CONVERTIBLE) convert_to(call.arguments[i], *param_basic); } - else if(!arg_type || !param_type || arg_type!=param_type) - return; } resolve(call, call.declaration->return_type_declaration, false); }