[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: return type for a method parameter & assigning probe buttons
From: |
William S. Shu |
Subject: |
Re: return type for a method parameter & assigning probe buttons |
Date: |
Tue, 07 Sep 1999 20:36:39 +0100 |
Thanks for the insight, Marcus
William.
"Marcus G. Daniels" wrote:
> >>>>> "WS" == William S Shu <address@hidden> writes:
>
> WS> Problem 1: Objective-C) How can one pass a method as an argument
> WS> as well as the type of its return value?
> [ ... deleted..]Generic return typing is hairy problem. If you really want to
> be
> able to return generic types you need to use GCC builtins and the
> performv: method. Something like this:
>
> - (double)call: (SEL)sel
> {
> __builtin_return ([self performv: sel : __builtin_apply_args ()]);
> }
>
> Unfortunately the __builtin_{return/apply_args} are deprecated in GCC
> and actually fail on some platforms (e.g. Sparc). (For Java things,
> we take care of argument frame packing and unpacking by hand, using platform
> specific code.)
> [... deleted ...]
>
> WS> val += [obj valueOf] <====== **** return type assumed to be id
>
> This is actually invalid syntax. You'd have to say [obj perform: valueOf].
sorry: retyped code at that level.
> WS> How do I get to probe both objects (in fact any object) on the
> WS> raster by using the same mouse button.
>
> WS> [worldRaster setButton: ButtonRight // use Right button
> WS> Client: personDisplay
> WS> Message: M(makeProbeAtX:Y:)];
>
> Send a different message, one that has the effect of calling
> makeProbeAtX:Y: twice.
==================================
Swarm-Support is for discussion of the technical details of the day
to day usage of Swarm. For list administration needs (esp.
[un]subscribing), please send a message to <address@hidden>
with "help" in the body of the message.
- Re: 3rd Problem Installing Swarm2.0 in LinuxPPC R5, (continued)
- Re: 3rd Problem Installing Swarm2.0 in LinuxPPC R5, Marcus G. Daniels, 1999/09/05
- 4th Problem Installing Swarm2.0 in LinuxPPC R5, Darren Schreiber, 1999/09/06
- Re: 4th Problem Installing Swarm2.0 in LinuxPPC R5, Marcus G. Daniels, 1999/09/06
- Re: 4th Problem Installing Swarm2.0 in LinuxPPC R5, Darren Schreiber, 1999/09/07
- Using forEach:, Darren Schreiber, 1999/09/07
- Re: Using forEach:, Norberto Eiji Nawa(0.3.31), 1999/09/07
- Re: Using forEach:, Ken Cline, 1999/09/07
- Re: 4th Problem Installing Swarm2.0 in LinuxPPC R5, Marcus G. Daniels, 1999/09/07
- return type for a method parameter & assigning probe buttons, William S. Shu, 1999/09/07
- Re: return type for a method parameter & assigning probe buttons, Marcus G. Daniels, 1999/09/07
- Re: return type for a method parameter & assigning probe buttons,
William S. Shu <=
- [no subject], DARREN MATTHEW SCHREIBER, 1999/09/07
- Re: none, Marcus G. Daniels, 1999/09/07
- Dendogram, Darren Schreiber, 1999/09/08
- Re: Dendogram, Marcus G. Daniels, 1999/09/08
- Display direction, Jayshree Sarma, 1999/09/08
- Re: Display direction, Marcus G. Daniels, 1999/09/08
- Error Message - Swarm-1.4.1, Jayshree Sarma, 1999/09/09
- Re: Error Message - Swarm-1.4.1, Marcus G. Daniels, 1999/09/09
- Re: Error Message - Swarm-1.4.1, Jayshree Sarma, 1999/09/09
- Re: Error Message - Swarm-1.4.1, Paul E. Johnson, 1999/09/09