INLINE pragmas
Joachim Breitner
mail at joachim-breitner.de
Thu Jul 30 10:24:09 UTC 2015
Hi,
Am Donnerstag, den 30.07.2015, 10:14 +0000 schrieb Simon Peyton Jones:
> | (I always have to look up the documentation for these, just a
> | suggestion but maybe it would be better to call them INLINEAFTER[n]
> | and INLINEBEFORE[n], or something?)
>
> Maybe. But NOINLINE[n] means "do not inline until phase n; and you
> are free to do what you like thereafter" So it would have to be
> NOINLINEUNTIL[n]. But yes, that'd be quite do-able.
I support that suggestion, as I also always have to look it up as well,
and things like NONLINE[~n] are really non-self-explanatory.
Although "NOINLINEUNTIL[n]" is (to me, non-native-speaker) not as clear
as it could be about what happens in phase n; the same with
INLINEAFTER.
How about this, using “from” and “before”, which (to me) make it
clearer what happens at n:
INLINE[n] becomes INLINEFROM[n]
NOINLINE[n] becomes NOINLINEBEFORE[n]
INLINE[~n] becomes INLINEBEFORE[n]
NOINLINE[~n] becomes NOINLINEFROM[n]
BTW, the docs say about NOINLINE “You shouldn't ever need to do this,
unless you're very cautious about code size.” – should this also
mention that NOINLINE are often necessary with RULES?
Greetings,
Joachim
--
Joachim “nomeata” Breitner
mail at joachim-breitner.de • http://www.joachim-breitner.de/
Jabber: nomeata at joachim-breitner.de • GPG-Key: 0xF0FBF51F
Debian Developer: nomeata at debian.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part
URL: <http://mail.haskell.org/pipermail/ghc-devs/attachments/20150730/a72df4cd/attachment.sig>
More information about the ghc-devs
mailing list