<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/clang/lib/AST/DeclPrinter.cpp, branch users/wangpc-pp/spr/aarch64-remove-usage-of-postrascheduler</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/'/>
<entry>
<title>[clang] NFCI: use TemplateArgumentLoc for type-param DefaultArgument (#92854)</title>
<updated>2024-05-21T23:27:50+00:00</updated>
<author>
<name>Matheus Izvekov</name>
<email>mizvekov@gmail.com</email>
</author>
<published>2024-05-21T23:27:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=e42b799bb28815431f2c5a95f7e13fde3f1b36a1'/>
<id>e42b799bb28815431f2c5a95f7e13fde3f1b36a1</id>
<content type='text'>
This is an enabler for a future patch.

This allows an type-parameter default argument to be set as an arbitrary
TemplateArgument, not just a type.
This allows template parameter packs to have default arguments in the
AST, even though the language proper doesn't support the syntax for it.

This will be used in a later patch which synthesizes template parameter
lists with arbitrary default arguments taken from template
specializations.

There are a few places we used SubsType, because we only had a type, now
we use SubstTemplateArgument.
SubstTemplateArgument was missing arguments for setting Instantiation
location and entity names.
Adding those is needed so we don't regress in diagnostics.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is an enabler for a future patch.

This allows an type-parameter default argument to be set as an arbitrary
TemplateArgument, not just a type.
This allows template parameter packs to have default arguments in the
AST, even though the language proper doesn't support the syntax for it.

This will be used in a later patch which synthesizes template parameter
lists with arbitrary default arguments taken from template
specializations.

There are a few places we used SubsType, because we only had a type, now
we use SubstTemplateArgument.
SubstTemplateArgument was missing arguments for setting Instantiation
location and entity names.
Adding those is needed so we don't regress in diagnostics.</pre>
</div>
</content>
</entry>
<entry>
<title>Reapply "[Clang] Unify interface for accessing template arguments as written for class/variable template specializations (#81642)" (#91393)</title>
<updated>2024-05-14T20:09:57+00:00</updated>
<author>
<name>Krystian Stasiowski</name>
<email>sdkrystian@gmail.com</email>
</author>
<published>2024-05-14T20:09:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=12028373020739b388eb2b8141742509f1764e3c'/>
<id>12028373020739b388eb2b8141742509f1764e3c</id>
<content type='text'>
Reapplies #81642, fixing the crash which occurs when running the lldb test suite.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Reapplies #81642, fixing the crash which occurs when running the lldb test suite.</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "[Clang] Unify interface for accessing template arguments as written for class/variable template specializations (#81642)"</title>
<updated>2024-05-07T20:03:14+00:00</updated>
<author>
<name>Adrian Prantl</name>
<email>aprantl@apple.com</email>
</author>
<published>2024-05-07T20:02:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=c6855ab24e63feb432aac4f86eb70ac16d76c921'/>
<id>c6855ab24e63feb432aac4f86eb70ac16d76c921</id>
<content type='text'>
This reverts commit 7115ed0fff027b65fa76fdfae215ed1382ed1473.

This commit broke several LLDB tests.

https://green.lab.llvm.org/job/llvm.org/view/LLDB/job/as-lldb-cmake/3480/
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit 7115ed0fff027b65fa76fdfae215ed1382ed1473.

This commit broke several LLDB tests.

https://green.lab.llvm.org/job/llvm.org/view/LLDB/job/as-lldb-cmake/3480/
</pre>
</div>
</content>
</entry>
<entry>
<title>[Clang] Unify interface for accessing template arguments as written for class/variable template specializations (#81642)</title>
<updated>2024-05-07T18:45:52+00:00</updated>
<author>
<name>Krystian Stasiowski</name>
<email>sdkrystian@gmail.com</email>
</author>
<published>2024-05-07T18:45:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=7115ed0fff027b65fa76fdfae215ed1382ed1473'/>
<id>7115ed0fff027b65fa76fdfae215ed1382ed1473</id>
<content type='text'>
Our current method of storing the template arguments as written for
`(Class/Var)Template(Partial)SpecializationDecl` suffers from a number
of flaws:
- We use `TypeSourceInfo` to store `TemplateArgumentLocs` for class
template/variable template partial/explicit specializations. For
variable template specializations, this is a rather unintuitive hack (as
we store a non-type specialization as a type). Moreover, we don't ever
*need* the type as written -- in almost all cases, we only want the
template arguments (e.g. in tooling use-cases).
- The template arguments as written are stored in a number of redundant
data members. For example, `(Class/Var)TemplatePartialSpecialization`
have their own `ArgsAsWritten` member that stores an
`ASTTemplateArgumentListInfo` (the template arguments).
`VarTemplateSpecializationDecl` has yet _another_ redundant member
"`TemplateArgsInfo`" that also stores an `ASTTemplateArgumentListInfo`.

This patch eliminates all
`(Class/Var)Template(Partial)SpecializationDecl` members which store the
template arguments as written, and turns the `ExplicitInfo` member into
a `llvm::PointerUnion&lt;const ASTTemplateArgumentListInfo*,
ExplicitInstantiationInfo*&gt;` (to avoid unnecessary allocations when the
declaration isn't an explicit instantiation). The template arguments as
written are now accessed via `getTemplateArgsWritten` in all cases.

The "most breaking" change is to AST Matchers, insofar that `hasTypeLoc`
will no longer match class template specializations (since they no
longer store the type as written).</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Our current method of storing the template arguments as written for
`(Class/Var)Template(Partial)SpecializationDecl` suffers from a number
of flaws:
- We use `TypeSourceInfo` to store `TemplateArgumentLocs` for class
template/variable template partial/explicit specializations. For
variable template specializations, this is a rather unintuitive hack (as
we store a non-type specialization as a type). Moreover, we don't ever
*need* the type as written -- in almost all cases, we only want the
template arguments (e.g. in tooling use-cases).
- The template arguments as written are stored in a number of redundant
data members. For example, `(Class/Var)TemplatePartialSpecialization`
have their own `ArgsAsWritten` member that stores an
`ASTTemplateArgumentListInfo` (the template arguments).
`VarTemplateSpecializationDecl` has yet _another_ redundant member
"`TemplateArgsInfo`" that also stores an `ASTTemplateArgumentListInfo`.

This patch eliminates all
`(Class/Var)Template(Partial)SpecializationDecl` members which store the
template arguments as written, and turns the `ExplicitInfo` member into
a `llvm::PointerUnion&lt;const ASTTemplateArgumentListInfo*,
ExplicitInstantiationInfo*&gt;` (to avoid unnecessary allocations when the
declaration isn't an explicit instantiation). The template arguments as
written are now accessed via `getTemplateArgsWritten` in all cases.

The "most breaking" change is to AST Matchers, insofar that `hasTypeLoc`
will no longer match class template specializations (since they no
longer store the type as written).</pre>
</div>
</content>
</entry>
<entry>
<title>Fix the double space and double attribute printing of the final keyword. (#88600)</title>
<updated>2024-04-18T06:32:34+00:00</updated>
<author>
<name>Vassil Vassilev</name>
<email>v.g.vassilev@gmail.com</email>
</author>
<published>2024-04-18T06:32:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=71c0784dc4a2ef40039a97af122ba78549193120'/>
<id>71c0784dc4a2ef40039a97af122ba78549193120</id>
<content type='text'>
Fixes #56517.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes #56517.
</pre>
</div>
</content>
</entry>
<entry>
<title>[Clang] [C++26] Implement P2573R2: `= delete("should have a reason");` (#86526)</title>
<updated>2024-04-14T10:30:01+00:00</updated>
<author>
<name>Sirraide</name>
<email>aeternalmail@gmail.com</email>
</author>
<published>2024-04-14T10:30:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=ef164cee90477e294ff692209b4cf97a0e1958ed'/>
<id>ef164cee90477e294ff692209b4cf97a0e1958ed</id>
<content type='text'>
This implements support for the `= delete("message")` syntax that was
only just added to C++26
([P2573R2](https://isocpp.org/files/papers/P2573R2.html#proposal-scope)).</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This implements support for the `= delete("message")` syntax that was
only just added to C++26
([P2573R2](https://isocpp.org/files/papers/P2573R2.html#proposal-scope)).</pre>
</div>
</content>
</entry>
<entry>
<title>[Clang][AST] Track whether template template parameters used the 'typename' keyword (#88139)</title>
<updated>2024-04-11T17:20:05+00:00</updated>
<author>
<name>Krystian Stasiowski</name>
<email>sdkrystian@gmail.com</email>
</author>
<published>2024-04-11T17:20:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=4e6d18f40642c2cc8e124bbe55810b2d9b2ac9c0'/>
<id>4e6d18f40642c2cc8e124bbe55810b2d9b2ac9c0</id>
<content type='text'>
This patch adds a `Typename` bit-field to `TemplateTemplateParmDecl`
which stores whether the template template parameter was declared with
the `typename` keyword.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch adds a `Typename` bit-field to `TemplateTemplateParmDecl`
which stores whether the template template parameter was declared with
the `typename` keyword.</pre>
</div>
</content>
</entry>
<entry>
<title>Reland "Rework the printing of attributes (#87281)"</title>
<updated>2024-04-09T07:26:48+00:00</updated>
<author>
<name>Vassil Vassilev</name>
<email>v.g.vassilev@gmail.com</email>
</author>
<published>2024-04-09T05:27:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=9391ff8c86007562d40c240ea082b7c0cbf35947'/>
<id>9391ff8c86007562d40c240ea082b7c0cbf35947</id>
<content type='text'>
Original commit message:
"

Commit https://github.com/llvm/llvm-project/commit/46f3ade introduced a notion
of printing the attributes on the left to improve the printing of attributes
attached to variable declarations. The intent was to produce more GCC compatible
code because clang tends to print the attributes on the right hand side which is
not accepted by gcc.

This approach has increased the complexity in tablegen and the attrubutes
themselves as now the are supposed to know where they could appear. That lead to
mishandling of the `override` keyword which is modelled as an attribute in
clang.

This patch takes an inspiration from the existing approach and tries to keep the
position of the attributes as they were written. To do so we use simpler
heuristic which checks if the source locations of the attribute precedes the
declaration. If so, it is considered to be printed before the declaration.

Fixes https://github.com/llvm/llvm-project/issues/87151
"

The reason for the bot breakage is that attributes coming from ApiNotes are not
marked implicit even though they do not have source locations. This caused an
assert to trigger. This patch forces attributes with no source location
information to be printed on the left. That change is consistent to the overall
intent of the change to increase the chances for attributes to compile across
toolchains and at the same time the produced code to be as close as possible to
the one written by the user.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Original commit message:
"

Commit https://github.com/llvm/llvm-project/commit/46f3ade introduced a notion
of printing the attributes on the left to improve the printing of attributes
attached to variable declarations. The intent was to produce more GCC compatible
code because clang tends to print the attributes on the right hand side which is
not accepted by gcc.

This approach has increased the complexity in tablegen and the attrubutes
themselves as now the are supposed to know where they could appear. That lead to
mishandling of the `override` keyword which is modelled as an attribute in
clang.

This patch takes an inspiration from the existing approach and tries to keep the
position of the attributes as they were written. To do so we use simpler
heuristic which checks if the source locations of the attribute precedes the
declaration. If so, it is considered to be printed before the declaration.

Fixes https://github.com/llvm/llvm-project/issues/87151
"

The reason for the bot breakage is that attributes coming from ApiNotes are not
marked implicit even though they do not have source locations. This caused an
assert to trigger. This patch forces attributes with no source location
information to be printed on the left. That change is consistent to the overall
intent of the change to increase the chances for attributes to compile across
toolchains and at the same time the produced code to be as close as possible to
the one written by the user.
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "Rework the printing of attributes (#87281)"</title>
<updated>2024-04-09T05:03:34+00:00</updated>
<author>
<name>Vassil Vassilev</name>
<email>v.g.vassilev@gmail.com</email>
</author>
<published>2024-04-09T05:02:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=62e92573d28d62ab7e6438ac34d513b07c51ce09'/>
<id>62e92573d28d62ab7e6438ac34d513b07c51ce09</id>
<content type='text'>
This reverts commit a30662fc2acdd73ca1a9217716299a4676999fb4 due to bot failures.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit a30662fc2acdd73ca1a9217716299a4676999fb4 due to bot failures.
</pre>
</div>
</content>
</entry>
<entry>
<title>Rework the printing of attributes (#87281)</title>
<updated>2024-04-09T04:14:43+00:00</updated>
<author>
<name>Vassil Vassilev</name>
<email>v.g.vassilev@gmail.com</email>
</author>
<published>2024-04-09T04:14:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=a30662fc2acdd73ca1a9217716299a4676999fb4'/>
<id>a30662fc2acdd73ca1a9217716299a4676999fb4</id>
<content type='text'>
Commit https://github.com/llvm/llvm-project/commit/46f3ade introduced a
notion of printing the attributes on the left to improve the printing of
attributes attached to variable declarations. The intent was to produce
more GCC compatible code because clang tends to print the attributes on
the right hand side which is not accepted by gcc.

This approach has increased the complexity in tablegen and the
attrubutes themselves as now the are supposed to know where they could
appear. That lead to mishandling of the `override` keyword which is
modelled as an attribute in clang.

This patch takes an inspiration from the existing approach and tries to
keep the position of the attributes as they were written. To do so we
use simpler heuristic which checks if the source locations of the
attribute precedes the declaration. If so, it is considered to be
printed before the declaration.

Fixes https://github.com/llvm/llvm-project/issues/87151</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit https://github.com/llvm/llvm-project/commit/46f3ade introduced a
notion of printing the attributes on the left to improve the printing of
attributes attached to variable declarations. The intent was to produce
more GCC compatible code because clang tends to print the attributes on
the right hand side which is not accepted by gcc.

This approach has increased the complexity in tablegen and the
attrubutes themselves as now the are supposed to know where they could
appear. That lead to mishandling of the `override` keyword which is
modelled as an attribute in clang.

This patch takes an inspiration from the existing approach and tries to
keep the position of the attributes as they were written. To do so we
use simpler heuristic which checks if the source locations of the
attribute precedes the declaration. If so, it is considered to be
printed before the declaration.

Fixes https://github.com/llvm/llvm-project/issues/87151</pre>
</div>
</content>
</entry>
</feed>
