AttrSubjectMatchRules.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. #pragma once
  2. #ifdef __GNUC__
  3. #pragma GCC diagnostic push
  4. #pragma GCC diagnostic ignored "-Wunused-parameter"
  5. #endif
  6. //===-- AttrSubjectMatchRules.h - Attribute subject match rules -*- C++ -*-===//
  7. //
  8. // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
  9. // See https://llvm.org/LICENSE.txt for license information.
  10. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  11. //
  12. //===----------------------------------------------------------------------===//
  13. #ifndef LLVM_CLANG_BASIC_ATTRSUBJECTMATCHRULES_H
  14. #define LLVM_CLANG_BASIC_ATTRSUBJECTMATCHRULES_H
  15. #include "clang/Basic/SourceLocation.h"
  16. #include "llvm/ADT/DenseMap.h"
  17. namespace clang {
  18. namespace attr {
  19. /// A list of all the recognized kinds of attributes.
  20. enum SubjectMatchRule {
  21. #define ATTR_MATCH_RULE(X, Spelling, IsAbstract) X,
  22. #include "clang/Basic/AttrSubMatchRulesList.inc"
  23. };
  24. const char *getSubjectMatchRuleSpelling(SubjectMatchRule Rule);
  25. using ParsedSubjectMatchRuleSet = llvm::DenseMap<int, SourceRange>;
  26. } // end namespace attr
  27. } // end namespace clang
  28. #endif
  29. #ifdef __GNUC__
  30. #pragma GCC diagnostic pop
  31. #endif