Forum General

Does Mono.Tasklets is still working?

LBrLBr USMember

Hello,

I've tried to run simple test case using Mono.Tasklets and the code looks like:

using Mono.Tasklets;

namespace ContinuationTest
{
class MainClass
{
public static void Main(string[] args)
{
var c = new Continuation();

        switch (c.Store(0))
        {
            case 0:
                System.Console.WriteLine("Stage 0");
                break;
            case 1:
                System.Console.WriteLine("Stage 1");
                break;
        }

        System.Console.WriteLine("Jumping to Stage 1 ...");
        c.Restore(1);
    }
}

}

When I run it on Windows 10 platform throwing exception:

...
Unhandled Exception:
System.MissingMethodException: Attempted to access a missing method.
at (wrapper managed-to-native) Mono.Tasklets.Continuation:alloc ()
at Mono.Tasklets.Continuation..ctor () <0x2290a7312d0 + 0x00018> in :0
at ContinuationTest.MainClass.Main (System.String[] args) <0x2290a730f00 + 0x0003a> in :0
[ERROR] FATAL UNHANDLED EXCEPTION: System.MissingMethodException: Attempted to access a missing method.
at (wrapper managed-to-native) Mono.Tasklets.Continuation:alloc ()
at Mono.Tasklets.Continuation..ctor () <0x2290a7312d0 + 0x00018> in :0
at ContinuationTest.MainClass.Main (System.String[] args) <0x2290a730f00 + 0x0003a> in :0
Press any key to continue . . .
...

When I use the same code on Linux ( Ubuntu 12 ) the error is:

A System.ArgumentException was thrown.
Continuation not initialized
Parameter name cont

Sign In or Register to comment.