Browse Source

* fixed bug, introduced in 6ff566350cbc2ecf8615cae6cc6792939a288ec8, due to
missing parenthesis

Nikolay Nikolov 2 years ago
parent
commit
3d55ac9d09
1 changed files with 2 additions and 2 deletions
  1. 2 2
      compiler/wasm32/nwasmcal.pas

+ 2 - 2
compiler/wasm32/nwasmcal.pas

@@ -70,8 +70,8 @@ implementation
           begin
             pvs:=tparavarsym(procdefinition.paras[paranr]);
             if is_wasm_reference_type(p.left.resultdef) and
-              (pvs.varspez in [vs_var,vs_constref]) or
-               ((pvs.varspez=vs_const) and (pvs.vardef.typ=formaldef)) then
+              ((pvs.varspez in [vs_var,vs_constref,vs_out]) or
+               ((pvs.varspez=vs_const) and (pvs.vardef.typ=formaldef))) then
               CGMessage(parser_e_wasm_ref_types_can_only_be_passed_by_value);
             Inc(paranr);
             p:=tcallparanode(tcallparanode(p).right);