1 //===--- Attributes.h - Attributes header -----------------------*- C++ -*-===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
9 #ifndef LLVM_CLANG_BASIC_ATTRIBUTES_H
10 #define LLVM_CLANG_BASIC_ATTRIBUTES_H
12 #include "clang/Basic/LangOptions.h"
13 #include "clang/Basic/TargetInfo.h"
19 enum class AttrSyntax {
20 /// Is the identifier known as a GNU-style attribute?
22 /// Is the identifier known as a __declspec-style attribute?
24 /// Is the identifier known as a [] Microsoft-style attribute?
26 // Is the identifier known as a C++-style attribute?
28 // Is the identifier known as a C-style attribute?
30 // Is the identifier known as a pragma attribute?
34 /// Return the version number associated with the attribute if we
35 /// recognize and implement the attribute specified by the given information.
36 int hasAttribute(AttrSyntax Syntax, const IdentifierInfo *Scope,
37 const IdentifierInfo *Attr, const TargetInfo &Target,
38 const LangOptions &LangOpts);
40 } // end namespace clang
42 #endif // LLVM_CLANG_BASIC_ATTRIBUTES_H