🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.bug
Article #2748

inline functions

#2748
From: Jan Edler
Date: Mon, 12 Jun 1989 21:01
16 lines
1087 bytes
I'm looking at using the inline keyword.
I'm playing with a version of gcc-1.35.

I don't think a function declared inline should cause code
to be emitted from cc1 to define its body.  I.E., I think the current
behavior of "static inline" should be the default for just plain "inline".
If I have a large program, with many source files, and I put some inline
functions into a .h file to be included by many .c files, I *MUST* use
"static inline", to avoid a multiply-defined symbol complaint from the
linker.  This seems silly.  I think just plain "inline" should be
sufficient.  Are there realistic cases where the current behavior of
"inline" is preferable?

Why not?
Jan Edler
edler@nyu.edu
Technical Details
Message-ID: <8906122101.AA00954@jan.ultra.nyu.edu>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!tut.cis.ohio-state.edu!JAN.ULTRA.NYU.EDU!edler

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!tut.cis.ohio-state.edu!JAN.ULTRA.NYU.EDU!edler
From: edler@JAN.ULTRA.NYU.EDU (Jan Edler)
Newsgroups: gnu.gcc.bug
Subject: inline functions
Message-ID: <8906122101.AA00954@jan.ultra.nyu.edu>
Date: 12 Jun 89 21:01:27 GMT
Sender: daemon@tut.cis.ohio-state.edu
Distribution: gnu
Organization: GNUs Not Usenet
Lines: 16