From: Alexandre Oliva <oliva@adacore.com>
To: Sebastian Huber <sebastian.huber@embedded-brains.de>
Cc: gcc-patches@gcc.gnu.org, libstdc++@gcc.gnu.org, RTEMS <devel@rtems.org>
Subject: Re: [PATCH] libstdc++: testsuite: fs rename to self may fail
Date: Wed, 22 Jun 2022 04:01:28 -0300 [thread overview]
Message-ID: <orwnd989mf.fsf@lxoliva.fsfla.org> (raw)
In-Reply-To: <4fe20709-e617-7644-175c-bd49b52dc6c2@embedded-brains.de> (Sebastian Huber's message of "Wed, 22 Jun 2022 08:33:57 +0200")
Hello, Sebastian,
On Jun 22, 2022, Sebastian Huber <sebastian.huber@embedded-brains.de> wrote:
> On 22/06/2022 08:24, Alexandre Oliva via Libstdc++ wrote:
>> rtems6's rename() implementation errors with EEXIST when the rename-to
>> filename exists, even when renaming a file to itself or when renaming
>> a nonexisting file. Adjust expectations.
>>
>> Regstrapped on x86_64-linux-gnu, also tested with a cross to
>> aarch64-rtems6. Ok to install?
>>
>> PS:https://devel.rtems.org/ticket/2169 doesn't seem to suggest plans to
>> change behavior so as to comply with POSIX.
> I would not adjust the test case to cope with systems which are not in
> line with POSIX.
My understanding is that the libstdc++ testsuite is not meant to test
for POSIX conformance, but for conformance with the C++ language
standards.
C++ inherits rename from C, and C says the behavior is implementation
defined if the new name already exists.
RTEMS is thus comformant with the requirements from C (and thus C++),
and it is therefore reasonable for libstdc++'s testsuite to accept
RTEMS' behavior as such.
That said, because libstdc++ tests are all-or-nothing, perhaps it would
make sense to have a separate test for strict POSIX conformance in
rename, XFAILed on RTEMS targets. How about that?
--
Alexandre Oliva, happy hacker https://FSFLA.org/blogs/lxo/
Free Software Activist GNU Toolchain Engineer
Disinformation flourishes because many people care deeply about injustice
but very few check the facts. Ask me about <https://stallmansupport.org>
next prev parent reply other threads:[~2022-06-22 7:01 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-22 6:24 Alexandre Oliva
2022-06-22 6:33 ` Sebastian Huber
2022-06-22 7:01 ` Alexandre Oliva [this message]
2022-06-22 10:41 ` Jonathan Wakely
2022-06-23 3:59 ` Alexandre Oliva
2022-06-23 6:26 ` Alexandre Oliva
2022-06-23 9:25 ` Jonathan Wakely
2022-06-23 11:21 ` Alexandre Oliva
2022-06-23 11:38 ` Jonathan Wakely
2022-06-23 12:41 ` Alexandre Oliva
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=orwnd989mf.fsf@lxoliva.fsfla.org \
--to=oliva@adacore.com \
--cc=devel@rtems.org \
--cc=gcc-patches@gcc.gnu.org \
--cc=libstdc++@gcc.gnu.org \
--cc=sebastian.huber@embedded-brains.de \
/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).