aboutsummaryrefslogtreecommitdiffstats
path: root/unpack.go
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2016-07-15 16:40:37 -0700
committerColin Cross <ccross@android.com>2016-07-15 16:43:42 -0700
commitba5bf880bfe6b911da57997f9ebc3a46d69980ca (patch)
treed62f7dab3e664992ba82c7767b4a148661c4cf09 /unpack.go
parentf9dbc3becc0fcdcb49bb6e6992a023fa4de7de80 (diff)
downloadandroid_build_blueprint-ba5bf880bfe6b911da57997f9ebc3a46d69980ca.tar.gz
android_build_blueprint-ba5bf880bfe6b911da57997f9ebc3a46d69980ca.tar.bz2
android_build_blueprint-ba5bf880bfe6b911da57997f9ebc3a46d69980ca.zip
Fix error messages containing variable types
value.Type and value.Pos changed to methods, change the users that were not caught by error checking to use Type() or Pos(). Change-Id: I295a658c007fa2de68c89fb85ee367fbea5ed1aa
Diffstat (limited to 'unpack.go')
-rw-r--r--unpack.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/unpack.go b/unpack.go
index f7e0a2d..3e21203 100644
--- a/unpack.go
+++ b/unpack.go
@@ -279,7 +279,7 @@ func unpackBool(boolValue reflect.Value, property *parser.Property) []error {
if !ok {
return []error{
fmt.Errorf("%s: can't assign %s value to bool property %q",
- property.Value.Pos, property.Value.Type, property.Name),
+ property.Value.Pos(), property.Value.Type(), property.Name),
}
}
boolValue.SetBool(b.Value)
@@ -293,7 +293,7 @@ func unpackString(stringValue reflect.Value,
if !ok {
return []error{
fmt.Errorf("%s: can't assign %s value to string property %q",
- property.Value.Pos, property.Value.Type, property.Name),
+ property.Value.Pos(), property.Value.Type(), property.Name),
}
}
stringValue.SetString(s.Value)
@@ -306,7 +306,7 @@ func unpackSlice(sliceValue reflect.Value, property *parser.Property) []error {
if !ok {
return []error{
fmt.Errorf("%s: can't assign %s value to list property %q",
- property.Value.Pos, property.Value.Type, property.Name),
+ property.Value.Pos(), property.Value.Type(), property.Name),
}
}
@@ -332,7 +332,7 @@ func unpackStruct(namePrefix string, structValue reflect.Value,
if !ok {
return []error{
fmt.Errorf("%s: can't assign %s value to map property %q",
- property.Value.Pos, property.Value.Type, property.Name),
+ property.Value.Pos(), property.Value.Type(), property.Name),
}
}