From: Marek Polacek <polacek@redhat.com>
To: GCC Patches <gcc-patches@gcc.gnu.org>
Subject: [committed] c++: Add test for DR 188.
Date: Thu, 16 Jul 2020 12:13:23 -0400 [thread overview]
Message-ID: <20200716161323.768809-1-polacek@redhat.com> (raw)
Tested x86_64-pc-linux-gnu, applying to trunk.
gcc/testsuite/ChangeLog:
DR 188
* g++.dg/DRs/dr188.C: New test.
---
gcc/testsuite/g++.dg/DRs/dr188.C | 7 +++++++
1 file changed, 7 insertions(+)
create mode 100644 gcc/testsuite/g++.dg/DRs/dr188.C
diff --git a/gcc/testsuite/g++.dg/DRs/dr188.C b/gcc/testsuite/g++.dg/DRs/dr188.C
new file mode 100644
index 00000000000..f29a9eba1c9
--- /dev/null
+++ b/gcc/testsuite/g++.dg/DRs/dr188.C
@@ -0,0 +1,7 @@
+// DR 188
+// { dg-do compile { target c++11 } }
+// From [diff.expr]p5.
+
+char arr[100];
+// Yields 100 in C++ and sizeof(char*) in C.
+static_assert (sizeof (0, arr) == 100, "");
base-commit: a4f49061b6d921f72b2faf4843144f3c75f828f7
--
2.26.2
reply other threads:[~2020-07-16 16:13 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200716161323.768809-1-polacek@redhat.com \
--to=polacek@redhat.com \
--cc=gcc-patches@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).