Re: final protected private symbol
"Per Hedbor () @ Pike (-) importm?te f?r mailinglistan" <[email protected]>
| Newsgroups | gmane.comp.lang.pike.user |
|---|---|
| Message-ID | <[email protected]> |
> Has anyone benchmarked the various keywords and seen how much > performance improvement you get? In theory, 'final' at least ought to > result in faster code, but how much? Things marked 'final' or 'private' being faster is a new feature in pike 8.0 (final/private global variables are accessed directly, without using the vtable, basically). Before there was really no difference except access rights, so the only use was to make the API "cleaner". Or, well, I think pike 7.8 optimized 'final constant' by having uses of the constant use the constant directly instead of looking it up. (This dones not affect how the constants works when they are acceessed using the module system (there it is the index operator used that decides if they are constant or not)) -- Per Hedbor