X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:references:to:subject :content-type; q=dns; s=default; b=vBC5MnPvr38jgmaL0ePkQpUa2ojIh +Dwan8LSwwmVDcSPWe5VSyPLvZI3LCkVjGF3oKbsBN5eDB727d9tnsDYeP9sqg2r UzlER/OCMvsbZTDAm7+FfumG/3araaUVeRG03qilTdhSJfoLb48llNk2t1krXLEv gBI0oW3t6+Q4SE= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:references:to:subject :content-type; s=default; bh=i6EzalljPXj94gjvfhTnZfA4PB8=; b=UDu k6/DZPX4qqc8ws3Aq/I2+IXH96c7EMUX+IjRISlPKmLG4vZayo/u33oC1SldjMby yQ8HzDBDX2KOMEyWbGsDummbe7XtsB3Z0tnJJpHHLShLaI1vyBF3LcIFH8eyvN4W N+BLnC33Xu+sveJoWfdxzpbG0M7l3VCd1jSNAKd4= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.4 required=5.0 tests=BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=no version=3.3.2 spammy=zi, H*M:google X-HELO: mail-oi0-f41.google.com X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:date:from:references:to:subject :user-agent; bh=3CJhvfk2ZN3dsWIB6mIBSbGPsp4A2xTUmixJL031ZtA=; b=F4a7Ge8Dd7gCqWH9rQ+bKAc0ChHoqJELQhsiqscltjkS6J+337Uj6ZqSI5ADvxsiLs l3mk+NLxxmXE82+oxBeGSpOQ534mGf88N6vMsd9iormf+IKydDKylNJrCWnGh4bif2by vEsDfg8tfCTL+LiR9BAmUDo/zAttMOatWeHzmvOjjijz+CIpi7XfDz2oifeJFwQrFx1d f+NRku7LpnoFkvqe5acw3UP7HH6v5csIvzkj3ZA6alPWHx5+Z3TZgxaRN7gb6ZUL9XNN kjcnn127cbwS2sC+sKAjgaefHvBV8Re74PcyonNUPNR8gf26wrSmnZYgBQi01U7NkpH7 oUyg== X-Gm-Message-State: AODbwcC1L3ImU+az2rULP9EfjuEIowx6Ye+4LrBeQuHX2KcW+qsXYnk7 oUSvP7tbGWmEupMB X-Received: by 10.157.82.87 with SMTP id q23mr8321176otg.52.1495763598632; Thu, 25 May 2017 18:53:18 -0700 (PDT) Message-ID: <59278a8d.4c72ca0a.40c07.37ed@mx.google.com> Date: Thu, 25 May 2017 18:53:17 -0700 (PDT) From: Steven Penny X-Google-Original-From: Steven Penny References: <5927885e DOT b5169d0a DOT fd65e DOT 370a AT mx DOT google DOT com> To: cygwin AT cygwin DOT com Subject: Re: bug in lrint [was: FW: Printing long int in C program under cygwin64] Content-Type: text/plain; charset=utf8; format=flowed User-Agent: Tryst/2.0.1 (github.com/svnpenn/tryst) On Thu, 25 May 2017 18:43:58, Steven Penny wrote: > Uh, have you actually tried this? It doesnt do anything: > > $ cat alfa.c > #define __USE_MINGW_ANSI_STDIO 1 > #include > int main() { > printf("%zi %zu %llu\n", __SIZE_MAX__, __SIZE_MAX__, __SIZE_MAX__); > } > > $ x86_64-w64-mingw32-gcc -Wformat-signedness -o alfa alfa.c Correcting myself: you need 2 flags to get this working: $ x86_64-w64-mingw32-gcc -Wformat -Wformat-signedness alfa.c alfa.c: In function ‘main’: alfa.c:11:10: warning: format ‘%zi’ expects argument of type ‘signed size_t’, but argument 2 has type ‘long long unsigned int’ [-Wformat=] printf("%zi %zu %llu\n", __SIZE_MAX__, __SIZE_MAX__, __SIZE_MAX__); ^ -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple