================
@@ -1185,29 +1224,24 @@ class YAMLConverter {
 
     llvm::StringSet<> KnownMethodSelectors;
     for (const auto &CXXMethod : T.Methods) {
-      auto WhereParameters = getWhereParameters(CXXMethod);
-      if (!WhereParameters.first)
+      auto WhereSelector = getWhereSelector(CXXMethod, /*AllowObject=*/true);
+      if (!WhereSelector)
         continue;
 
-      if (WhereParameters.second) {
-        if (!KnownMethodSelectors
-                 .insert(getFunctionSelectorKey(CXXMethod.Name,
-                                                *WhereParameters.second))
-                 .second) {
+      if (WhereSelector->Parameters || WhereSelector->Object) {
+        std::string DuplicateKey =
----------------
Xazax-hun wrote:

Alternatively, I am also wondering, if we already have `operator==` for the 
selectors we only might need hashes added for them and maybe we could use a 
hash set on the selectors for deduplication directly instead of creating 
separate string keys? 

https://github.com/llvm/llvm-project/pull/216148
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to