anchor.diff:          match command.commandType with
           | SwitchMode mode ->
               match mode with
  -            | NormalMode -> textEditorData.Caret.Mode <- CaretMode.Block
  -            | VisualMode -> textEditorData.Caret.Mode <- CaretMode.Block
  -            | InsertMode -> textEditorData.Caret.Mode <- CaretMode.Insert
  -            { vimState with mode = mode }
  +            | NormalMode -> 
  +                textEditorData.Caret.Mode <- CaretMode.Block
  +                { vimState with mode = mode }
  +            | VisualMode -> 
  +                textEditorData.Caret.Mode <- CaretMode.Block
  +                { vimState with mode = mode }
  +            | InsertMode ->
  +                textEditorData.Caret.Mode <- CaretMode.Insert
  +                { vimState with mode = mode; keys = [] }
           | _ -> vimState
   
       let (|Digit|_|) character =
  
positive.code:             | _ -> None, keyList
  
          let run = getCommand multiplier
          let action =
              match state.mode, keyList with
              | InsertMode, [ "<esc>" ] -> [ run (SwitchMode NormalMode) Nothing ]
  
negative.code:         let editorData = x.Editor.GetContent<ITextEditorDataProvider>().GetTextEditorData()
          editorData.Caret.Mode <- CaretMode.Block
  
      override x.KeyPress descriptor =
          let editorData = x.Editor.GetContent<ITextEditorDataProvider>().GetTextEditorData()
          let oldState = vimState
  
          let newState, handledKeyPress = handleKeyPress vimState descriptor editorData
          LoggingService.LogDebug (sprintf "%A %A" newState handledKeyPress)
          vimState <- newState
          match oldState.mode with
          | InsertMode -> base.KeyPress descriptor
          | _ -> false
  