Sometimes when poking around in IEx, I will mis-pair a bracket or quote and get “stuck”. This often happens if I mispaste something.
irb I could always just ctrl-c to basically cancel the current input buffer and put me back in the “root” of the interpreter.
irb(main):002:1* arst( irb(main):003:1* nieo irb(main):004:1> ^C irb(main):002:0>
In IEx I get this
iex(1)> arst( ...(1)> nieo ...(1)> BREAK: (a)bort (A)bort with dump (c)ontinue (p)roc info (i)nfo (l)oaded (v)ersion (k)ill (D)b-tables (d)istribution
And from my poking around, a/A quit IEx, c puts me back where I was, p,i,l,v,D,d,k are informational or for killing processes (maybe the current IEx is hidden in there).
Is there a way to just throw out all the current input (short of working out what pair is open and manually closing them all)? I want to retain the rest of my IEx state.