[PATCH] D73451: [clangd] Update the include mappings for std symbols.

Kadir Cetinkaya via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jan 27 03:56:27 PST 2020


kadircet added a comment.

In D73451#1841595 <https://reviews.llvm.org/D73451#1841595>, @hokein wrote:

> In D73451#1841510 <https://reviews.llvm.org/D73451#1841510>, @kadircet wrote:
>
> > we seem to be missing some symbols now, like `polymorphic_allocator` `random_shuffle` `gets` etc.
>
>
> yeap, two majoir reasons:
>
> - some symbols <https://en.cppreference.com/w/cpp/symbol_index/zombie_names> are deprecated/removed in new C++ standard, e.g. random_shuffle is removed in C++17
> - missing information in cppreference page, e.g. there is no header section for `polymorphic_allocator` in the offline cppreference page :(
>
>   Regarding those deprecated symbols, we could handle them according to  which C++ standard we are using, as we have enough information from cppreferences <https://en.cppreference.com/w/cpp/symbol_index/zombie_names>, but it needs some work, and is low priority.


Ah I see, it is sad that cppreference just deletes those from symbol index, instead of marking them as `delete after c++XX`, I am not sure when the symbols introduced by this patch are added(but it is likely that they are introduced with c++20), so I think losing existing symbols
has a worse effect than not having information regarding c++20 symbols. Because these are symbols that are likely to be used by current c++ developers and supported by clangd, and it will be a regression to drop those, whereas the newly introduced symbols are already
missing.

So maybe postpone this update until we implement parsing of zombie_names page as well, also please file a bug either way so that we don't lose track.

> 
> 
>> and there seems to be a functional change to the parser. Are they intentional, if so why?
> 
> The change should be NFC, it just makes the parser more robust on invalid links, the new version of the cppreference have invalid links on the symbol index page.
>  updated the code to make it clearer.

maybe separate that out into a different patch so that it stands out?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D73451/new/

https://reviews.llvm.org/D73451





More information about the cfe-commits mailing list