代码之家  ›  专栏  ›  技术社区  ›  TheAhmad

列表叮当查询匹配器

  •  0
  • TheAhmad  · 技术社区  · 8 年前

    有没有办法列出所有可能的匹配者 clang-query AST matcher reference 列表不一定是最新版本。连名单都在 ASTMatchers.h 叮当的标题( clang-6.0.0 equalsNode matcher包含在列表中,但在中不可用 叮当查询

    1 回复  |  直到 8 年前
        1
  •  0
  •   TheAhmad    8 年前

    看来有些媒人有缺陷,还在进行中。因此,尽管他们的名字包含在 ASTMatchers.h clang-6.0.0/lib/ASTMatchers/Dynamic/Registry.cpp:Line 95 :

    // TODO: Here is the list of the missing matchers, grouped by reason.
    //
    // Need Variant/Parser fixes:
    // ofKind
    //
    // Polymorphic + argument overload:
    // findAll
    //
    // Other:
    // equalsNode
    
    REGISTER_OVERLOADED_2(callee);
    ...
    

    equalsNode 也是失踪的媒人之一。支持的匹配器在以下行中注册。