clang 22.0.0git
ASTDiagnostic.h
Go to the documentation of this file.
1/===--- ASTDiagnostic.h - Diagnostics for the AST library ------*- 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#ifndef LLVM_CLANG_AST_ASTDIAGNOSTIC_H
10#define LLVM_CLANG_AST_ASTDIAGNOSTIC_H
11
12#include "clang/AST/Type.h"
15
16namespace clang {
17 / DiagnosticsEngine argument formatting function for diagnostics that
18 / involve AST nodes.
19 /
20 / This function formats diagnostic arguments for various AST nodes,
21 / including types, declaration names, nested name specifiers, and
22 / declaration contexts, into strings that can be printed as part of
23 / diagnostics. It is meant to be used as the argument to
24 / \c DiagnosticsEngine::SetArgToStringFn(), where the cookie is an \c
25 / ASTContext pointer.
28 intptr_t Val,
29 StringRef Modifier,
30 StringRef Argument,
33 void *Cookie,
34 ArrayRef<intptr_t> QualTypeVals);
35
36 / Returns a desugared version of the QualType, and marks ShouldAKA as true
37 / whenever we remove significant sugar from the type. Make sure ShouldAKA
38 / is initialized before passing it in.
40 bool &ShouldAKA);
41
42 std::string FormatUTFCodeUnitAsCodepoint(unsigned Value, QualType T);
43
44} / end namespace clang
45
46#endif
Defines the Diagnostic-related interfaces.
C Language Family Type Representation.
Holds long-lived AST nodes (such as types and decls) that can be referred to throughout the semantic ...
Definition ASTContext.h:220
A (possibly-)qualified type.
Definition TypeBase.h:937
The JSON file list parser is used to communicate input to InstallAPI.
QualType desugarForDiagnostic(ASTContext &Context, QualType QT, bool &ShouldAKA)
Returns a desugared version of the QualType, and marks ShouldAKA as true whenever we remove significa...
std::string FormatUTFCodeUnitAsCodepoint(unsigned Value, QualType T)
const FunctionProtoType * T
void FormatASTNodeDiagnosticArgument(DiagnosticsEngine::ArgumentKind Kind, intptr_t Val, StringRef Modifier, StringRef Argument, ArrayRef< DiagnosticsEngine::ArgumentValue > PrevArgs, SmallVectorImpl< char > &Output, void *Cookie, ArrayRef< intptr_t > QualTypeVals)
DiagnosticsEngine argument formatting function for diagnostics that involve AST nodes.
__INTPTR_TYPE__ intptr_t
A signed integer type with the property that any valid pointer to void can be converted to this type,...

Follow Lee on X/Twitter - Father, Husband, Serial builder creating AI, crypto, games & web tools. We are friends :) AI Will Come To Life!

Check out: eBank.nz (Art Generator) | Netwrck.com (AI Tools) | Text-Generator.io (AI API) | BitBank.nz (Crypto AI) | ReadingTime (Kids Reading) | RewordGame | BigMultiplayerChess | WebFiddle | How.nz | Helix AI Assistant