From d23ce8498e2f94b2ce50cd48e54ea3fb67ae8730 Mon Sep 17 00:00:00 2001 From: mccallum Date: Tue, 24 Sep 1996 17:41:03 +0000 Subject: [PATCH] ([NSString -copy]): New method. Now -copy sent to strings should work. (Added temporarily until this problem is fixed by me overhaul of the string classes to separate Core and NonCore methods.) git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@1827 72102866-910b-0410-8b05-ffd578937521 --- Source/NSString.m | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Source/NSString.m b/Source/NSString.m index 98930fe4a..3eb9d36da 100644 --- a/Source/NSString.m +++ b/Source/NSString.m @@ -1201,6 +1201,15 @@ handle_printf_atsign (FILE *stream, return [[[self class] allocWithZone:zone] initWithString:self]; } +/* xxx Temporarily put this NSObject-like implementation here, so + we don't get String's Collection implementation. + When we separate Core from NonCore methods, this problem will + go away. */ +- copy +{ + return [self copyWithZone: NS_NOZONE]; +} + - mutableCopyWithZone: (NSZone*)zone { return [[[[self class] _mutableConcreteClass] allocWithZone:zone]