Re: Assertion failure in mini-trampolines.c

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Assertion failure in mini-trampolines.c

Geoff Norton-2
Please file a bug with a test case

Thanks

Sent from my iPhone

On 2011-03-09, at 8:44 PM, David Moles <[hidden email]> wrote:

Oops, correction: it doesn't blow up till I try to access otherInstance.AnotherProperty.

On Wed, Mar 9, 2011 at 5:41 PM, David Moles <[hidden email]> wrote:
Something in the vtable or somewhere is definitely hosed. It looks like one of this object's properties is getting replaced with the object's type name (as a string).

Basically I've got code of the form:

namespace MyNamespace {
class AClass {
IOtherClass TheProperty { get; }
}

interface IOtherClass {
bool AnotherProperty { get; }
}

class OtherClass : IOtherClass {
public bool AnotherProperty { get; }
public override String ToString() { return "Hi there"; }
}
}

And when this code executes:

void SomeFunction(AClass anInstance) {
var otherInstance = anInstance.TheProperty;
Console.Writeline("type: {0} value: {1}",
otherInstance.getType().Name, otherInstance);
}

It prints

type: String value: MyNamespace.AClass

-- when I would expect

type: OtherClass value: Hi there

-- and then it blows up.

On Wed, Mar 9, 2011 at 4:33 PM, David Moles <[hidden email]> wrote:
Correction: On closer examination, it looks like the relevant code is trying to access a property declared by [some interface].


On Wed, Mar 9, 2011 at 4:03 PM, David Moles <[hidden email]> wrote:
I've had several SIGABRT crashes recently of the form below:

System.String doesn't implement interface [some interface of mine]
* Assertion: should not be reached at ../../../../mono/mini/mini-trampolines.c:183

Am I doing something wrong here? There's a stack trace, but no obvious relevance to the failure (for instance, the interface it's complaining about isn't involved there, at least not directly).

--
David Moles



--
David Moles



--
David Moles



--
David Moles
_______________________________________________
MonoTouch mailing list
[hidden email]
http://lists.ximian.com/mailman/listinfo/monotouch

_______________________________________________
MonoTouch mailing list
[hidden email]
http://lists.ximian.com/mailman/listinfo/monotouch
Loading...