Quantcast
Channel: .Net arrays with lower bound > 0 - Stack Overflow
Browsing latest articles
Browse All 6 View Live

Answer by usr for .Net arrays with lower bound > 0

The .NET CLR differentiates between two internal array object formats: SZ arrays and MZ arrays. MZ arrays can be multi-dimensional and store their lower bounds in the object.The reason for this...

View Article



Answer by SoLaR for .Net arrays with lower bound > 0

Know it's old question, but to fully explain it.If type (in this case a single-dimension array with lower bound > 0) can't be created by typed code, simply reflected type instance can't be consumed...

View Article

Answer by Joel Coehoorn for .Net arrays with lower bound > 0

Just store your lower bound in a const offset integer, and subtract that value from whatever your source returns as the index.Also: this is an old VB6 feature. I think there might be an attribute to...

View Article

Answer by Coincoin for .Net arrays with lower bound > 0

The reason why you can't cast from one to the other is that this is evil.Lets say you create an array of object[5..9] and you pass it to a function F as an object[].How would the function knows that...

View Article

Answer by Martin Marconcini for .Net arrays with lower bound > 0

I'm not sure about why that can't be passed as Object[], but wouldn't be easy if you just create a real class to wrap an array and handle your "weird logic" in there?You'd get the benefits of using a...

View Article


.Net arrays with lower bound > 0

Although perhaps a bizare thing to want to do, I need to create an Array in .Net with a lower bound > 0. This at first seems to be possible, using:Array.CreateInstance(typeof(Object), new int[] {2},...

View Article
Browsing latest articles
Browse All 6 View Live




Latest Images