[Mono-bugs] [Bug 590292] New: Runtime error when creating NSSet using NSSet.MakeNSObjectSet

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Mon Mar 22 14:51:33 EDT 2010


http://bugzilla.novell.com/show_bug.cgi?id=590292

http://bugzilla.novell.com/show_bug.cgi?id=590292#c0


           Summary: Runtime error when creating NSSet using
                    NSSet.MakeNSObjectSet
    Classification: Mono
           Product: MonoTouch
           Version: SVN
          Platform: Macintosh
        OS/Version: Mac OS X 10.6
            Status: NEW
          Severity: Critical
          Priority: P5 - None
         Component: Class Libraries
        AssignedTo: gnorton at novell.com
        ReportedBy: jim at arrowoodtechnologies.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---
           Blocker: ---


User-Agent:       Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US;
rv:1.9.0.16) Gecko/2009120206 Firefox/3.0.16

Cannot load anything into an NSSet.  Using NSSet.MakeNSObjectSet compiles but
throws runtime error below.  Place the following line in any executable block
of monotouch code to reproduce issue:

------

NSSet nsSet = NSSet.MakeNSObjectSet<NSString> (new NSString [] {new NSString
("mString")});  

------

Unhandled Exception: MonoTouch.Foundation.MonoTouchException: Objective-C
exception thrown.  Name: NSInvalidArgumentException Reason: *** -[NSMutableSet
initWithCapacity:]: method only defined for abstract class.  Define -[NSCFSet
initWithCapacity:]!
  at (wrapper managed-to-native)
MonoTouch.ObjCRuntime.Messaging:void_objc_msgSend_IntPtr (intptr,intptr,intptr)
  at MonoTouch.Foundation.NSSet.InitWithArray (MonoTouch.Foundation.NSArray
array) [0x0001c] in
/Users/plasma/Source/iphone/monotouch/Foundation/NSSet.g.cs:79 
  at MonoTouch.Foundation.NSSet.MakeNSObjectSet[NSString]
(MonoTouch.Foundation.NSString[] values) [0x0000d] in
/Users/plasma/Source/iphone/monotouch/Foundation/NSSet.cs:27 


Reproducible: Always

Steps to Reproduce:
Place the following line in any solution: 



NSSet nsSet = NSSet.MakeNSObjectSet<NSString> (new NSString [] {new NSString
("mString")});  

Actual Results:  
Unhandled Exception: MonoTouch.Foundation.MonoTouchException: Objective-C
exception thrown.  Name: NSInvalidArgumentException Reason: *** -[NSMutableSet
initWithCapacity:]: method only defined for abstract class.  Define -[NSCFSet
initWithCapacity:]!
  at (wrapper managed-to-native)
MonoTouch.ObjCRuntime.Messaging:void_objc_msgSend_IntPtr (intptr,intptr,intptr)
  at MonoTouch.Foundation.NSSet.InitWithArray (MonoTouch.Foundation.NSArray
array) [0x0001c] in
/Users/plasma/Source/iphone/monotouch/Foundation/NSSet.g.cs:79 
  at MonoTouch.Foundation.NSSet.MakeNSObjectSet[NSString]
(MonoTouch.Foundation.NSString[] values) [0x0000d] in
/Users/plasma/Source/iphone/monotouch/Foundation/NSSet.cs:27 

Expected Results:  
No Error

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list