コード例 #1
0
ファイル: DebugFrame.cs プロジェクト: techarch/ironruby
 internal DebugFrame(
     DebugThread thread,
     FunctionInfo funcInfo,
     IRuntimeVariables liftedLocals,
     int frameOrder)
     : this(thread, funcInfo) {
     _liftedLocals = liftedLocals;
     _stackDepth = frameOrder;
 }
コード例 #2
0
 internal DebugRuntimeVariables(IRuntimeVariables runtimeVariables) {
     _runtimeVariables = runtimeVariables;
 }
コード例 #3
0
ファイル: LuaOps.cs プロジェクト: ericmj/IronLua
 public static void VarargsAssign(IRuntimeVariables variables, object[] values)
 {
     var variablesArray = VarargsAssign(variables.Count, values);
     for (var i = 0; i < variables.Count; i++)
         variables[i] = variablesArray[i];
 }
コード例 #4
0
ファイル: DebugFrame.cs プロジェクト: techarch/ironruby
        /// <summary>
        /// // This method is called from the generator to update the frame with generator's locals
        /// </summary>
        internal void ReplaceLiftedLocals(IRuntimeVariables liftedLocals) {
            Debug.Assert(_liftedLocals == null || liftedLocals.Count >= _liftedLocals.Count);

            IRuntimeVariables oldLiftecLocals = _liftedLocals;

            // Replace the list of IStrongBoxes with the new list
            _liftedLocals = liftedLocals;

            if (oldLiftecLocals != null) {
                for (int i = 0; i < oldLiftecLocals.Count; i++) {
                    if (!_funcInfo.Variables[i].IsParameter && i < _liftedLocals.Count)
                        _liftedLocals[i] = oldLiftecLocals[i];
                }
            }

            // Null out scope/variable states to force creation of new ones
            _variables.Clear();
        }
コード例 #5
0
ファイル: DefaultDebugThread.cs プロジェクト: TerabyteX/main
 public FrameRuntimeVariablesPair(IRuntimeVariables runtimeVariables, DebugFrame frame)
 {
     RuntimeVariables = runtimeVariables;
     Frame = frame;
 }
コード例 #6
0
 private static IRuntimeVariables MergeRuntimeVariables(IRuntimeVariables first, IRuntimeVariables second, int[] indexes)
 {
     return(new RuntimeOps.MergedRuntimeVariables(first, second, indexes));
 }
コード例 #7
0
ファイル: DefaultDebugThread.cs プロジェクト: zuvys/dlr
 public FrameRuntimeVariablesPair(IRuntimeVariables runtimeVariables, DebugFrame frame)
 {
     RuntimeVariables = runtimeVariables;
     Frame            = frame;
 }
コード例 #8
0
        public static IRuntimeVariables MergeRuntimeVariables(IRuntimeVariables first, IRuntimeVariables second, int[] indexes)
        {
            Contract.Ensures(Contract.Result <System.Runtime.CompilerServices.IRuntimeVariables>() != null);

            return(default(IRuntimeVariables));
        }
コード例 #9
0
ファイル: LuaTrace.cs プロジェクト: SPARTAN563/IronLua
        public FunctionStack(string identifier)
        {
            Identifier = identifier;

            Context = null;
            UpScope = null;
            ExecScope = null;
            UpValues = null;
            UpValueNames = null;
            LocalVariables = null;
            LocalVariableNames = null;
            Locals = null;
        }
    public static IRuntimeVariables MergeRuntimeVariables(IRuntimeVariables first, IRuntimeVariables second, int[] indexes)
    {
      Contract.Ensures(Contract.Result<System.Runtime.CompilerServices.IRuntimeVariables>() != null);

      return default(IRuntimeVariables);
    }
コード例 #11
0
 /// <summary>
 /// Creates a new expression quoter.
 /// </summary>
 /// <param name="locals">The hoisted locals information gathered by the compiler at compile time.</param>
 /// <param name="closure">The closure to access for the binding of hoisted variables.</param>
 public ExpressionQuoter(HoistedLocals locals, IRuntimeVariables closure)
 {
     _locals  = locals;
     _closure = closure;
 }
コード例 #12
0
 internal static IRuntimeVariables Create(IRuntimeVariables first, IRuntimeVariables second, int[] indexes)
 {
     return(new LightLambdaClosureVisitor.MergedRuntimeVariables(first, second, indexes));
 }
コード例 #13
0
 private MergedRuntimeVariables(IRuntimeVariables first, IRuntimeVariables second, int[] indexes)
 {
     this._first   = first;
     this._second  = second;
     this._indexes = indexes;
 }
コード例 #14
0
 internal ScopedRuntimeVariables(IList<VariableInfo> variableInfos, IRuntimeVariables variables)
 {
     _variableInfos = variableInfos;
     _variables = variables;
 }
コード例 #15
0
 /// <summary>
 /// Creates an <see cref="IRuntimeVariables"/> object providing access to closed over variables.
 /// </summary>
 /// <param name="closure">The closure containing the variables.</param>
 /// <param name="indexes">The indices into the closure where variables are found.</param>
 public RuntimeVariableList(IRuntimeVariables closure, long[] indexes)
 {
     _closure = closure;
     _indexes = indexes;
 }
コード例 #16
0
 /// <summary>
 ///     Combines two runtime variable lists and returns a new list.
 /// </summary>
 /// <param name="first">The first list.</param>
 /// <param name="second">The second list.</param>
 /// <param name="indexes">The index array indicating which list to get variables from.</param>
 /// <returns>The merged runtime variables.</returns>
 // [Obsolete("do not use this method", true), EditorBrowsable(EditorBrowsableState.Never)]
 public static IRuntimeVariables MergeRuntimeVariables(IRuntimeVariables first, IRuntimeVariables second, int[] indexes)
 {
     return(new MergedRuntimeVariables(first, second, indexes));
 }
コード例 #17
0
ファイル: LuaTrace.cs プロジェクト: SPARTAN563/IronLua
        public FunctionStack(CodeContext context, LuaScope upScope, LuaScope execScope, string identifier)
        {
            ContractUtils.Requires(context != null);

            Context = context;
            UpScope = upScope;
            ExecScope = execScope;

            if (UpScope != null)
                UpValueNames = UpScope.GetLocalNames().ToArray();

            if (ExecScope != null)
                LocalVariableNames = ExecScope.GetLocalNames().ToArray();

            if (ExecScope != null && ExecScope.LocalsCount > 0)
                Locals = new Stack<VariableAccess>();
            else
                Locals = null;

            Identifier = identifier;

            LocalVariableNames = null;
            LocalVariables = null;
            UpValueNames = null;
            UpValues = null;
        }
コード例 #18
0
 internal MergedRuntimeVariables(IRuntimeVariables first, IRuntimeVariables second, int[] indexes)
 {
     _first = first;
     _second = second;
     _indexes = indexes;
 }
コード例 #19
0
 private static string GetInfo(IRuntimeVariables vars)
 {
     return("{ Count = " + vars.Count + ", Values = { " + string.Join(", ", Enumerable.Range(0, vars.Count).Select(i => vars[i])) + " } }");
 }
コード例 #20
0
ファイル: DefaultDebugThread.cs プロジェクト: zuvys/dlr
 internal void LiftVariables(IRuntimeVariables runtimeVariables)
 {
     // Don't create the frame object right away.  Create it when it's actually needed for debugging.
     _frames.Add(new FrameRuntimeVariablesPair(new DebugRuntimeVariables(runtimeVariables), null));
 }
コード例 #21
0
 internal ScopedRuntimeVariables(IList <VariableInfo> variableInfos, IRuntimeVariables variables)
 {
     _variableInfos = variableInfos;
     _variables     = variables;
 }
コード例 #22
0
 internal MergedRuntimeVariables(IRuntimeVariables first, IRuntimeVariables second, int[] indexes)
 {
     _first   = first;
     _second  = second;
     _indexes = indexes;
 }
コード例 #23
0
ファイル: RuntimeOps.cs プロジェクト: kerwon/dlr
 public static void LiftVariables(DebugThread thread, IRuntimeVariables runtimeVariables)
 {
     ((DefaultDebugThread)thread).LiftVariables(runtimeVariables);
 }
コード例 #24
0
ファイル: DefaultDebugThread.cs プロジェクト: TerabyteX/main
 internal void LiftVariables(IRuntimeVariables runtimeVariables)
 {
     // Don't create the frame object right away.  Create it when it's actually needed for debugging.
     _frames.Add(new FrameRuntimeVariablesPair(new DebugRuntimeVariables(runtimeVariables), null));
 }
コード例 #25
0
ファイル: RuntimeOps.cs プロジェクト: kerwon/dlr
 public static void ReplaceLiftedLocals(DebugFrame frame, IRuntimeVariables liftedLocals)
 {
     frame.ReplaceLiftedLocals(liftedLocals);
 }
コード例 #26
0
 internal static IRuntimeVariables Create(IRuntimeVariables first, IRuntimeVariables second, int[] indexes)
 {
     return(new MergedRuntimeVariables(first, second, indexes));
 }
コード例 #27
0
 internal DebugRuntimeVariables(IRuntimeVariables runtimeVariables)
 {
     _runtimeVariables = runtimeVariables;
 }
コード例 #28
0
 private static string GetInfo(IRuntimeVariables vars)
 {
     return "{ Count = " + vars.Count + ", Values = { " + string.Join(", ", Enumerable.Range(0, vars.Count).Select(i => vars[i])) + " } }";
 }
コード例 #29
0
ファイル: LocalsDictionary.cs プロジェクト: rudimk/dlr-dotnet
 public LocalsDictionary(IRuntimeVariables locals, SymbolId[] symbols)
 {
     Assert.NotNull(locals, symbols);
     _locals  = locals;
     _symbols = symbols;
 }
コード例 #30
0
ファイル: LocalsDictionary.cs プロジェクト: jcteague/ironruby
 public LocalsDictionary(IRuntimeVariables locals, SymbolId[] symbols) {
     Assert.NotNull(locals, symbols);
     _locals = locals;
     _symbols = symbols;
 }
コード例 #31
0
 public static IRuntimeVariables MergeRuntimeVariables(IRuntimeVariables first, IRuntimeVariables second, int[] indexes)
 {
     throw new NotImplementedException();
 }