[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Customize create and probe maps questions
From: |
Wojtek Kopczuk |
Subject: |
Re: Customize create and probe maps questions |
Date: |
Mon, 02 Dec 1996 20:50:02 -0500 |
Roger M. Burkhart wrote:
> > 3. It is much less important but I would greatly appreciate
> > an answer. I use forwarding in one of my classes and every
> > time I use a method that is forwarded, during compilation
> > I get a warning: `class' does not respond to `method:' what makes
> > an output really messy. It certainly doesn't respond to it,
> > it forwards it... Is there any way to stop it?
> Yes. The problem is typically with default type checking performed by the
> compiler whenever it thinks it knows the class of an object. The workaround
> is to case a receiver of class type to type (id), which is all it takes
> to shut the compiler up. For example, [(id)classReceiver doSomething: foo];.
> Don't know your exact situation, but casting to (id) is what I always do
> to suppress these warning messages.
That's exactly what I need. It is so obvious that one wonders how
he couldn't find it by himself. Especially because I've seen this kind
of casting a few time in various places. Thank you.
Wojtek
--
-----------------------------------------------------------
Wojtek Kopczuk "There is no third way between
address@hidden right and wrong"
IGS: wojtek Friedrich von Hayek
http://www.econ.lsa.umich.edu/~wojtek
-----------------------------------------------------------