[PATCH] D61316: [clangd] Improvements to header mapping: more precise parsing of cppreference symbol pages.

Kadir Cetinkaya via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu May 2 00:53:09 PDT 2019


kadircet added inline comments.


================
Comment at: clangd/include-mapping/gen_std.py:90
+        # Decl may not be for the symbol name we're looking for.
+        if not re.search("\\b%s\\b" % symbol_name, text):
+          continue
----------------
does this also work with functions? For example floor will be written as:
```constexpr ToDuration floor(const duration<Rep, Period>& d);```
which does not contain floor as a word. https://en.cppreference.com/w/cpp/chrono/duration/floor


================
Comment at: clangd/include-mapping/gen_std.py:95
+        if was_decl:
+          current_headers = []
+        was_decl = False
----------------
why not perform clean-up unconditionally?


Repository:
  rCTE Clang Tools Extra

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

https://reviews.llvm.org/D61316





More information about the cfe-commits mailing list