public void ShouldProvideAnOneIndexedMark() { var cursor = new Cursor(); var result = cursor.Mark(); result.Line.Should().Be(1, "the mark should be at line 1"); result.Column.Should().Be(1, "the mark should be at column 1"); }
private void StaleSimpleKeys() { foreach (SimpleKey simpleKey in simpleKeys) { if (simpleKey.IsPossible && (simpleKey.Line < cursor.Line || simpleKey.Index + 1024 < cursor.Index)) { if (simpleKey.IsRequired) { Mark mark = cursor.Mark(); throw new SyntaxErrorException(mark, mark, "While scanning a simple key, could not find expected ':'."); } simpleKey.IsPossible = false; } } }