13

I'm learning F#, and keep accidentally writing infinitely recursive functions..

When I call these in F# Interactive (FSI) through Visual Studio (2010 or 2012), I can't find a way to get out of it other than to restart Visual Studio. Is there any other - ideally faster - way out?

Grant Crofton
  • 8,895
  • 5
  • 28
  • 38
  • 1
    You want to cancel the current evaluation (right click on the FSI pane). No need to reset the whole of FSI, much less reboot VS! – J D Aug 01 '13 at 20:37

1 Answers1

16

Right click in the F# interactive window, and select Reset Interactive Session.

Cancel Interactive Evaluation should also work for you if you just want to cancel the current running function but to keep previous results.

Yin Zhu
  • 16,980
  • 13
  • 75
  • 117
  • Right click is the solution. Do you know how to let the shortcut `Ctrl-Break` (Cancel Interactive Evalution) work on a laptop? I tried `Fn+Ctrl+Pause`, (On my laptop, Break is on the Pause key color print.) It doesn't work. – Nick May 22 '15 at 09:52