+ else if(var.block_declaration)
+ {
+ if(stage->type==Stage::VERTEX && var.interface=="in")
+ error(var, "Interface block not allowed on vertex shader input");
+ else if(stage->type==Stage::FRAGMENT && var.interface=="out")
+ error(var, "Interface block not allowed on fragment shader output");
+ }
+ else if(kind==BasicTypeDeclaration::VOID)
+ error(var, "Type 'void' not allowed on variable");
+ else if(kind==BasicTypeDeclaration::BOOL && var.source!=BUILTIN_SOURCE)
+ {
+ if(scope==INTERFACE_BLOCK)
+ error(var, "Type 'bool' not allowed in an interface block");
+ else if(!var.interface.empty())
+ error(var, "Type 'bool' not allowed on interface variable");
+ }
+
+ if(var.array && !var.array_size)
+ error(var, "Array must have a size");