Beispiel #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="VSDebugger"/> class.
 /// </summary>
 /// <param name="proxy">The Visual Studio debugger proxy running in Default AppDomain.</param>
 public VSDebugger(VSDebuggerProxy proxy)
 {
     Proxy = proxy;
     Context.SetUserTypeMetadata(ScriptCompiler.ExtractMetadata(new[]
     {
         typeof(CsDebugScript.CommonUserTypes.NativeTypes.cv.Mat).Assembly,     // CsDebugScript.CommonUserTypes.dll
     }));
 }
Beispiel #2
0
        protected void Execute_AutoCast(Action action)
        {
            lock (autoCastLock)
            {
                var originalUserTypeMetadata = Context.UserTypeMetadata;

                try
                {
                    Context.SetUserTypeMetadata(ScriptCompiler.ExtractMetadata(new[]
                    {
                        typeof(SharpDebug.CommonUserTypes.NativeTypes.std.@string).Assembly,
                        GetType().Assembly,
                    }));

                    action();
                }
                finally
                {
                    Context.SetUserTypeMetadata(originalUserTypeMetadata);
                }
            }
        }