Bug/Issue?: Control-C doesn't work in some cases.
----------------------------------------------------------------------
| Sage Version 3.4.2, Release Date: 2009-05-05 |
| Type notebook() for the GUI, and license() for information. |
----------------------------------------------------------------------
sage: var('x,y,z')
(x, y, z)
sage: time f = (x+y+z)^5
CPU times: user 0.00 s, sys: 0.00 s, total: 0.00 s
Wall time: 0.00 s
sage: g = f*(f+1)
sage: timeit('g.expand()')
5 loops, best of 3: 53.2 ms per loop
sage: %prun g.expand()
8890 function calls in 0.069 CPU seconds
Ordered by: internal time
ncalls tottime percall cumtime percall filename:lineno(function)
1 0.065 0.065 0.069 0.069 {method 'expand' of 'sage.symbolic.expression.Expression' objects}
8863 0.003 0.000 0.003 0.000 functional.py:393(imag)
1 0.000 0.000 0.069 0.069 <string>:1(<module>)
4 0.000 0.000 0.000 0.000 arith.py:1140(gcd)
4 0.000 0.000 0.000 0.000 {method 'lcm' of 'sage.structure.element.PrincipalIdealDomainElement' objects}
4 0.000 0.000 0.000 0.000 arith.py:1256(lcm)
4 0.000 0.000 0.000 0.000 {method 'gcd' of 'sage.rings.integer.Integer' objects}
8 0.000 0.000 0.000 0.000 {hasattr}
1 0.000 0.000 0.000 0.000 {method 'disable' of '_lsprof.Profiler' objects}
sage: %prun v = [g.expand() for _ in range(1000)]
^CException exceptions.KeyboardInterrupt: KeyboardInterrupt() in 'sage.symbolic.pynac.py_is_real' ignored
^CException exceptions.KeyboardInterrupt: KeyboardInterrupt() in 'sage.symbolic.pynac.py_is_real' ignored
^CException exceptions.KeyboardInterrupt: KeyboardInterrupt() in 'sage.symbolic.pynac.py_is_real' ignored