[IronPython] System.Array
Kristof Wagemans
kristof.wagemans at gmail.com
Fri Sep 8 19:12:26 CEST 2006
The question is: is there an alternative syntax to create an array of a
specific length. Now you have to go through a static method of System.Array
to create it.
I wanted to know if you can create it directly and keep it looking like
System.Array[int]. Something like: System.Array[int](3). But this throws an
exception.
_____
From: users-bounces at lists.ironpython.com
[mailto:users-bounces at lists.ironpython.com] On Behalf Of J. Merrill
Sent: Friday 8 September 2006 18:57
To: Discussion of IronPython
Subject: Re: [IronPython] System.Array
Did you leave some part of your own question un-answered? CreateInstance
does just what you said you wanted to know how to do, doesn't it?
At 04:22 AM 9/8/2006, Kristof Wagemans wrote
You can create an int array of length 3 with:
System.Array[int]((1,2,3))
Is there an alternative syntax to create an int array of length 3 without
passing in a tuple with 3 values? I know that I can create one with:
System.Array.CreateInstance(int,3)
J. Merrill / Analytical Software Corp
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20060908/60fcc764/attachment.html>
More information about the Ironpython-users
mailing list