[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: NSString/NSAttributedString and compiler warnings
From: |
Manuel Guesdon |
Subject: |
Re: NSString/NSAttributedString and compiler warnings |
Date: |
Sat, 19 Apr 2003 11:33:27 +0200 (CEST) |
Hi,
On Sat, 19 Apr 2003 06:43:33 +0000 (GMT) Axel 'Mikesch' Katerbau
<axel@objectpark.org> wrote:
>| If I write...
>|
>| NSMutableString *string = [NSMutableString string];
>|
>| ...the compiler warns me about non-matching types for assignment. Which
>| seems rather odd to me. Is this the intended behavior? Does anybody
>| have the same effect?
The +string call is the one declared for NSString which return a NSString* so
you have to cast it:
NSMutableString *string = (NSMutableString*)[NSMutableString string];
Manuel
--
______________________________________________________________________
Manuel Guesdon - ORANGE CONCEPT <mguesdon@orange-concept.com>
14 rue Jean-Baptiste Clement - 93200 Saint-Denis - France
Tel: +33 1 4940 0997 - Fax: +33 1 4940 0998