+
+int main() {
+ const int& x = A::x;
+ if (x != -1)
+ __builtin_abort();
+}
--
Nathan Sidwell
--- /dev/null
+++ b/gcc/testsuite/g++.dg/modules/merge-16_b.C
@@ -0,0 +1,5 @@
+// PR c++/112588
+// { dg-additional-options "-fmodules-ts" }
+
+#include "merge-16.h"
+import merge16;
--
Nathan Sidwell
nal
linkage" }
+ }
+}
+
+namespace m {
+ enum e3 { x3 }; // { dg-message "declared here with module linkage" }
+ enum class e4 { x4 }; // { dg-message "declared here with module linkage" }
+}
+
+export using enum s::e1; // { dg-error "does not have external linkage" }
+export using enum s::e2; // { dg-error "does not have external linkage" }
+export using enum m::e3; // { dg-error "does not have external linkage" }
+export using enum m::e4; // { dg-error "does not have external linkage" }
+
+// { dg-prune-output "not writing module" }
--
Nathan Sidwell
blic declarations in
module interface files, whether used or not".)
I'd like to hear Nathan's thoughts on the matter first, since he's the modules
implementation designer.
Jason
--
Nathan Sidwell
stsuite/g++.dg/modules/using-11_b.C
new file mode 100644
index 000..736a48c98f2
--- /dev/null
+++ b/gcc/testsuite/g++.dg/modules/using-11_b.C
@@ -0,0 +1,8 @@
+// PR c++/109679
+// { dg-module-do link }
+// { dg-additional-options "-fmodules-ts" }
+
+import M;
+int main() {
+ return foo();
+}
--
Nathan Sidwell
/testsuite/g++.dg/modules/part-mac-1_c.C
b/gcc/testsuite/g++.dg/modules/part-mac-1_c.C
index 78a53d2fda3..db57adcef44 100644
--- a/gcc/testsuite/g++.dg/modules/part-mac-1_c.C
+++ b/gcc/testsuite/g++.dg/modules/part-mac-1_c.C
@@ -2,4 +2,4 @@
// { dg-module-cmi {mod} }
export module mod;
-import mod:impl;
+import :impl;
--
2.42.0
--
Nathan Sidwell
e mode 100644
index 000..0508c0d6193
--- /dev/null
+++ b/gcc/testsuite/g++.dg/modules/pr106363_b.C
@@ -0,0 +1,10 @@
+// PR c++/106363
+// { dg-additional-options "-fmodules-ts" }
+// { dg-module-cmi pr106363.b }
+
+export module pr106363.b;
+import pr106363.a;
+
+namespace ns {
+ export using ns::x;
+}
--
Nathan Sidwell
On 12/18/23 17:10, Jason Merrill wrote:
On 12/18/23 16:57, Nathan Sidwell wrote:
On 12/18/23 16:31, Jason Merrill wrote:
Tested x86_64-pc-linux-gnu. Does this make sense? Did you have another theory
about how to merge these?
Why isn't push_abi_namespace doing the right setup here? (and I
atch-id: 66735c0c7beb22586ed4b632d10ec9094bb9920c
--
Nathan Sidwell
-module-cmi pr106363.b }
+
+export module pr106363.b;
+import pr106363.a;
+
+namespace ns {
+ export using ns::x;
+}
--
2.42.0
--
Nathan Sidwell
th internal
linkage" }
+ }
+}
+
+namespace m {
+ enum e3 { x3 }; // { dg-message "declared here with module linkage" }
+ enum class e4 { x4 }; // { dg-message "declared here with module linkage" }
+}
+
+export using enum s::e1; // { dg-error "does not have external linkage" }
+export using enum s::e2; // { dg-error "does not have external linkage" }
+export using enum m::e3; // { dg-error "does not have external linkage" }
+export using enum m::e4; // { dg-error "does not have external linkage" }
+
+// { dg-prune-output "not writing module" }
--
Nathan Sidwell
On 11/23/23 21:10, Nathaniel Shead wrote:
On Thu, Nov 23, 2023 at 11:45:31AM -0500, Nathan Sidwell wrote:
On 11/13/23 01:09, Nathaniel Shead wrote:
I happened to be browsing the standard a bit later and noticed that we
incorrectly reject the example given below.
Bootstrapped on x86_64-pc
--- /dev/null
+++ b/gcc/testsuite/g++.dg/modules/pr112631.C
@@ -0,0 +1,8 @@
+// { dg-additional-options "-fmodules-ts" }
+// { dg-module-cmi bla }
+
+export module bla;
+
+extern "C++" inline void fun() {
+ void oops(); // { dg-bogus "block-scope extern declaration" }
+}
--
Nathan Sidwell
s/pr99232_b.C
@@ -0,0 +1,7 @@
+// PR c++/99232
+// { dg-additional-options "-fmodules-ts" }
+
+import pr99232;
+
+double foo() { return lambda * 2.0; }
+static_assert(a == 42);
--
Nathan Sidwell
-1_c.C
b/gcc/testsuite/g++.dg/modules/part-mac-1_c.C
index 78a53d2fda3..db57adcef44 100644
--- a/gcc/testsuite/g++.dg/modules/part-mac-1_c.C
+++ b/gcc/testsuite/g++.dg/modules/part-mac-1_c.C
@@ -2,4 +2,4 @@
// { dg-module-cmi {mod} }
export module mod;
-import mod:impl;
+import :impl;
--
Nathan Sidwell
00..ab0c4ab4805
--- /dev/null
+++ b/gcc/testsuite/g++.dg/modules/lambda-6_b.C
@@ -0,0 +1,9 @@
+// PR c++/107398
+// { dg-additional-options "-fmodules-ts" }
+
+import Lambda6;
+
+int main() {
+ if (foo() != 1)
+__builtin_abort();
+}
--
Nathan Sidwell
ting for declaration" }
+export typedef int z; // { dg-bogus "conflicting exporting for declaration" }
+
+template using w = T;
+export template using w = T; // { dg-error "conflicting exporting for
declaration" }
template int f (T);
export template int f (T); // { dg-error "conflicting exporting for
declaration" }
--
Nathan Sidwell
cls so we miss this for now
class A;
-export class A; // { dg-error "conflicting exporting declaration" "" { xfail
*-*-* } }
+export class A; // { dg-error "conflicting exporting for declaration" }
-// { dg-warning "due to errors" "" { target *-*-* } 0 }
+template struct B;
+export template struct B {}; // { dg-error "conflicting exporting for
declaration" }
+
+// { dg-warning "due to errors" "" { target *-*-* } 0 }
--
Nathan Sidwell
off-by: Nathaniel Shead
thanks, I've committed it for you.
nathan
--
Nathan Sidwell
On 11/9/23 18:29, Nathaniel Shead wrote:
On Thu, Nov 09, 2023 at 05:57:39PM -0500, Nathan Sidwell wrote:
On 11/9/23 04:55, Nathaniel Shead wrote:
I'm not sure if this is just papering over a general issue of clones not being
exported/imported, or if this is just an exception to the general
ot; }
+// { dg-module-cmi !lib }
+
+export module lib;
+
+namespace outer {
+ template void any_of(T) { } // { dg-note "declared here" }
+}
+
+export using outer::any_of; // { dg-error "does not have external linkage" }
+
+// { dg-prune-output "not writing module" }
--
Nathan Sidwell
ew file mode 100644
index 000..b7468562ba9
--- /dev/null
+++ b/gcc/testsuite/g++.dg/modules/pr103499_b.C
@@ -0,0 +1,8 @@
+// PR c++/103499
+// { dg-additional-options "-fmodules-ts" }
+
+import pr103499;
+
+void test(derived* p) {
+ delete p;
+}
--
Nathan Sidwell
65c..37d0e77b1e1 100644
--- a/gcc/testsuite/g++.dg/modules/lambda-5_a.C
+++ b/gcc/testsuite/g++.dg/modules/lambda-5_a.C
@@ -1,5 +1,5 @@
// PR c++/105322
-// { dg-module-do link
+// { dg-module-do link }
// { dg-additional-options -fmodules-ts }
// { dg-module-cmi pr105322.Lambda }
--
Nat
PR c++/105322
+// { dg-additional-options -fmodules-ts }
+
+import pr105322;
+
+int main() {
+ f1();
+ f2();
+ g3();
+}
--
Nathan Sidwell
From fb65e961231943ecc68988f38a9ec78b0c93e5df Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Fri, 20 Oct 2023 12:20:37 -0400
Subject: [PATCH] c++: Cons
On 7/21/23 10:57, Ben Boeckel wrote:
On Thu, Jul 20, 2023 at 17:00:32 -0400, Nathan Sidwell wrote:
On 7/19/23 20:47, Ben Boeckel wrote:
But it is inhibiting distributed builds because the distributing tool
would need to know:
- what CMIs are actually imported (here, "read the module m
On 7/19/23 20:47, Ben Boeckel wrote:
On Wed, Jul 19, 2023 at 17:11:08 -0400, Nathan Sidwell wrote:
GCC is neither of these descriptions. a CMI does not contain the transitive
closure of its imports. It contains an import table. That table lists the
transitive closure of its imports (it needs
On 7/18/23 20:01, Ben Boeckel wrote:
On Tue, Jul 18, 2023 at 16:52:44 -0400, Jason Merrill wrote:
On 6/25/23 12:36, Ben Boeckel wrote:
On Fri, Jun 23, 2023 at 08:12:41 -0400, Nathan Sidwell wrote:
On 6/22/23 22:45, Ben Boeckel wrote:
On Thu, Jun 22, 2023 at 17:21:42 -0400, Jason Merrill
On 7/18/23 16:52, Jason Merrill wrote:
On 6/25/23 12:36, Ben Boeckel wrote:
On Fri, Jun 23, 2023 at 08:12:41 -0400, Nathan Sidwell wrote:
On 6/22/23 22:45, Ben Boeckel wrote:
On Thu, Jun 22, 2023 at 17:21:42 -0400, Jason Merrill wrote:
On 1/25/23 16:06, Ben Boeckel wrote:
They affect
Not commenting on the semantics, but the name seems unfortunate (hello
bikeshed). The documentation starts with 'attribute causes @var{name} to be
emitted as an alias to the definition'. So not emitting a 'reverse alias',
whatever that might be. It doesn;t seem to mention how reverse alias
appear, but without the same minimum language requirements.
+ The link is intended to be automatic: there should be no exceptions.
+
+ - The attribute appertains to whatever a standard attribute in the
+ same location would appertain to. There is no "sliding" from decls
+
it is neutered in patch 3 where
`write_make_modules_deps` is used in `make_write` (or will use that name
Why do you want to record the transitive modules? I would expect just noting the
ones with imports directly in the TU would suffice (i.e check the 'outermost' arg)
nathan
--
Nathan Sidwell
eing
the template inst of X. That code appears to be completely unnecessary. Added a
bunch of conversion operator demangling tests.
nathan
--
Nathan SidwellFrom 5a897036187468d4ded330b90b2abdaff5061ed6 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Mon, 12 Jun 2023 19:37:04 -0400
Subject: [PATC
rray- or function-producing conversions, which I
suspect is rarer.
pushed to trunk
nathan
--
Nathan SidwellFrom 80f075b410125bddb31459428760645baba1a69f Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Sat, 10 Jun 2023 12:42:17 -0400
Subject: [PATCH] c++: Adjust conversion deduction [PR61663][D
2001
From: Nathan Sidwell
Date: Wed, 17 May 2023 19:27:13 -0400
Subject: [PATCH] Allow plugin dumps
Defer dump option parsing until plugins are initialized. This allows one to
use plugin names for dumps.
PR other/99451
gcc/
* opts.h (handle_deferred_dump_options): Declare.
* opts-global.cc
#define nop(X) X
--- a/gcc/testsuite/g++.dg/modules/dir-only-2_b.C
+++ b/gcc/testsuite/g++.dg/modules/dir-only-2_b.C
@@ -1,5 +1,5 @@
// { dg-do preprocess }
-// { dg-additional-options "-fmodules-ts -fdirectives-only -isystem [srcdir]" }
+// { dg-additional-options "-fmodules-ts -fdirectives-only -isystem [srcdir]
-fno-canonical-system-headers" }
// a comment
module; // line
frob
--
Nathan Sidwell
rror {failed (socket|connecting|disabled) mapper 'localhost:172477262'}
"" { target *-*-* } 0 }
// { dg-prune-output "fatal error:" }
// { dg-prune-output "failed to read" }
// { dg-prune-output "compilation terminated" }
--
Nathan Sidwell
Jakub,
for avoidance of doubt, your version is fine.
nathan
On 4/11/23 18:06, Nathan Sidwell wrote:
On 4/11/23 04:12, Jakub Jelinek wrote:
Hi!
When working on the PR109040 fix, I wanted to test it on some
WORD_REGISTER_OPERATIONS target and tried sparc-solaris on GCC Farm.
My bootstrap
$@ -nt \
$(srcdir)/cp/module.cc; then \
cp ../prev-gcc/$@ $@; \
else \
date '+%y%m%dU' 2>/dev/null >$@; \
fi`; \
nathan
--
Nathan Sidwell
*-*-* } } }
--
Nathan Sidwell
i pr104234 }
+export module pr104234;
+
+template struct A {
+ template friend struct B;
+};
+A a;
+template struct B { };
--
Nathan Sidwell
ock_fd >= 0 && FD_ISSET (sock_fd, ))
active = -1;
+#endif
}
if (active >= 0)
--
Nathan Sidwell
.
That's a clever approach! LGTM
nathan
--
Nathan Sidwell
&& IS_DIR_SEPARATOR (ptr[2])) // A:/FOO
+#endif
+ || false)
/* A header name. */
return get_module (build_string (strlen (ptr), ptr));
--
Nathan Sidwell
osed as indicating the number
of explicit template parameters (1-based).
I'll commit in a few days.
nathan
--
Nathan SidwellFrom b7f0ba90011b8c9cae7b7278463f609ba21cd44b Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Mon, 7 Nov 2022 11:24:14 -0500
Subject: [PATCH] demangler: Templated lambda demang
On 11/8/22 05:18, Torbjorn SVENSSON wrote:
Hi Nathan,
On 2022-11-08 00:03, Nathan Sidwell wrote:
Yes, something like the above, but I think you're missing "/bob' in the
DOS_BASED case? shouldn't that also be a pathname?
if (IS_DIR_SEPARATOR (ptr[ptr[0] == '.']) // ./FOO or
On 11/3/22 11:06, Torbjorn SVENSSON wrote:
On 2022-11-03 15:17, Nathan Sidwell wrote:
On 10/28/22 05:15, Torbjörn SVENSSON wrote:
On Windows, the ':' character is special and when the module name is
a single character, like 'A', then the flatname would be (for
example) 'A:Foo'. On Windows
I found some additional cases when working on the demangler. May as
well check their mangling. Since I managed to confuse myself.
nathan
--
Nathan SidwellFrom 51d567d4d15e78b42d2ca83f229c98fff2aec9fa Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Mon, 7 Nov 2022 11:08:21 -0500
Subject
(f)[0] && (f)[1] == ':' && ((f)[2] == '/' || (f)[2] == '\\'))
#define HAS_DOS_DRIVE_SPEC(f) HAS_DRIVE_SPEC_1 (1, f)
#define IS_UNIX_DIR_SEPARATOR(c) IS_DIR_SEPARATOR_1 (0, c)
--
Nathan Sidwell
On 11/3/22 09:48, Torbjorn SVENSSON wrote:
Hello Nathan,
On 2022-11-03 14:13, Nathan Sidwell wrote:
On 11/3/22 05:37, Torbjörn SVENSSON wrote:
v1 -> v2:
Updated expression in bad-mapper-3.C
Ok for trunk?
---
Without the patch, the output for bad-mapper-3.C would be:
/src/gcc/gcc/testsu
ING disabled) mapper
'localhost:172477262'} "" { target *-*-* } 0 }
// { dg-prune-output "fatal error:" }
// { dg-prune-output "failed to read" }
// { dg-prune-output "compilation terminated" }
--
Nathan Sidwell
2b0e81d5cc2f7e1d773f6c502bd65b097f392675 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Mon, 31 Oct 2022 06:11:28 -0400
Subject: [PATCH] c++: per-scope, per-signature lambda discriminators
This implements ABI-compliant lambda discriminators. Not only do we
have per-scope counters, but we also
recorder (nearly)
always consecutively, it's clearer to handle it as two separate
operations. That also allows us to remove the instantiation
special-case for a null extra-scope.
nathan
--
Nathan SidwellFrom 0122faae30fe1ad1dfa8c69f3d3f0428b996b600 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
From bf6e972b65c56c615682f712f785d0f0541ac77b Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Mon, 24 Oct 2022 17:39:55 -0400
Subject: [PATCH] c++: Templated lambda mangling
(Explicitly) Templated lambdas have a different signature to
implicitly templated lambdas -- '[] (T) {}' is not the
same as '[](auto) {}'. This sh
owing patch fixes it by calling find_namespace_slot again even if it
was non-NULL, just doesn't assert it is *slot == ns in that case (because
it often is not).
Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?
ok. thanks
nathan
--
Nathan Sidwell
43e654afeba484d75fbee080262a038c1da00ad5 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Tue, 25 Oct 2022 09:39:00 -0400
Subject: [PATCH] c++: Adjust synthetic template parm creation
We intend to mark synthetic template parameters (coming from use of auto
parms), as DECL_VIRTUAL_P. The API of process_template_parm
On 10/21/22 09:11, Patrick Palka wrote:
On Fri, 21 Oct 2022, Nathan Sidwell wrote:
Thanks for the explanation, it's a situation I didn;t anticipate and your fix
is good. Could you add a comment about why you need to propagate the values
though?
Thanks a lot, will do. Just to make sure
0,0 +1,6 @@
+// PR c++/106848
+// { dg-additional-options "-fmodules-ts -g" }
+
+import "enum-9_a.H";
+
+memory_order x = memory_order_seq_cst;
--
2.38.0.68.ge85701b4af
--
Nathan Sidwell
;
+
+static_assert(C);
+static_assert(C); // { dg-error "static assert" }
--
Nathan Sidwell
/testsuite/g++.dg/modules/pr105045_b.C
@@ -0,0 +1,6 @@
+// PR c++/105045
+// { dg-additional-options -fmodules-ts }
+
+import pr105045;
+
+int main() { f(0); }
--
Nathan Sidwell
@
+// PR c++/101449
+// { dg-additional-options -fmodules-ts }
+
+import pr101449;
+
+static_assert(f().b);
+static_assert(g(f()));
--
Nathan Sidwell
On 10/13/22 11:27, Jason Merrill wrote:
On 10/11/22 13:40, Nathan Sidwell wrote:
On 10/11/22 11:35, Patrick Palka wrote:
IIUC the function depset::hash::add_binding_entity has an assert
verifying that if a namespace contains an exported entity, then
the namespace must have been opened
gcc/testsuite/g++.dg/modules/pr106304_b.C
new file mode 100644
index 000..e8333909c8d
--- /dev/null
+++ b/gcc/testsuite/g++.dg/modules/pr106304_b.C
@@ -0,0 +1,8 @@
+// PR c++/106304
+// { dg-additional-options -fmodules-ts }
+
+module pr106304;
+
+void f(A& a) {
+ as_b(a);
+}
--
Nathan Sidwell
pr100134;
+
+import "tpl-friend-8_a.H";
+
+export std::A a;
--
Nathan Sidwell
On 10/11/22 10:58, Patrick Palka wrote:
On Mon, 10 Oct 2022, Nathan Sidwell wrote:
On 10/4/22 13:36, Patrick Palka wrote:
Here when lazily loading the binding for f at parse time from the
template g, processing_template_decl is set and thus the call to
note_vague_linkage_fn from module_state
, so we do not need to check for that
case (although we could if we wanted to be more lenient).
nathan
--
Nathan SidwellFrom 0fa35c7e2974a22b2107fa378895c3069fe07ff3 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Fri, 30 Sep 2022 09:43:30 -0700
Subject: [PATCH] libiberty: Demangling 'M
/null
+++ b/gcc/testsuite/g++.dg/modules/pr99377-2_b.C
@@ -0,0 +1,6 @@
+// PR c++/99377
+// { dg-additional-options -fmodules-ts }
+// { dg-do link }
+import pr99377;
+template void g() { f(); }
+int main() { g(); }
--
Nathan Sidwell
ld-3.H
new file mode 100644
index 000..4fd4db7116a
--- /dev/null
+++ b/gcc/testsuite/g++.dg/modules/bfield-3.H
@@ -0,0 +1,8 @@
+// { dg-additional-options -fmodule-header }
+// { dg-module-cmi {} }
+
+template
+struct A {
+ int x : 1;
+ int y : N;
+};
--
Nathan Sidwell
the argument of the pack. That's an orthogonal problem, for which the
solution is to have better knowledge of operator precedence.
nathan
--
Nathan SidwellFrom 55bd808527e8c1947cf2d2b42769528087b687ef Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Fri, 30 Sep 2022 12:11:42 -0700
Subject: [PATCH
0:00 2001
From: Nathan Sidwell
Date: Fri, 30 Sep 2022 08:43:10 -0700
Subject: [PATCH 1/3] c++: Lambda context mangling
VAR and FIELD decls can become part of a lambda context, when the
lambda is 'attached' to that entity (It's a C++20 ODR thing that was
discovered with modules, but is actually sepa
+
+import "static-2_a.H";
+
+int main() {
+ f();
+}
--
Nathan Sidwell
On 9/30/22 09:43, Nathan Sidwell wrote:
Hi,
I've discovered some mangling problems with lambdas. (a) divergence
from clang and (b) manglings that incorrectly demangle. With #a I'm not
yet sure who is correct. for #b g++ is definitely wrong.
From the docs, it doesn't appear to have been
should bump it to 18?
nathan
--
Nathan Sidwell
0;
--
Nathan Sidwell
.
nathan
--
Nathan SidwellFrom a1f7f9541c2b20eb44750b9c15cd831c62d67f21 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Wed, 28 Sep 2022 09:21:14 -0700
Subject: [PATCH] c++: import/export NTTP objects
This adds smarts to the module machinery to handle NTTP object
VAR_DECLs. Like typeinfo objects
On 9/28/22 10:42, Patrick Palka wrote:
On Tue, 27 Sep 2022, Nathan Sidwell wrote:
On 9/26/22 15:05, Patrick Palka wrote:
On Mon, 26 Sep 2022, Patrick Palka wrote:
On Mon, 26 Sep 2022, Nathan Sidwell wrote:
return decl;
@@ -29150,9 +29151,10 @@ finish_concept_definition (cp_expr
-- anyway a bit flag on the node is better, IMHO). We
break apart the creation routine, so there's now an entry point the
module machinery can use directly.
nathan
--
Nathan SidwellFrom 50888e70c984da9cd9676d3986f68222581884b3 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Wed, 28 Sep 2022 09:20
On 9/26/22 15:05, Patrick Palka wrote:
On Mon, 26 Sep 2022, Patrick Palka wrote:
On Mon, 26 Sep 2022, Nathan Sidwell wrote:
On 9/26/22 10:08, Nathan Sidwell wrote:
On 9/23/22 09:32, Patrick Palka wrote:
Judging by the two commits that introduced/modified this part
tional-options -fmodule-header }
+// { dg-module-cmi {} }
+
+#include "partial-2.h"
diff --git a/gcc/testsuite/g++.dg/modules/partial-2_d.C
b/gcc/testsuite/g++.dg/modules/partial-2_d.C
new file mode 100644
index 000..ed54d3c2884
--- /dev/null
+++ b/gcc/testsuite/g++.dg/modules/partial-2_d.C
@@ -0,0 +1,8 @@
+// PR c++/107033
+// { dg-additional-options -fmodules-ts }
+// { dg-module-cmi pr107033 }
+export module pr107033;
+
+import "partial-2_c.H";
+
+#include "partial-2.cc"
--
Nathan Sidwell
On 9/26/22 10:08, Nathan Sidwell wrote:
On 9/23/22 09:32, Patrick Palka wrote:
Judging by the two commits that introduced/modified this part of
maybe_register_incomplete_var, r196852 and r214333, ISTM the code
is really only concerned with constexpr static data members (whose
initializer may
paramete object for A{}'. I see
that's a special mangler 'mangle_template_parm_object', called from
get_template_parm_object. Perhaps these VAR_DECLs need an additional
in-tree flag that the streamer can check for?
nathan
--
Nathan Sidwell
.
not sure how to approach this.
nathan
--
Nathan Sidwell
__cpp_concepts
+static_assert(concepts::is_reference_v);
+static_assert(concepts::is_reference_v);
+static_assert(!concepts::is_reference_v);
+
+static_assert(concepts::A::is_reference_v);
+static_assert(concepts::A::is_reference_v);
+static_assert(!concepts::A::is_reference_v);
+#endif
--
Nathan Sidwell
-#include
-#include
-#include
-#include
#endif
#endif
#endif
+
+// C++23
+#if __cplusplus > 202002L
+#include
+#include
+#include
+#if 0
+// Unimplemented
+#include
+#include
+#include
+#include
+#include
+#endif
+#endif
+
--
Nathan Sidwell
++.dg/modules/auto-3_b.C
@@ -0,0 +1,4 @@
+// { dg-additional-options "-fmodules-ts -fno-module-lazy" }
+
+#include "auto-3.h"
+import "auto-3_a.H";
--
Nathan Sidwell
On 9/20/22 10:08, Patrick Palka wrote:
On Tue, 20 Sep 2022, Nathan Sidwell wrote:
On 9/19/22 09:52, Patrick Palka wrote:
It looks like some xtreme-header-* tests are failing after the libstdc++
change r13-2158-g02f6b405f0e9dc ultimately because we're neglecting
to stream
;
res = expn;
}
--
Nathan Sidwell
On 9/16/22 11:54, Patrick Palka wrote:
On Fri, 16 Sep 2022, Nathan Sidwell wrote:
Thanks, this looks right. Sigh templates can mess up ones mental invariants!
The test case should really be a foo_[ab].C kind, to test both sides of the
streaming. Bonus points for using the template after
Thanks, this looks right. Sigh templates can mess up ones mental invariants!
The test case should really be a foo_[ab].C kind, to test both sides of the
streaming. Bonus points for using the template after importing. And you
need the dg-module-cmi annotation to check /and then delete/ the gcm
On 8/22/22 13:39, Paul Hollinsky wrote:
On Mon, Aug 22, 2022 at 09:19:29AM -0400, Nathan Sidwell wrote:
On 8/19/22 16:27, Paul Hollinsky wrote:
Hi all,
Would love some feedback on this patch!
Thanks,
Paul
On Mon, Aug 01, 2022 at 05:18:40AM +, Paul Hollinsky wrote:
Rather than
485,9 @@ struct cpp_reader
been used. */
bool seen_once_only;
+ /* Optimization for #pragma once. */
+ struct htab *pragma_once_files;
+
/* Multiple include optimization. */
const cpp_hashnode *mi_cmacro;
const cpp_hashnode *mi_ind_cmacro;
--
2.34.1
--
Nathan Sidwell
On 8/15/22 10:03, Richard Biener wrote:
On Mon, Aug 15, 2022 at 3:29 PM Nathan Sidwell via Gcc-patches
wrote:
On 8/2/22 10:44, Qing Zhao wrote:
Hi, Nathan,
I am adding a new bitfield “decl_not_flexarray” in “tree_decl_common”
(gcc/tree-core.h) for the new gcc feature -fstrict-flex-arrays
Not all systems have the same injected headers, leading to line
location table differences that are immaterial to the test. Fix the
regexp more robustly.
nathan
--
Nathan SidwellFrom af088b32def1c56538f0f3aaea16f013e9292d64 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Mon, 15 Aug 2022
odule streaming, could you please help me on this?
add it in to trees_{in,out}::core_bools. You could elide streaming for
non-FIELD_DECL decls.
Hope that helps.
nathan
Thanks a lot for your help.
Qing
--
Nathan Sidwell
9671f4d5e7efa130280b6d50fb4e9e8492d5b587 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Wed, 13 Jul 2022 12:11:40 -0700
Subject: [PATCH] C++: add -std={c,gnu}++{current,future}
Since C++ is such a moving target, Microsoft have /std:c++latest
(AFAICT clang does not), to select the currently
47794da8d8ea61ea8f6a0e21d3c1731a56d0cff3 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Fri, 24 Jun 2022 05:57:42 -0700
Subject: [PATCH] c++: Prune ordinary locations
Like macro locations, we only need to emit ordinary location
information for locations emitted into the CMI. This adds a hash table
noting
From 47e36785cd2ba35a577b0678a2ac185288eb9e52 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Mon, 27 Jun 2022 07:51:12 -0700
Subject: [PATCH] c++: Note macro locations
In order to prune ordinary locations, we need to note the locations of
macros we'll be writing out. This rearanges the macro processing to ach
The macro location tables should really mention they are about
locations. So rename them. Also, add a missing free of the remapping
table, and remove some now-unneeded macro checking.
nathan
--
Nathan SidwellFrom b0f25e1fdc6199725e69023a3dc49021f311ba66 Mon Sep 17 00:00:00 2001
From: Nathan
% and 60% respectively.
Ordinary locations are still transformed en-mass. They are somewhat
more complicated to apply a similar optimization to.
nathan
--
Nathan SidwellFrom 445cc1266ff8b9b8f96eceafa3c1116da54de967 Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Wed, 22 Jun 2022 05:54:30 -0700
d844478ab47a16c8ae65f253fd1cdc685c7951fc Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Wed, 22 Jun 2022 07:51:44 -0700
Subject: [PATCH] c++: Remove ifdefed code
The only reason I chose to use DECL_UID on this hash table was to make
it stable against ASLR and perturbations due to other allocations.
It's not required
I missed we documented this as unimplemented, when I implemented it.
--
Nathan SidwellFrom f1fcd6e3ad911945bc3c24a3a5c7ea99b910121e Mon Sep 17 00:00:00 2001
From: Nathan Sidwell
Date: Tue, 21 Jun 2022 06:23:11 -0700
Subject: [PATCH] doc: Document module language-linkage supported
I missed we
1 - 100 of 2544 matches
Mail list logo