[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Swarm-Support] When did gcc get so lenient about the location of va
From: |
Bill Northcott |
Subject: |
Re: [Swarm-Support] When did gcc get so lenient about the location of variable declarations? |
Date: |
Tue, 15 Mar 2005 11:13:41 +1100 |
On 15/03/2005, at 4:13 AM, Paul Johnson wrote:
I need help with one piece of syntax. Recall you can tell the
compiler that a class exists, although it has not been presented yet,
with the directive
@class TheClassName
IF you do that, then you can use (TheClassName *) as a return type and
the compiler does not bother you.
What is the equivalent declaration for a protocol?
From the Objective-C language manual syntax definitions:
protocol-declaration:
@protocol protocol-name
[ protocol-reference-list ]
[ interface-declaration-list ]
@end
protocol-declaration-list:
@protocol < protocol-list > ;
class-declaration-list:
@class class-list ;
Which is hopefully self-explanatory. So I guess you need:
@protocol < SomeProtocol SomeOtherProtocol >;
Bill