clang 19.0.0git
ExpressionTraits.h
Go to the documentation of this file.
1//===- ExpressionTraits.h - C++ Expression Traits Support Enums -*- C++ -*-===//
2//
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
6//
7//===----------------------------------------------------------------------===//
8///
9/// \file
10/// Defines enumerations for expression traits intrinsics.
11///
12//===----------------------------------------------------------------------===//
13
14#ifndef LLVM_CLANG_BASIC_EXPRESSIONTRAITS_H
15#define LLVM_CLANG_BASIC_EXPRESSIONTRAITS_H
16
17#include "llvm/Support/Compiler.h"
18
19namespace clang {
20
22#define EXPRESSION_TRAIT(Spelling, Name, Key) ET_##Name,
23#include "clang/Basic/TokenKinds.def"
24 ET_Last = -1 // ET_Last == last ET_XX in the enum.
25#define EXPRESSION_TRAIT(Spelling, Name, Key) +1
26#include "clang/Basic/TokenKinds.def"
27};
28
29/// Return the internal name of type trait \p T. Never null.
30const char *getTraitName(ExpressionTrait T) LLVM_READONLY;
31
32/// Return the spelling of the type trait \p TT. Never null.
33const char *getTraitSpelling(ExpressionTrait T) LLVM_READONLY;
34
35} // namespace clang
36
37#endif
The JSON file list parser is used to communicate input to InstallAPI.
const char * getTraitName(ExpressionTrait T) LLVM_READONLY
Return the internal name of type trait T. Never null.
const char * getTraitSpelling(ExpressionTrait T) LLVM_READONLY
Return the spelling of the type trait TT. Never null.