code: function installEditorListeners(editor, previousEditor) {
              // always clean up cached scope and hint info
              resetCachedHintContext();
  
              if (!jsHintsEnabled) {
                  return;
              }
  
              if (editor && HintUtils.isSupportedLanguage(LanguageManager.getLanguageForPath(editor.document.file.fullPath).getId())) {
                  initializeSession(editor, previousEditor);
                  editor
                      .on(HintUtils.eventName("change"), function (event, editor, changeList) {
                          if (!ignoreChange) {
                              ScopeManager.handleFileChange(changeList);
                          }
                          ignoreChange = false;
                      });
              } else {
                  session = null;
              }
          }
docs: /*
  Connects to the given editor, creating a new Session & adding listeners
  
  @param {?Editor} editor - editor context on which to listen for
  changes. If null, 'session' is cleared.
  @param {?Editor} previousEditor - the previous editor