anchor.diff:  
     ;; auto-calculate cursorDx when pressedEnter is true
     (when result.pressedEnter
  -    (var prevCursorLine result.origLines[result.cursorLine-1])
  +    (var prevCursorLine result.inputLines[result.cursorLine-1])
       (set result.cursorDx (- result.cursorX prevCursorLine.length)))
   
     result)
  
positive.code: 
    (commitChar result origCh))
  
  (function processLine (result line)
    (initLine result line)
    (initIndent result)
  
    (setTabStops result)
  
    (var chars (str line NEWLINE))
    (forindex i 0 chars.length
      (processChar result chars[i]))
  
    (var unmatchedX result.firstUnmatchedCloseParenX)
    (when (&& (!= unmatchedX SENTINEL_NULL)
  
negative.code: 
        origText text            ;; [string] - original text
        origCursorX SENTINEL_NULL
        inputLines               ;; [string array] - input lines that we process line-by-line, char-by-char
        (text.split LINE_ENDING_REGEX)
  
        lines []                 ;; [string array] - resulting lines (with corrected parens or indentation)
        lineNo -1                ;; [integer] - line number we are processing
        ch ""                    ;; [string] - character we are processing (can be changed to indicate a replacement)
        x 0                      ;; [integer] - x position of the current character (ch)
  
        inputLineNo -1
        inputX 0
  
        parenStack []            ;; We track where we are in the Lisp tree by keeping a stack (array) of open-parens.
                                 ;; Stack elements are objects containing keys {ch, x, lineNo, indentDelta}
  