Browse Source

Make "none" calling convention ignore return_by_pointer flag

gingerBill 5 years ago
parent
commit
5ae924f988
1 changed files with 3 additions and 0 deletions
  1. 3 0
      src/check_type.cpp

+ 3 - 0
src/check_type.cpp

@@ -2361,6 +2361,9 @@ bool abi_compat_return_by_pointer(gbAllocator a, ProcCallingConvention cc, Type
 	if (abi_return_type == nullptr) {
 		return false;
 	}
+	if (cc == ProcCC_None) {
+		return false;
+	}
 
 	Type *single_type = reduce_tuple_to_single_type(abi_return_type);