MCPcopy Index your code
hub / github.com/csev/py4e / rebaseHistSelSingle

Function rebaseHistSelSingle

tools/pythonauto/static/codemirrorepl/codemirror.js:6726–6733  ·  view source on GitHub ↗
(pos, from, to, diff)

Source from the content-addressed store, hash-verified

6724 // Rebasing/resetting history to deal with externally-sourced changes
6725
6726 function rebaseHistSelSingle(pos, from, to, diff) {
6727 if (to < pos.line) {
6728 pos.line += diff;
6729 } else if (from < pos.line) {
6730 pos.line = from;
6731 pos.ch = 0;
6732 }
6733 }
6734
6735 // Tries to rebase an array of history events given a change in the
6736 // document. If the change touches the same lines as the event, the

Callers 1

rebaseHistArrayFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected