From 65ad1b9e4a9cdcac6c3e3890e022871929240e49 Mon Sep 17 00:00:00 2001 From: Jhonathan Abreu Date: Tue, 14 May 2024 15:57:21 -0400 Subject: [PATCH] Minor change --- src/runtime/MethodBinder.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/runtime/MethodBinder.cs b/src/runtime/MethodBinder.cs index 6ed522fb4..bef394ba7 100644 --- a/src/runtime/MethodBinder.cs +++ b/src/runtime/MethodBinder.cs @@ -696,9 +696,7 @@ internal Binding Bind(BorrowedReference inst, BorrowedReference args, BorrowedRe } var match = new MatchedMethod(kwargsMatched, margs, outs, mi); - // Only add matches using implicit conversion if no other regular matches were found, - // since we favor regular matches over matches using implicit conversion - if (usedImplicitConversion && matches.Count == 0) + if (usedImplicitConversion) { if (matchesUsingImplicitConversion == null) { @@ -709,7 +707,7 @@ internal Binding Bind(BorrowedReference inst, BorrowedReference args, BorrowedRe else { matches.Add(match); - // We don't need the matches using implicit conversion anymore + // We don't need the matches using implicit conversion anymore, we can free the memory matchesUsingImplicitConversion = null; } }