What is this symbol @ ?

Just starting out? Need help? Post your questions and find answers here.
TIGER
User
User
Posts: 81
Joined: Mon Feb 23, 2004 8:33 pm

What is this symbol @ ?

Post by TIGER »

I so some times there is a @ symbol in from of procedure call or
variable.

What is it for ?
PIII450 128RAM TNT2
AlGonzalez
User
User
Posts: 53
Joined: Sun Feb 15, 2004 6:04 am
Location: Easley, SC, USA

Post by AlGonzalez »

See Pointers in the Help file.
Addresses of procedures

Normally only advanced programmers need to find the address of procedures. Probably the most common reason for needing the address of a procedure is when dealing with the OS at a low-level. Some OSes allow you to specify callback or hook functions (for some operations) which get called by the OS and allows the programmer to extend the ability of the OS routine. The address of a procedure is found in a similar way to variables.

    Example:

    Procedure WindowCB(WindowID.l, Message.l, wParam.l, lParam.l)
         ; This is where the processing of your callback procedure would be performed
    EndProcedure

    ; A special callback for the Windows OS allowing you to process window events
    SetWindowCallback( @WindowCB() )
HTH
ricardo
Addict
Addict
Posts: 2438
Joined: Fri Apr 25, 2003 7:06 pm
Location: Argentina

Re: What is this symbol @ ?

Post by ricardo »

TIGER wrote:I so some times there is a @ symbol in from of procedure call or
variable.

What is it for ?
Its the addres of the procedure or the variable.
ARGENTINA WORLD CHAMPION
freak
PureBasic Team
PureBasic Team
Posts: 5940
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Post by freak »

quidquid Latine dictum sit altum videtur
Post Reply