🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #3849

Re: Why "long long" doesn't work.

#3849
From: Michael Shields
Date: Thu, 24 Aug 1995 20:34
15 lines
1081 bytes
In article <41g85d$kc@newsbf02.news.aol.com>,
FFarance <ffarance@aol.com> wrote:
> How would this lookup work?  Since the format string is interpreted
> by "printf", "printf" would have to know how big the next argument
> is on the stack -- how would it know how big the next argument is?

You could specify that arguments are always promoted to the largest
integer type.  It would simply both calling and implementing variadic
functions with EIR types, obsolete the `h' and `l' modifiers, and look
much cleaner.

It would take more stack (or register) space, but since functions rarely
have more than a few arguments, this isn't much of a loss.
-- 
Shields.
Technical Details
Message-ID: <41inp4$b1n@yage.tembel.org>
Path: arc1-ca.pugleaf.net!news.tembel.org!not-for-mail
References: <41fdv8$ici@milo.mcs.anl.gov> <41g85d$kc@newsbf02.news.aol.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!news.tembel.org!not-for-mail
From: shields@tembel.org (Michael Shields)
Newsgroups: comp.std.c
Subject: Re: Why "long long" doesn't work.
Date: 24 Aug 1995 20:34:44 -0000
Organization: Tembel's Hedonic Commune
Message-ID: <41inp4$b1n@yage.tembel.org>
References: <41fdv8$ici@milo.mcs.anl.gov> <41g85d$kc@newsbf02.news.aol.com>
NNTP-Posting-Host: yage.tembel.org
NNTP-Posting-User: shields