Skip to content

Commit bced9b4

Browse files
committed
[AutoBump] Merge with 0195ec4 (Jan 15)
2 parents 7a03692 + 0195ec4 commit bced9b4

File tree

225 files changed

+7986
-4021
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

225 files changed

+7986
-4021
lines changed

clang/cmake/caches/hexagon-unknown-linux-musl-clang-cross.cmake

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ set(CLANG_LINKS_TO_CREATE
1010
hexagon-none-elf-clang
1111
hexagon-unknown-none-elf-clang++
1212
hexagon-unknown-none-elf-clang
13+
clang++
14+
clang-cl
15+
clang-cpp
1316
CACHE STRING "")
1417

1518
set(LLVM_INSTALL_TOOLCHAIN_ONLY ON CACHE BOOL "")

clang/docs/InternalsManual.rst

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,21 @@ Description:
276276
diagnostic instead of having to do things textually. The selected string
277277
does undergo formatting.
278278

279+
**"enum_select format**
280+
281+
Example:
282+
``unknown frobbling of a %enum_select<FrobbleKind>{%VarDecl{variable declaration}|%FuncDecl{function declaration}}0 when blarging``
283+
Class:
284+
Integers
285+
Description:
286+
This format specifier is used exactly like a ``select`` specifier, except it
287+
additionally generates a namespace, enumeration, and enumerator list based on
288+
the format string given. In the above case, a namespace is generated named
289+
``FrobbleKind`` that has an unscoped enumeration with the enumerators
290+
``VarDecl`` and ``FuncDecl`` which correspond to the values 0 and 1. This
291+
permits a clearer use of the ``Diag`` in source code, as the above could be
292+
called as: ``Diag(Loc, diag::frobble) << diag::FrobbleKind::VarDecl``.
293+
279294
**"plural" format**
280295

281296
Example:

clang/docs/ReleaseNotes.rst

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -316,8 +316,6 @@ C++23 Feature Support
316316
C++20 Feature Support
317317
^^^^^^^^^^^^^^^^^^^^^
318318

319-
- Implemented module level lookup for C++20 modules. (#GH90154)
320-
321319

322320
Resolutions to C++ Defect Reports
323321
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

clang/include/clang/AST/DeclBase.h

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -836,10 +836,6 @@ class alignas(8) Decl {
836836
return isFromASTFile() ? getImportedOwningModule() : getLocalOwningModule();
837837
}
838838

839-
/// Get the top level owning named module that owns this declaration if any.
840-
/// \returns nullptr if the declaration is not owned by a named module.
841-
Module *getTopLevelOwningNamedModule() const;
842-
843839
/// Get the module that owns this declaration for linkage purposes.
844840
/// There only ever is such a standard C++ module.
845841
Module *getOwningModuleForLinkage() const;
@@ -2726,12 +2722,6 @@ class DeclContext {
27262722
bool Deserialize = false) const;
27272723

27282724
private:
2729-
/// Lookup all external visible declarations and the external declarations
2730-
/// within the same module specified by \c NamedModule. We can't
2731-
/// get it from \c this since the same declaration may be declared in
2732-
/// multiple modules. e.g., namespace.
2733-
lookup_result lookupImpl(DeclarationName Name, Module *NamedModule) const;
2734-
27352725
/// Whether this declaration context has had externally visible
27362726
/// storage added since the last lookup. In this case, \c LookupPtr's
27372727
/// invariant may not hold and needs to be fixed before we perform

clang/include/clang/AST/ExternalASTMerger.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -141,8 +141,7 @@ class ExternalASTMerger : public ExternalASTSource {
141141

142142
/// Implementation of the ExternalASTSource API.
143143
bool FindExternalVisibleDeclsByName(const DeclContext *DC,
144-
DeclarationName Name,
145-
Module *NamedModule) override;
144+
DeclarationName Name) override;
146145

147146
/// Implementation of the ExternalASTSource API.
148147
void

clang/include/clang/AST/ExternalASTSource.h

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ class RecordDecl;
5151
class Selector;
5252
class Stmt;
5353
class TagDecl;
54-
class Module;
5554

5655
/// Abstract interface for external sources of AST nodes.
5756
///
@@ -146,20 +145,12 @@ class ExternalASTSource : public RefCountedBase<ExternalASTSource> {
146145
/// Find all declarations with the given name in the given context,
147146
/// and add them to the context by calling SetExternalVisibleDeclsForName
148147
/// or SetNoExternalVisibleDeclsForName.
149-
/// \param DC the context for lookup.
150-
/// \param Name the name of the declarations to find.
151-
/// \param NamedModule find declarations visible to the given module
152-
/// \c NamedModule . This may be different from owning module of \c DC since
153-
/// there are declarations (e.g., namespace declaration) can appear in
154-
/// multiple modules.
155-
///
156-
/// \return \c true if any declarations might have been found, and \c false
157-
/// if we definitely have no declarations with this name.
148+
/// \return \c true if any declarations might have been found, \c false if
149+
/// we definitely have no declarations with tbis name.
158150
///
159151
/// The default implementation of this method is a no-op returning \c false.
160-
virtual bool FindExternalVisibleDeclsByName(const DeclContext *DC,
161-
DeclarationName Name,
162-
Module *NamedModule);
152+
virtual bool
153+
FindExternalVisibleDeclsByName(const DeclContext *DC, DeclarationName Name);
163154

164155
/// Load all the external specializations for the Decl \param D if \param
165156
/// OnlyPartial is false. Otherwise, load all the external **partial**

clang/include/clang/Basic/Builtins.td

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4855,6 +4855,12 @@ def HLSLFirstBitHigh : LangBuiltin<"HLSL_LANG"> {
48554855
let Prototype = "void(...)";
48564856
}
48574857

4858+
def HLSLFirstBitLow : LangBuiltin<"HLSL_LANG"> {
4859+
let Spellings = ["__builtin_hlsl_elementwise_firstbitlow"];
4860+
let Attributes = [NoThrow, Const];
4861+
let Prototype = "void(...)";
4862+
}
4863+
48584864
def HLSLFrac : LangBuiltin<"HLSL_LANG"> {
48594865
let Spellings = ["__builtin_hlsl_elementwise_frac"];
48604866
let Attributes = [NoThrow, Const];

clang/include/clang/Basic/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,11 @@ macro(clang_diag_gen component)
33
-gen-clang-diags-defs -clang-component=${component}
44
SOURCE Diagnostic.td
55
TARGET ClangDiagnostic${component})
6+
7+
clang_tablegen(Diagnostic${component}Enums.inc
8+
-gen-clang-diags-enums -clang-component=${component}
9+
SOURCE Diagnostic.td
10+
TARGET ClangDiagnostic${component}Enums)
611
endmacro(clang_diag_gen)
712

813
clang_diag_gen(Analysis)

clang/include/clang/Basic/DiagnosticAST.h

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,19 @@ enum {
2222
#undef DIAG
2323
NUM_BUILTIN_AST_DIAGNOSTICS
2424
};
25+
26+
#define DIAG_ENUM(ENUM_NAME) \
27+
namespace ENUM_NAME { \
28+
enum {
29+
#define DIAG_ENUM_ITEM(IDX, NAME) NAME = IDX,
30+
#define DIAG_ENUM_END() \
31+
} \
32+
; \
33+
}
34+
#include "clang/Basic/DiagnosticASTEnums.inc"
35+
#undef DIAG_ENUM_END
36+
#undef DIAG_ENUM_ITEM
37+
#undef DIAG_ENUM
2538
} // end namespace diag
2639
} // end namespace clang
2740

clang/include/clang/Basic/DiagnosticAnalysis.h

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,18 @@ enum {
2222
#undef DIAG
2323
NUM_BUILTIN_ANALYSIS_DIAGNOSTICS
2424
};
25+
#define DIAG_ENUM(ENUM_NAME) \
26+
namespace ENUM_NAME { \
27+
enum {
28+
#define DIAG_ENUM_ITEM(IDX, NAME) NAME = IDX,
29+
#define DIAG_ENUM_END() \
30+
} \
31+
; \
32+
}
33+
#include "clang/Basic/DiagnosticAnalysisEnums.inc"
34+
#undef DIAG_ENUM_END
35+
#undef DIAG_ENUM_ITEM
36+
#undef DIAG_ENUM
2537
} // end namespace diag
2638
} // end namespace clang
2739

0 commit comments

Comments
 (0)