This revision was automatically updated to reflect the committed changes. Closed by commit rGc9081968ead1: [clangd] Fix typo in symbol kind conversion (authored by sammccall).
Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70309/new/ https://reviews.llvm.org/D70309 Files: clang-tools-extra/clangd/Protocol.cpp clang-tools-extra/clangd/unittests/FindSymbolsTests.cpp clang-tools-extra/clangd/unittests/XRefsTests.cpp Index: clang-tools-extra/clangd/unittests/XRefsTests.cpp =================================================================== --- clang-tools-extra/clangd/unittests/XRefsTests.cpp +++ clang-tools-extra/clangd/unittests/XRefsTests.cpp @@ -917,7 +917,7 @@ HI.NamespaceScope = ""; HI.Name = "X"; HI.LocalScope = "X::"; // FIXME: Should be X<T *>:: - HI.Kind = SymbolKind::Method; // FIXME: Should be Constructor + HI.Kind = SymbolKind::Constructor; HI.Type = "void ()"; // FIXME: Should be None HI.ReturnType = "void"; // FIXME: Should be None or X<T*> HI.Definition = "X<type - parameter - 0 - 0 *>()"; // FIXME: --> X() Index: clang-tools-extra/clangd/unittests/FindSymbolsTests.cpp =================================================================== --- clang-tools-extra/clangd/unittests/FindSymbolsTests.cpp +++ clang-tools-extra/clangd/unittests/FindSymbolsTests.cpp @@ -390,16 +390,16 @@ ElementsAreArray( {AllOf(WithName("Foo"), WithKind(SymbolKind::Class), Children()), AllOf(WithName("Foo"), WithKind(SymbolKind::Class), - Children(AllOf(WithName("Foo"), WithKind(SymbolKind::Method), - Children()), - AllOf(WithName("Foo"), WithKind(SymbolKind::Method), - Children()), + Children(AllOf(WithName("Foo"), + WithKind(SymbolKind::Constructor), Children()), + AllOf(WithName("Foo"), + WithKind(SymbolKind::Constructor), Children()), AllOf(WithName("f"), WithKind(SymbolKind::Method), Children()), AllOf(WithName("operator="), WithKind(SymbolKind::Method), Children()), - AllOf(WithName("~Foo"), WithKind(SymbolKind::Method), - Children()), + AllOf(WithName("~Foo"), + WithKind(SymbolKind::Constructor), Children()), AllOf(WithName("Nested"), WithKind(SymbolKind::Class), Children(AllOf(WithName("f"), WithKind(SymbolKind::Method), Index: clang-tools-extra/clangd/Protocol.cpp =================================================================== --- clang-tools-extra/clangd/Protocol.cpp +++ clang-tools-extra/clangd/Protocol.cpp @@ -257,7 +257,7 @@ return SymbolKind::Property; case index::SymbolKind::Constructor: case index::SymbolKind::Destructor: - return SymbolKind::Method; + return SymbolKind::Constructor; case index::SymbolKind::ConversionFunction: return SymbolKind::Function; case index::SymbolKind::Parameter:
Index: clang-tools-extra/clangd/unittests/XRefsTests.cpp =================================================================== --- clang-tools-extra/clangd/unittests/XRefsTests.cpp +++ clang-tools-extra/clangd/unittests/XRefsTests.cpp @@ -917,7 +917,7 @@ HI.NamespaceScope = ""; HI.Name = "X"; HI.LocalScope = "X::"; // FIXME: Should be X<T *>:: - HI.Kind = SymbolKind::Method; // FIXME: Should be Constructor + HI.Kind = SymbolKind::Constructor; HI.Type = "void ()"; // FIXME: Should be None HI.ReturnType = "void"; // FIXME: Should be None or X<T*> HI.Definition = "X<type - parameter - 0 - 0 *>()"; // FIXME: --> X() Index: clang-tools-extra/clangd/unittests/FindSymbolsTests.cpp =================================================================== --- clang-tools-extra/clangd/unittests/FindSymbolsTests.cpp +++ clang-tools-extra/clangd/unittests/FindSymbolsTests.cpp @@ -390,16 +390,16 @@ ElementsAreArray( {AllOf(WithName("Foo"), WithKind(SymbolKind::Class), Children()), AllOf(WithName("Foo"), WithKind(SymbolKind::Class), - Children(AllOf(WithName("Foo"), WithKind(SymbolKind::Method), - Children()), - AllOf(WithName("Foo"), WithKind(SymbolKind::Method), - Children()), + Children(AllOf(WithName("Foo"), + WithKind(SymbolKind::Constructor), Children()), + AllOf(WithName("Foo"), + WithKind(SymbolKind::Constructor), Children()), AllOf(WithName("f"), WithKind(SymbolKind::Method), Children()), AllOf(WithName("operator="), WithKind(SymbolKind::Method), Children()), - AllOf(WithName("~Foo"), WithKind(SymbolKind::Method), - Children()), + AllOf(WithName("~Foo"), + WithKind(SymbolKind::Constructor), Children()), AllOf(WithName("Nested"), WithKind(SymbolKind::Class), Children(AllOf(WithName("f"), WithKind(SymbolKind::Method), Index: clang-tools-extra/clangd/Protocol.cpp =================================================================== --- clang-tools-extra/clangd/Protocol.cpp +++ clang-tools-extra/clangd/Protocol.cpp @@ -257,7 +257,7 @@ return SymbolKind::Property; case index::SymbolKind::Constructor: case index::SymbolKind::Destructor: - return SymbolKind::Method; + return SymbolKind::Constructor; case index::SymbolKind::ConversionFunction: return SymbolKind::Function; case index::SymbolKind::Parameter:
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits