From: monojenkins Date: Mon, 10 Aug 2020 12:31:04 +0000 (-0400) Subject: [aot] Fix the handling of r4/r8 parameter types with attributes during generic sharin... X-Git-Tag: submit/tizen/20210909.063632~6116 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7281349206c09e0098ae0e4184f2b46225f85b1e;p=platform%2Fupstream%2Fdotnet%2Fruntime.git [aot] Fix the handling of r4/r8 parameter types with attributes during generic sharing. (#40498) The attributes need to be ignored as with the other types, otherwise gsharedvt wrappers for signatures with parameters like double f = default will not be found. Fixes https://github.com/mono/mono/issues/20195. Co-authored-by: vargaz --- diff --git a/src/mono/mono/mini/mini-generic-sharing.c b/src/mono/mono/mini/mini-generic-sharing.c index 5fb8bbb..86f7066 100644 --- a/src/mono/mono/mini/mini-generic-sharing.c +++ b/src/mono/mono/mini/mini-generic-sharing.c @@ -1276,6 +1276,10 @@ get_wrapper_shared_type_full (MonoType *t, gboolean is_field) #else return m_class_get_byval_arg (mono_defaults.uint32_class); #endif + case MONO_TYPE_R4: + return m_class_get_byval_arg (mono_defaults.single_class); + case MONO_TYPE_R8: + return m_class_get_byval_arg (mono_defaults.double_class); case MONO_TYPE_OBJECT: case MONO_TYPE_CLASS: case MONO_TYPE_SZARRAY: