From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <1d774b35c732e620fee8fc4254c169e7@felloff.net> Date: Thu, 7 Jan 2016 02:08:00 +0100 From: cinap_lenrek@felloff.net To: 9fans@9fans.net In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Subject: Re: [9fans] subtracting pointers on amd64 6c Topicbox-Message-UUID: 7eb9d5ec-ead9-11e9-9d60-3106f5b1d025 what if we introduce signed intptr type and use that instead of introducing ptrdiff? ape already has a signed intptr_t type. then use 'z' as a modifier to mean "intptr size" so that %zd would print signed intptr and %zud is for uintptr? the %t and %T space seems rather crowded... term% grep 'fmtinstall\(''[zZtT]' */*.c */*/*.c */*/*/*.c */*/*/*/*.c cmd/timepic.c: fmtinstall('T', Tfmt); cmd/trace.c: fmtinstall('t', timeconv); libhtml/lex.c: fmtinstall('T', Tconv); libmach/kdb.c: fmtinstall('T', Tfmt); libmach/udb.c: fmtinstall('T', Tfmt); libventi/log.c: fmtinstall('T', timefmt); 9/mtx/pci.c: fmtinstall('T', tbdffmt); 9/pc/pci.c: fmtinstall('T', tbdffmt); 9/port/edf.c: fmtinstall('t', timeconv); 9/teg2/pci.c: fmtinstall('T', tbdffmt); cmd/cc/lex.c: fmtinstall('T', Tconv); cmd/cwfs/sub.c: fmtinstall('Z', Zfmt); /* print devices */ cmd/cwfs/sub.c: fmtinstall('T', Tfmt); /* print times */ cmd/db/output.c: fmtinstall('t', tconv); cmd/disk/rd9660.c: fmtinstall('T', asciiTfmt); cmd/disk/rd9660.c: fmtinstall('T', runeTfmt); cmd/hjfs/buf.c: fmtinstall('T', Tfmt); cmd/vac/unvac.c: fmtinstall('t', mtimefmt); cmd/upas/fs/imap4.c: fmtinstall('Z', doublequote); cmd/upas/marshal/marshal.c: fmtinstall('Z', doublequote); cmd/venti/srv/fixarenas.c: fmtinstall('z', zfmt); cmd/venti/srv/fixarenas.c: fmtinstall('t', tfmt); cmd/venti/srv/utils.c: fmtinstall('T', vttimefmt); -- cinap