Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c > #91734

Re: Q: stdint format specifiers

From Keith Thompson <kst-u@mib.org>
Newsgroups comp.lang.c
Subject Re: Q: stdint format specifiers
Date 2016-08-05 08:26 -0700
Organization None to speak of
Message-ID <lneg63z16n.fsf@kst-u.example.com> (permalink)
References (1 earlier) <282c43f4-9e51-4c3c-9552-6703c60df230@googlegroups.com> <ln8twc1fpw.fsf@kst-u.example.com> <ad7f21a6-cd3b-450b-b625-a64fd3f4bdbd@googlegroups.com> <lnziosz0xx.fsf@kst-u.example.com> <f0f7b353-f070-4a17-a401-4952372d4be2@googlegroups.com>

Show all headers | View raw


Malcolm McLean <malcolm.mclean5@btinternet.com> writes:
> On Thursday, August 4, 2016 at 10:19:59 PM UTC+1, Keith Thompson wrote:
>> supercat@casperkitty.com writes:
>>> From what I can tell, the fundamental purpose of all the PRI_* 
>>> macros is to make code that uses types like uint32_t behave in 
>>> a fashion independent of the size of the built-in integer types; 
>>> the main reason one would want to convert code from using %ld to 
>>> using those macros is to facilitate
>>> migration of that code to other systems.
>> 
>> Right.  I wasn't discussing the purpose of the PRI_* macros, just the
>> problems inherent in automatically generating code that uses them.
>> 
> Yes, you don't want to play with fundamental things like strings
> or integers, or the language starts to fall apart and the most
> trivial task becomes involved.
> Make int big enough to index any array, and stop using all other
> types except in special purpose bit-bashing or port communicating
> code.

Feel free to argue that, but please don't frame it as if you were
agreeing with me.

-- 
Keith Thompson (The_Other_Keith) kst-u@mib.org  <http://www.ghoti.net/~kst>
Working, but not speaking, for JetHead Development, Inc.
"We must do something.  This is something.  Therefore, we must do this."
    -- Antony Jay and Jonathan Lynn, "Yes Minister"

Back to comp.lang.c | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

Q: stdint format specifiers Johann Klammer <klammerj@NOSPAM.a1.net> - 2016-08-04 18:11 +0200
  Re: Q: stdint format specifiers supercat@casperkitty.com - 2016-08-04 09:53 -0700
    Re: Q: stdint format specifiers Keith Thompson <kst-u@mib.org> - 2016-08-04 12:44 -0700
      Re: Q: stdint format specifiers Johann Klammer <klammerj@NOSPAM.a1.net> - 2016-08-04 22:57 +0200
      Re: Q: stdint format specifiers supercat@casperkitty.com - 2016-08-04 14:11 -0700
        Re: Q: stdint format specifiers Keith Thompson <kst-u@mib.org> - 2016-08-04 14:19 -0700
          Re: Q: stdint format specifiers supercat@casperkitty.com - 2016-08-04 15:08 -0700
            Re: Q: stdint format specifiers Keith Thompson <kst-u@mib.org> - 2016-08-04 15:26 -0700
          Re: Q: stdint format specifiers Malcolm McLean <malcolm.mclean5@btinternet.com> - 2016-08-04 23:19 -0700
            Re: Q: stdint format specifiers supercat@casperkitty.com - 2016-08-05 08:04 -0700
            Re: Q: stdint format specifiers Keith Thompson <kst-u@mib.org> - 2016-08-05 08:26 -0700

csiph-web