I found the particular trace sequence that aborts the calling script.
Is this expected?
)r test-1.input
Notice that all goes well until line 15; where I try to reset the
"stats". Which happens.
But the following code (i.e. the reading of test-1.input is aborted.
Not even hidden; after the stoppage ask:
aa
)trace
the results are in the test.log file. So the trace is still running as
is the )spool; but test.input has stopped being read.
Ray
--
You received this message because you are subscribed to the Google Groups "FriCAS -
computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/fricas-devel.
For more options, visit https://groups.google.com/d/optout.
)clear all
)system rm test.log
)spool test.log
)r trace_reset
-- prime the pump
test_sub(1)
--
--
-- Start tracing
)trace test_sub )count )time )only a
-- Execute
test_sub(2)
test_sub(3)
-- Stats
)trace )stats
)trace )stats reset
-- But the next line (and this one) doesn't get executed
aa:=5
test_sub(4)
--
--
output("passed")
)spool
output("hi there")
test_sub(p) ==
output("testing test_sub")
p^2
--
facc(n) == if n < 3 then n else n * facc (n - 1)
)r trace_reset
output("hi there")
hi there
Type: Void
test_sub(p) ==
output("testing test_sub")
p^2
Type: Void
--
facc(n) == if n < 3 then n else n * facc (n - 1)
Type: Void
-- prime the pump
test_sub(1)
Compiling function test_sub with type PositiveInteger ->
PositiveInteger
testing test_sub
(4) 1
Type: PositiveInteger
--
--
-- Start tracing
)trace test_sub )count )time )only a
Function traced: test_sub
-- Execute
test_sub(2)
testing test_sub
(5) 4
Type: PositiveInteger
test_sub(3)
testing test_sub
(6) 9
Type: PositiveInteger
-- Stats
)trace )stats
--------------------- Traced function execution times ----------------------
*1;test_sub;1;frame1 : 0.0 sec.
--------------------- Traced function execution counts ---------------------
*1;test_sub;1;frame1 : 2 times
Function traced: test_sub
)trace )stats reset
Trace facility timers, space counts and execution counts have been
reset.
(7) -> aa
(7) aa
Type: Variable(aa)
(8) -> )trace
Function traced: test_sub
(8) -> )trace )stats
--------------------- Traced function execution times ----------------------
*1;test_sub;1;frame1 : 0.0 sec.
--------------------- Traced function execution counts ---------------------
*1;test_sub;1;frame1 : 0 times
Function traced: test_sub
(8) ->