@@ -343,6 +347,15 @@ public:
return __data_[__idx];
}
+# if _LIBCPP_STD_VER >= 26
+_LIBCPP_HIDE_FROM_ABI constexpr reference at(size_type __idx) const {
H-G-Hristov wrote:
@mordante I am not sure what I need to do. My experience with modules
https://github.com/H-G-Hristov updated
https://github.com/llvm/llvm-project/pull/74994
>From 6e26ca239c49e1b7d9ab72217db7339e92df163f Mon Sep 17 00:00:00 2001
From: Zingam
Date: Sun, 10 Dec 2023 14:16:02 +0200
Subject: [PATCH 1/7] [libc++][span] P2821R5: span.at()
---
libcxx/include/span
wangpc-pp wrote:
> Please reorganize the patch as @dtcxzyw suggested. :-)
>
> I didn't notice this extension before, so I may not be asking the right
> question here: These MOPs can be redefined, then, are we able to schedule
> them in compiler? Becase we don't know the cost of MOPs if we don'
https://github.com/H-G-Hristov edited
https://github.com/llvm/llvm-project/pull/74994
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -343,6 +347,15 @@ public:
return __data_[__idx];
}
+# if _LIBCPP_STD_VER >= 26
+_LIBCPP_HIDE_FROM_ABI constexpr reference at(size_type __idx) const {
+ if (__idx >= size()) {
+__throw_out_of_range();
+ }
+ return *(data() + __idx);
--
https://github.com/H-G-Hristov edited
https://github.com/llvm/llvm-project/pull/74994
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constan
https://github.com/H-G-Hristov edited
https://github.com/llvm/llvm-project/pull/74994
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/mjklemm edited
https://github.com/llvm/llvm-project/pull/74139
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constan
DianQK wrote:
@nikic Would you approve of this? Or do we need to add other codegen
participants to review?
@davemgreen Any other comments?
https://github.com/llvm/llvm-project/pull/74682
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https:/
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constan
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constantin,
=?utf-8?q?Félix-Antoine?= Constan
xu-chiheng wrote:
> NFC, and
I have build scripts at https://github.com/xu-chiheng/Note
When bootstrapping Clang on Cygwin, there are various weird problems.
Reducing the size of CallArgList solve them all.
https://github.com/llvm/llvm-project/pull/74977
_
https://github.com/xu-chiheng edited
https://github.com/llvm/llvm-project/pull/74973
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
xu-chiheng wrote:
> Would you please add some tests about your changes?
>
> Also maybe it will be more useful to write some detailed descriptions, so
> others can understand your code easily. Cheers!
Does to solve any problem.
https://github.com/llvm/llvm-project/pull/74973
_
xu-chiheng wrote:
> Would you please add some tests about your changes?
>
> Also maybe it will be more useful to write some detailed descriptions, so
> others can understand your code easily. Cheers!
To keep aligned with Cygwin GCC
https://github.com/llvm/llvm-project/pull/74973
MaskRay wrote:
I hope that someone using illumos can test, but if it is hard to find one I can
approve this.
https://github.com/llvm/llvm-project/pull/74930
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman
https://github.com/knightXun updated
https://github.com/llvm/llvm-project/pull/74885
>From 12cc1fe332fbab94c1368ea95374d5a1289a22f8 Mon Sep 17 00:00:00 2001
From: knightXun
Date: Sat, 9 Dec 2023 04:57:15 +0800
Subject: [PATCH 01/17] [Clang][Sema] Check the number of lambda non-concept
tempate
Author: Chuanqi Xu
Date: 2023-12-11T14:15:16+08:00
New Revision: 9a46518630869e7fcb495e72378abdbedf68d40d
URL:
https://github.com/llvm/llvm-project/commit/9a46518630869e7fcb495e72378abdbedf68d40d
DIFF:
https://github.com/llvm/llvm-project/commit/9a46518630869e7fcb495e72378abdbedf68d40d.diff
LO
@@ -2645,10 +2653,14 @@ MCSection
*TargetLoweringObjectFileXCOFF::getSectionForTOCEntry(
const MCSymbol *Sym, const TargetMachine &TM) const {
// Use TE storage-mapping class when large code model is enabled so that
// the chance of needing -bbigtoc is decreased.
+ //
Author: Chuanqi Xu
Date: 2023-12-11T14:06:32+08:00
New Revision: 8c334627818437180176b16b1932b2a26372d8ae
URL:
https://github.com/llvm/llvm-project/commit/8c334627818437180176b16b1932b2a26372d8ae
DIFF:
https://github.com/llvm/llvm-project/commit/8c334627818437180176b16b1932b2a26372d8ae.diff
LO
@@ -2645,10 +2653,14 @@ MCSection
*TargetLoweringObjectFileXCOFF::getSectionForTOCEntry(
const MCSymbol *Sym, const TargetMachine &TM) const {
// Use TE storage-mapping class when large code model is enabled so that
// the chance of needing -bbigtoc is decreased.
+ //
@@ -2058,6 +2089,10 @@ void PPCAIXAsmPrinter::emitLinkage(const GlobalValue *GV,
}
}
+ // Do not emit the _$TLSML symbol.
+ if (GVSym->getName() == "_Renamed..5f24__TLSML[TC]")
orcguru wrote:
Thank you! I will put some flag check before the string com
@@ -0,0 +1,97 @@
+// This is a regression test for ThinLTO indirect-call-promotion when candidate
+// callees need to be imported from another IR module. In the C++ test case,
+// `main` calls `global_func` which is defined in another module. `global_func`
+// has two indirect ca
@@ -1,39 +0,0 @@
-; Do setup work for all below tests: generate bitcode and combined index
MaskRay wrote:
Hmm, I think it is still preferred to have a test here as runtime tests are
more sensitive to the environment and may be skipped by some contributors.
It m
@@ -41,6 +41,10 @@ namespace Intrinsic {
typedef unsigned ID;
} // end namespace Intrinsic
+// Choose ';' as the delimiter. ':' was used once but it doesn't work well for
+// Objective-C functions which commonly have :'s in their names
MaskRay wrote:
add a fu
@@ -147,6 +147,9 @@ def exclude_unsupported_files_for_aix(dirname):
config.substitutions.append(
("%clang_pgouse=", build_invocation(clang_cflags) + " -fprofile-use=")
)
+config.substitutions.append(
+("%clangxx_pgouse=", build_invocation(clang_cxxflags) + " -fprofile-u
@@ -0,0 +1,97 @@
+// This is a regression test for ThinLTO indirect-call-promotion when candidate
+// callees need to be imported from another IR module. In the C++ test case,
+// `main` calls `global_func` which is defined in another module. `global_func`
+// has two indirect ca
@@ -0,0 +1,97 @@
+// This is a regression test for ThinLTO indirect-call-promotion when candidate
+// callees need to be imported from another IR module. In the C++ test case,
+// `main` calls `global_func` which is defined in another module. `global_func`
+// has two indirect ca
@@ -0,0 +1,97 @@
+// This is a regression test for ThinLTO indirect-call-promotion when candidate
+// callees need to be imported from another IR module. In the C++ test case,
+// `main` calls `global_func` which is defined in another module. `global_func`
+// has two indirect ca
https://github.com/MaskRay edited
https://github.com/llvm/llvm-project/pull/74008
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MaskRay commented:
Mostly looks good with some nits...
https://github.com/llvm/llvm-project/pull/74008
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ElvisWang123 updated
https://github.com/llvm/llvm-project/pull/75021
>From f15627239b333d729fe796e6bbfe9232df30a92e Mon Sep 17 00:00:00 2001
From: Elvis Wang
Date: Sun, 10 Dec 2023 18:34:37 -0800
Subject: [PATCH] [PGO][nfc] Add `-fdiagnostics-show-profile-count` option to
sh
@@ -144,25 +145,27 @@ void GlobalObject::copyAttributesFrom(const GlobalObject
*Src) {
std::string GlobalValue::getGlobalIdentifier(StringRef Name,
GlobalValue::LinkageTypes Linkage,
Stri
https://github.com/MaskRay approved this pull request.
https://github.com/llvm/llvm-project/pull/74889
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MaskRay edited
https://github.com/llvm/llvm-project/pull/74377
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1,15 +1,15 @@
-! Test that flang-new OpenMP and OpenMP offload related
+! Test that flang OpenMP and OpenMP offload related
! commands forward or expand to the appropriate commands
-! for flang-new -fc1 as expected. Assumes a gfx90a, aarch64,
+! for flang -fc1 as expected.
https://github.com/srcarroll edited
https://github.com/llvm/llvm-project/pull/75017
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -27,7 +27,7 @@
! FULL-LTO: "-fc1"
! FULL-LTO-SAME: "-flto=full"
-! THIN-LTO-ALL: flang-new: warning: the option '-flto=thin' is a work in
progress
+! THIN-LTO-ALL: flang-{{[0-9]+}}: warning: the option '-flto=thin' is a work
in progress
MaskRay wrote:
Fo
https://github.com/srcarroll edited
https://github.com/llvm/llvm-project/pull/75017
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/srcarroll edited
https://github.com/llvm/llvm-project/pull/75017
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/srcarroll edited
https://github.com/llvm/llvm-project/pull/75017
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/knightXun updated
https://github.com/llvm/llvm-project/pull/74885
>From 12cc1fe332fbab94c1368ea95374d5a1289a22f8 Mon Sep 17 00:00:00 2001
From: knightXun
Date: Sat, 9 Dec 2023 04:57:15 +0800
Subject: [PATCH 01/16] [Clang][Sema] Check the number of lambda non-concept
tempate
topperc wrote:
> > LGTM
>
> >
>
> > Related question. If there is an -mcpu on the command line and target
> > attribute changes the march, do we keep the original CPU in the -target-cpu
> > attribute or drop it. The reason for all those negative features from the
> > driver was to make the
github-actions[bot] wrote:
:warning: C/C++ code formatter, clang-format found issues in your code.
:warning:
You can test this locally with the following command:
``bash
git-clang-format --diff 0e1a9e3084cd8dffa5d4f2cf6eabf9e7721e1cdd
3409af09aec7f81af7e6e976a774aa945aa7f6ee --
github-actions[bot] wrote:
:warning: Python code formatter, darker found issues in your code. :warning:
You can test this locally with the following command:
``bash
darker --check --diff -r
0e1a9e3084cd8dffa5d4f2cf6eabf9e7721e1cdd...3409af09aec7f81af7e6e976a774aa945aa7f6ee
compi
@@ -0,0 +1,60 @@
+#!/bin/bash
+
+if [ $# -lt 1 ]; then
+ echo "Path to clang required!"
+ echo "Usage: update_thinlto_indirect_call_promotion_inputs.sh
/path/to/updated/clang"
+ exit 1
+else
+ CLANG=$1
+fi
+
+# Allows the script to be invoked from other directories.
+OUTDIR=$
@@ -144,25 +145,27 @@ void GlobalObject::copyAttributesFrom(const GlobalObject
*Src) {
std::string GlobalValue::getGlobalIdentifier(StringRef Name,
GlobalValue::LinkageTypes Linkage,
Stri
minglotus-6 wrote:
> Mach-O (and 32-bit Windows) mangle global symbols with a leading `_`.
It's very helpful to know the name differences exist on Mach-O/COFF to
construct a test case for issue 74565.
https://godbolt.org/z/686Y9vYod shows the name difference (cross comparing IR
and machine as
llvmbot wrote:
@llvm/pr-subscribers-clang-codegen
Author: Fangrui Song (MaskRay)
Changes
When the main file is preprocessed and we change `MainFileName` to the
original source file name (e.g. `a.i => a.c`), the source manager does
not contain `a.c`, but we incorrectly associate the DIFile(
llvmbot wrote:
@llvm/pr-subscribers-clang
Author: Fangrui Song (MaskRay)
Changes
When the main file is preprocessed and we change `MainFileName` to the
original source file name (e.g. `a.i => a.c`), the source manager does
not contain `a.c`, but we incorrectly associate the DIFile(a.c) wit
llvmbot wrote:
@llvm/pr-subscribers-debuginfo
Author: Fangrui Song (MaskRay)
Changes
When the main file is preprocessed and we change `MainFileName` to the
original source file name (e.g. `a.i => a.c`), the source manager does
not contain `a.c`, but we incorrectly associate the DIFile(a.c)
https://github.com/MaskRay created
https://github.com/llvm/llvm-project/pull/75022
When the main file is preprocessed and we change `MainFileName` to the
original source file name (e.g. `a.i => a.c`), the source manager does
not contain `a.c`, but we incorrectly associate the DIFile(a.c) with
md
wangpc-pp wrote:
Please reorginize the patch as @dtcxzyw suggested. :-)
I didn't notice this extension before, so I may not be asking the right
question here: These MOPs can be redefined, then, are we able to schedule them
in compiler? Becase we don't know the cost of MOPs if we don't know how
yonghong-song wrote:
Hi, @nikic,
This patch caused a bpf verifier regression with one of bpf selftests. The
details can be found in kernel bpf mailing list.
https://lore.kernel.org/bpf/0ff5f011-7524-4550-89eb-bb2c89f69...@linux.dev/
Note that bpf verification failure here does not mean that
@@ -15,17 +15,13 @@ local:
```
There are two main drivers in Flang:
h-vetinari wrote:
It might be worth spending a paragraph or section explaining the historical
role of `flang-new`, if only so that people understand why it's (eventually)
not available anym
@@ -193,26 +190,29 @@ driver, `clang -cc1` and consists of the following
classes:
This list is not exhaustive and only covers the main classes that implement the
driver. The main entry point for the frontend driver, `fc1_main`, is
implemented in `flang/tools/flang-driver/drive
https://github.com/h-vetinari edited
https://github.com/llvm/llvm-project/pull/74377
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/h-vetinari commented:
Some drive-by comments - very happy to see this happening!
https://github.com/llvm/llvm-project/pull/74377
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/
github-actions[bot] wrote:
:warning: C/C++ code formatter, clang-format found issues in your code.
:warning:
You can test this locally with the following command:
``bash
git-clang-format --diff 44dc1e0baae7c4b8a02ba06dcf396d3d452aa873
a14cfc5f15fcddd4b89155c4f3f58a21c27140c4 --
BeMg wrote:
> LGTM
>
> Related question. If there is an -mcpu on the command line and target
> attribute changes the march, do we keep the original CPU in the -target-cpu
> attribute or drop it. The reason for all those negative features from the
> driver was to make the backend not infer any
https://github.com/BeMg approved this pull request.
LGTM
https://github.com/llvm/llvm-project/pull/74889
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/XDeme edited https://github.com/llvm/llvm-project/pull/74943
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/knightXun updated
https://github.com/llvm/llvm-project/pull/74885
>From 12cc1fe332fbab94c1368ea95374d5a1289a22f8 Mon Sep 17 00:00:00 2001
From: knightXun
Date: Sat, 9 Dec 2023 04:57:15 +0800
Subject: [PATCH 01/15] [Clang][Sema] Check the number of lambda non-concept
tempate
https://github.com/XDeme edited https://github.com/llvm/llvm-project/pull/74943
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
llvmbot wrote:
@llvm/pr-subscribers-clang-codegen
@llvm/pr-subscribers-llvm-ir
Author: Elvis Wang (ElvisWang123)
Changes
The original `-fdiagnostics-show-hotness` option show the relative number of
the loop count which is calculate by the `function_entry_count` and
`branch_frequency`. We
https://github.com/ElvisWang123 created
https://github.com/llvm/llvm-project/pull/75021
The original `-fdiagnostics-show-hotness` option show the relative number of
the loop count which is calculate by the `function_entry_count` and
`branch_frequency`. We want to know the real loop iteration c
Author: Nathan Ridge
Date: 2023-12-10T22:05:51-05:00
New Revision: 9d3ea5a06abe08fa37053b825b3a1510d96bb7fb
URL:
https://github.com/llvm/llvm-project/commit/9d3ea5a06abe08fa37053b825b3a1510d96bb7fb
DIFF:
https://github.com/llvm/llvm-project/commit/9d3ea5a06abe08fa37053b825b3a1510d96bb7fb.diff
https://github.com/HighCommander4 closed
https://github.com/llvm/llvm-project/pull/74971
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HighCommander4 updated
https://github.com/llvm/llvm-project/pull/74971
>From 86d99f7b29a131b949b32f18ff15eb1d1f5e4d3a Mon Sep 17 00:00:00 2001
From: Nathan Ridge
Date: Sun, 10 Dec 2023 00:50:54 -0500
Subject: [PATCH] [clangd] Initialize HighlightingsBuilder::Resolver
---
cl
github-actions[bot] wrote:
:warning: C/C++ code formatter, clang-format found issues in your code.
:warning:
You can test this locally with the following command:
``bash
git-clang-format --diff 10951050b5f371eb3e7cacce1691c4eb2fe2eab5
1ccaf0d034d73145ddfa9e3265f856950628a7f7 --
Author: Jie Fu
Date: 2023-12-11T10:45:56+08:00
New Revision: 10951050b5f371eb3e7cacce1691c4eb2fe2eab5
URL:
https://github.com/llvm/llvm-project/commit/10951050b5f371eb3e7cacce1691c4eb2fe2eab5
DIFF:
https://github.com/llvm/llvm-project/commit/10951050b5f371eb3e7cacce1691c4eb2fe2eab5.diff
LOG: [
Author: Chuanqi Xu
Date: 2023-12-11T10:18:12+08:00
New Revision: 9406ea3fe32e59a7d28de0dcbd0317b4cdfa4c62
URL:
https://github.com/llvm/llvm-project/commit/9406ea3fe32e59a7d28de0dcbd0317b4cdfa4c62
DIFF:
https://github.com/llvm/llvm-project/commit/9406ea3fe32e59a7d28de0dcbd0317b4cdfa4c62.diff
LO
https://github.com/mtrofin closed
https://github.com/llvm/llvm-project/pull/74970
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Author: Mircea Trofin
Date: 2023-12-10T18:03:08-08:00
New Revision: 1d608fc755a3e15d0020f61c9535c9b730ab9dec
URL:
https://github.com/llvm/llvm-project/commit/1d608fc755a3e15d0020f61c9535c9b730ab9dec
DIFF:
https://github.com/llvm/llvm-project/commit/1d608fc755a3e15d0020f61c9535c9b730ab9dec.diff
ChuanqiXu9 wrote:
@sam-mccall ping!
https://github.com/llvm/llvm-project/pull/66462
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
knightXun wrote:
> This needs at least one test and a Release note.
>
> I expect the code form the issue to be well-formed:
> https://godbolt.org/z/bhdfG34xc
>
> So I am curious why you are adding the diagnostic for?
thanks for the hit!
https://github.com/llvm/llvm-project/pull/74885
__
https://github.com/mtrofin updated
https://github.com/llvm/llvm-project/pull/74970
>From 90893a3b3f71524947cb041b2a25d0a02a8956d7 Mon Sep 17 00:00:00 2001
From: Mircea Trofin
Date: Sat, 9 Dec 2023 21:24:35 -0800
Subject: [PATCH 1/2] [NFC][InstrProf] Refactor InstrProfiling lowering pass
Akin o
https://github.com/SixWeining approved this pull request.
https://github.com/llvm/llvm-project/pull/74990
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -31,31 +31,45 @@ using LoadStorePair = std::pair;
/// Instrumentation based profiling lowering pass. This pass lowers
/// the profile instrumented code generated by FE or the IR based
/// instrumentation pass.
-class InstrProfiling : public PassInfoMixin {
+class InstrProfil
https://github.com/XDeme edited https://github.com/llvm/llvm-project/pull/74943
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/XDeme edited https://github.com/llvm/llvm-project/pull/74943
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/XDeme edited https://github.com/llvm/llvm-project/pull/74943
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/XDeme edited https://github.com/llvm/llvm-project/pull/74943
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/XDeme edited https://github.com/llvm/llvm-project/pull/74943
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -6849,6 +6849,73 @@ static void handleSwiftAsyncAttr(Sema &S, Decl *D, const
ParsedAttr &AL) {
checkSwiftAsyncErrorBlock(S, D, ErrorAttr, AsyncAttr);
}
+// Warn if parent function misses format attribute. Parent function misses
+// format attribute if there is an argum
XDeme wrote:
One thing that I checked only now, is that with clang-format 16.0.6 and 17.0.6,
it formats correctly.
But with `clang-format version 18.0.0 (https://github.com/llvm/llvm-project.git
a6c02edd6eac476523b5c73f29619a7a9e054872)` is doens't anymore, so this is a
regression introduced r
@@ -583,20 +583,31 @@ bool ContinuationIndenter::mustBreak(const LineState
&State) {
return true;
}
- // If the return type spans multiple lines, wrap before the function name.
- if (((Current.is(TT_FunctionDeclarationName) &&
-!State.Line->ReturnTypeWrapped
@@ -26465,6 +26451,21 @@ TEST_F(FormatTest, BreakAfterAttributes) {
"{\n"
"}",
CtorDtorCode, Style);
+
+ Style.BreakBeforeBraces = FormatStyle::BS_Attach;
+ Style.ReferenceAlignment = FormatStyle::ReferenceAlignmentStyle::RAS_Left;
@@ -583,21 +583,31 @@ bool ContinuationIndenter::mustBreak(const LineState
&State) {
return true;
}
- // If the return type spans multiple lines, wrap before the function name.
- if (((Current.is(TT_FunctionDeclarationName) &&
-!State.Line->ReturnTypeWrapped
https://github.com/XDeme updated https://github.com/llvm/llvm-project/pull/74943
>From b80f8579dbc745ddfaa3d60770dd0d3e79e6c641 Mon Sep 17 00:00:00 2001
From: XDeme
Date: Sat, 9 Dec 2023 14:31:12 -0300
Subject: [PATCH 1/7] Fixes overload operator in BreakAfterAttributes
---
clang/lib/Format/Co
https://github.com/XDeme edited https://github.com/llvm/llvm-project/pull/74943
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -583,20 +583,31 @@ bool ContinuationIndenter::mustBreak(const LineState
&State) {
return true;
}
- // If the return type spans multiple lines, wrap before the function name.
- if (((Current.is(TT_FunctionDeclarationName) &&
-!State.Line->ReturnTypeWrapped
@@ -6849,6 +6849,73 @@ static void handleSwiftAsyncAttr(Sema &S, Decl *D, const
ParsedAttr &AL) {
checkSwiftAsyncErrorBlock(S, D, ErrorAttr, AsyncAttr);
}
+// Warn if parent function misses format attribute. Parent function misses
+// format attribute if there is an argum
@@ -6849,6 +6849,73 @@ static void handleSwiftAsyncAttr(Sema &S, Decl *D, const
ParsedAttr &AL) {
checkSwiftAsyncErrorBlock(S, D, ErrorAttr, AsyncAttr);
}
+// Warn if parent function misses format attribute. Parent function misses
+// format attribute if there is an argum
https://github.com/aaronpuchert edited
https://github.com/llvm/llvm-project/pull/70024
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,143 @@
+// RUN: %clang_cc1 -fsyntax-only -verify -Wmissing-format-attribute %s
+
+#include
+#include
+#include
+#include
+
+__attribute__((__format__ (__scanf__, 1, 4)))
+void f1(char *out, const size_t len, const char *format, ... /* args */)
+{
+va_list args;
@@ -0,0 +1,132 @@
+// RUN: %clang_cc1 -fsyntax-only -verify -Wmissing-format-attribute %s
+
+#include
+#include
+
+void f1(const std::string &str, ... /* args */)
+{
+va_list args;
+vscanf(str.c_str(), args); // no warning
+vprintf(str.c_str(), args); // no warning
+
@@ -6849,6 +6849,73 @@ static void handleSwiftAsyncAttr(Sema &S, Decl *D, const
ParsedAttr &AL) {
checkSwiftAsyncErrorBlock(S, D, ErrorAttr, AsyncAttr);
}
+// Warn if parent function misses format attribute. Parent function misses
+// format attribute if there is an argum
1 - 100 of 163 matches
Mail list logo