public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: David Malcolm <dmalcolm@redhat.com>
To: Jonathan Yong <10walls@gmail.com>,
	Gcc Patch List <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] coreutils-sum-pr108666.c: fix spurious LLP64 warnings
Date: Wed, 14 Feb 2024 08:55:14 -0500	[thread overview]
Message-ID: <390591d3b86036c1358d91c62f438deb431cea3e.camel@redhat.com> (raw)
In-Reply-To: <5360d644-72d5-454b-92d4-d8298069f6b5@gmail.com>

On Fri, 2024-02-02 at 23:55 +0000, Jonathan Yong wrote:
> Attached patch OK? Fixes the following warnings:

Thanks; looks good to me.

Dave

> coreutils-sum-pr108666.c:17:1: warning: conflicting types for built-
> in function ‘memcpy’; expected ‘void *(void *, const void *, long
> long unsigned int)’ [-Wbuiltin-declaration-mismatch]
>     17 | memcpy(void* __restrict __dest, const void* __restrict
> __src, size_t __n)
>        | ^~~~~~
> 
> coreutils-sum-pr108666.c:25:1: warning: conflicting types for built-
> in function ‘malloc’; expected ‘void *(long long unsigned int)’ [-
> Wbuiltin-declaration-mismatch]
>     25 | malloc(size_t __size) __attribute__((__nothrow__, __leaf__))
>        | ^~~~~~
> 
> Copied for review convenience:
> diff --git a/gcc/testsuite/c-c++-common/analyzer/coreutils-sum-
> pr108666.c b/gcc/testsuite/c-c++-common/analyzer/coreutils-sum-
> pr108666.c
> index 5684d1b02d4..dadd27eaf41 100644
> --- a/gcc/testsuite/c-c++-common/analyzer/coreutils-sum-pr108666.c
> +++ b/gcc/testsuite/c-c++-common/analyzer/coreutils-sum-pr108666.c
> @@ -1,6 +1,6 @@
>   /* Reduced from coreutils's sum.c: bsd_sum_stream */
>   
> -typedef long unsigned int size_t;
> +typedef __SIZE_TYPE__ size_t;
>   typedef unsigned char __uint8_t;
>   typedef unsigned long int __uintmax_t;
>   typedef struct _IO_FILE FILE;


  parent reply	other threads:[~2024-02-14 13:55 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-02 23:55 Jonathan Yong
2024-02-11  1:05 ` Jonathan Yong
2024-02-14 13:55 ` David Malcolm [this message]
2024-02-14 15:59   ` Jonathan Yong

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=390591d3b86036c1358d91c62f438deb431cea3e.camel@redhat.com \
    --to=dmalcolm@redhat.com \
    --cc=10walls@gmail.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).