From: Cyril Hrubis <chrubis@suse.cz>
To: ltp@lists.linux.it
Subject: [LTP] Question about strncpy_2-1
Date: Tue, 11 Dec 2018 13:39:31 +0100 [thread overview]
Message-ID: <20181211123931.GC27346@rei> (raw)
In-Reply-To: <5C0F83AC.8070902@cn.fujitsu.com>
Hi!
> With old gcc version(e.g. gcc-4.4), compiling strncpy_2-1 gets the following error:
> ----------------------------------------------------------------------------------
> ../../../conformance/interfaces/strncpy/1-1.c: In function ???main???:
> ../../../conformance/interfaces/strncpy/1-1.c:64: error: #pragma GCC diagnostic not allowed inside functions
> ../../../conformance/interfaces/strncpy/1-1.c:65: error: #pragma GCC diagnostic not allowed inside functions
> ../../../conformance/interfaces/strncpy/1-1.c:67: error: #pragma GCC diagnostic not allowed inside functions
> conformance/interfaces/strncpy/1-1 compile FAILED; SKIPPING
> ----------------------------------------------------------------------------------
>
> It seems that push/pop is supported and pragma diagnostic is allowed inside functions
> since commit 0955be6 in GCC.
Looks like an attempt to silence warnings, but a lousy one that would
break on anything but new enough gcc, let's get rid of that.
--
Cyril Hrubis
chrubis@suse.cz
next prev parent reply other threads:[~2018-12-11 12:39 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-11 9:30 [LTP] Question about strncpy_2-1 Xiao Yang
2018-12-11 9:59 ` Xiao Yang
2018-12-11 12:37 ` Cyril Hrubis
2018-12-11 12:39 ` Cyril Hrubis [this message]
2018-12-12 10:40 ` [LTP] [PATCH] openposix/strncpy1-1: Fix compiler errors/warnings Xiao Yang
2018-12-14 8:33 ` Cyril Hrubis
2018-12-14 8:17 ` [LTP] [PATCH v2] " Xiao Yang
2018-12-14 12:47 ` Cyril Hrubis
2018-12-14 8:40 ` [LTP] [PATCH] " Xiao Yang
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=20181211123931.GC27346@rei \
--to=chrubis@suse.cz \
--cc=ltp@lists.linux.it \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.