aboutsummaryrefslogtreecommitdiff
path: root/src/check_decl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/check_decl.cpp')
-rw-r--r--src/check_decl.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/check_decl.cpp b/src/check_decl.cpp
index 842f8653c..f7df73953 100644
--- a/src/check_decl.cpp
+++ b/src/check_decl.cpp
@@ -851,6 +851,12 @@ gb_internal bool signature_parameter_similar_enough(Type *x, Type *y) {
}
}
+ Type *x_base = base_type(x);
+ Type *y_base = base_type(y);
+ if (x_base->kind == y_base->kind && x_base->kind == Type_Struct) {
+ return type_size_of(x_base) == type_size_of(y_base) && type_align_of(x_base) == type_align_of(y_base);
+ }
+
return are_types_identical(x, y);
}