MCPcopy Create free account
hub / github.com/OpenEndedGroup/Field2 / equalCursorPos

Function equalCursorPos

lib/web/CodeMirror/src/line/pos.js:15–15  ·  view source on GitHub ↗
(a, b)

Source from the content-addressed store, hash-verified

13export function cmp(a, b) { return a.line - b.line || a.ch - b.ch }
14
15export function equalCursorPos(a, b) { return a.sticky == b.sticky && cmp(a, b) == 0 }
16
17export function copyPos(x) {return Pos(x.line, x.ch)}
18export function maxPos(a, b) { return cmp(a, b) < 0 ? b : a }

Callers 2

equalsMethod · 0.90
findPosHFunction · 0.90

Calls 1

cmpFunction · 0.70

Tested by

no test coverage detected