Re: Static constant class members

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello !

On Sunday 29 February 2004 19:49, Eljay Love-Jensen wrote:
> You are correct.  If you really want it to be an immediate operand in C++,
> do this:
>
> class TxtVideo
> {
> public:
>    static unsigned int* const getVBase() { return (unsigned int*
> const)0x0C00B8000L; }
> ...
>
> That will be inserted as an inline function (since it's body is defined in
> the class), and the inline will optimize down to an immediate.
>
Thanks ! I'll try it.

-- 
          Vova

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux