Skip to content

Commit

Permalink
Spelling and grammar fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
scop authored and jackc committed Jul 30, 2022
1 parent 67a13b9 commit 49713e5
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion array_type.go
Expand Up @@ -11,7 +11,7 @@ import (

// ArrayType represents an array type. While it implements Value, this is only in service of its type conversion duties
// when registered as a data type in a ConnType. It should not be used directly as a Value. ArrayType is a convenience
// type for types that do not have an concrete array type.
// type for types that do not have a concrete array type.
type ArrayType struct {
elements []ValueTranscoder
dimensions []ArrayDimension
Expand Down
2 changes: 1 addition & 1 deletion enum_type.go
Expand Up @@ -2,7 +2,7 @@ package pgtype

import "fmt"

// EnumType represents a enum type. While it implements Value, this is only in service of its type conversion duties
// EnumType represents an enum type. While it implements Value, this is only in service of its type conversion duties
// when registered as a data type in a ConnType. It should not be used directly as a Value.
type EnumType struct {
value string
Expand Down
2 changes: 1 addition & 1 deletion hstore.go
Expand Up @@ -414,7 +414,7 @@ func parseHstore(s string) (k []string, v []Text, err error) {
r, end = p.Consume()
switch {
case end:
err = errors.New("Found EOS after ',', expcting space")
err = errors.New("Found EOS after ',', expecting space")
case (unicode.IsSpace(r)):
r, end = p.Consume()
state = hsKey
Expand Down
2 changes: 1 addition & 1 deletion inet.go
Expand Up @@ -198,7 +198,7 @@ func (dst *Inet) DecodeBinary(ci *ConnInfo, src []byte) error {
}

if len(src) != 8 && len(src) != 20 {
return fmt.Errorf("Received an invalid size for a inet: %d", len(src))
return fmt.Errorf("Received an invalid size for an inet: %d", len(src))
}

// ignore family
Expand Down
2 changes: 1 addition & 1 deletion interval.go
Expand Up @@ -174,7 +174,7 @@ func (dst *Interval) DecodeBinary(ci *ConnInfo, src []byte) error {
}

if len(src) != 16 {
return fmt.Errorf("Received an invalid size for a interval: %d", len(src))
return fmt.Errorf("Received an invalid size for an interval: %d", len(src))
}

microseconds := int64(binary.BigEndian.Uint64(src))
Expand Down
12 changes: 6 additions & 6 deletions testutil/testutil.go
Expand Up @@ -141,7 +141,7 @@ func TestPgxSuccessfulTranscodeEqFunc(t testing.TB, pgTypeName string, values []
}
}

// Derefence value if it is a pointer
// Dereference value if it is a pointer
derefV := v
refVal := reflect.ValueOf(v)
if refVal.Kind() == reflect.Ptr {
Expand Down Expand Up @@ -173,7 +173,7 @@ func TestDatabaseSQLSuccessfulTranscodeEqFunc(t testing.TB, driverName, pgTypeNa
}

for i, v := range values {
// Derefence value if it is a pointer
// Dereference value if it is a pointer
derefV := v
refVal := reflect.ValueOf(v)
if refVal.Kind() == reflect.Ptr {
Expand Down Expand Up @@ -235,7 +235,7 @@ func TestPgxSuccessfulNormalizeEqFunc(t testing.TB, tests []NormalizeTest, eqFun
t.Logf("Skipping: %#v does not implement %v", tt.Value, fc.name)
continue
}
// Derefence value if it is a pointer
// Dereference value if it is a pointer
derefV := tt.Value
refVal := reflect.ValueOf(tt.Value)
if refVal.Kind() == reflect.Ptr {
Expand Down Expand Up @@ -266,7 +266,7 @@ func TestDatabaseSQLSuccessfulNormalizeEqFunc(t testing.TB, driverName string, t
continue
}

// Derefence value if it is a pointer
// Dereference value if it is a pointer
derefV := tt.Value
refVal := reflect.ValueOf(tt.Value)
if refVal.Kind() == reflect.Ptr {
Expand Down Expand Up @@ -367,7 +367,7 @@ func TestPgxNullToGoZeroConversion(t testing.TB, pgTypeName string, zero interfa
}
}

// Derefence value if it is a pointer
// Dereference value if it is a pointer
derefZero := zero
refVal := reflect.ValueOf(zero)
if refVal.Kind() == reflect.Ptr {
Expand Down Expand Up @@ -416,7 +416,7 @@ func TestDatabaseSQLNullToGoZeroConversion(t testing.TB, driverName, pgTypeName
t.Fatal(err)
}

// Derefence value if it is a pointer
// Dereference value if it is a pointer
derefZero := zero
refVal := reflect.ValueOf(zero)
if refVal.Kind() == reflect.Ptr {
Expand Down

0 comments on commit 49713e5

Please sign in to comment.