コード例 #1
0
ファイル: Runner.cs プロジェクト: kayateia/climoo
        /// <summary>
        /// Queues a Coral function to run asynchronously.
        /// </summary>
        public static void CallFunction( State state, string name, object[] args, StackTrace.StackFrame frame )
        {
            // Convert the arguments.
            AstNode[] wrapped = WrapArgs( args );

            // Construct a synthetic AstIdentifier for the name.
            AstIdentifier id = new AstIdentifier( name );

            // Construct a synthetic AstCall.
            AstCall call = new AstCall( id, wrapped, frame );

            call.run( state );
        }
コード例 #2
0
ファイル: Runner.cs プロジェクト: kayateia/climoo
        /// <summary>
        /// Queues a Coral function to run asynchronously.
        /// </summary>
        public static void CallFunction( State state, FValue func, object[] args, StackTrace.StackFrame frame )
        {
            // Convert the arguments.
            AstNode[] wrapped = WrapArgs( args );

            // Construct a synthetic AstIdentifier for the name.
            AstNode funcNode = new WrapperAstObject( func );

            // Construct a synthetic AstCall.
            AstCall call = new AstCall( funcNode, wrapped, frame );

            call.run( state );
        }