Pointer cleanup (#78)

Remove unnecessary pointer receivers for Position and QueryResult
This commit is contained in:
Sam Broughton
2016-07-21 15:42:51 +01:00
committed by Thomas Pelletier
parent 64ff1ea4d5
commit 65ad89c1a7
2 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -18,12 +18,12 @@ type Position struct {
// String representation of the position.
// Displays 1-indexed line and column numbers.
func (p *Position) String() string {
func (p Position) String() string {
return fmt.Sprintf("(%d, %d)", p.Line, p.Col)
}
// Invalid returns whether or not the position is valid (i.e. with negative or
// null values)
func (p *Position) Invalid() bool {
func (p Position) Invalid() bool {
return p.Line <= 0 || p.Col <= 0
}