【发布时间】:2016-02-12 00:50:49
【问题描述】:
首先我安装了最新的Edge Nuget Package。然后我正在运行基本的 hello world 启动示例,并且在 Windows 2010 w/Visual Studio 2015 上遇到了这个错误。
当我在 OS-X 上执行相同的 hello world 代码时,我得到了这个错误。
这里是局部变量树的一个突破。看起来错误可能类似。
代码如下所示。它实际上是从README.md of the repo 复制而来的。
using System;
using System.Threading.Tasks;
using EdgeJs;
class Program
{
public static async void Start()
{
var func = Edge.Func(@"
return function (data, callback) {
callback(null, 'Node.js welcomes ' + data);
}
");
Console.WriteLine(await func(".NET"));
Console.ReadKey();
}
static void Main(string[] args)
{
Task.Run((Action)Start).Wait();
}
}
【问题讨论】: