summaryrefslogtreecommitdiff
path: root/libgo/go/database/sql/convert.go
diff options
context:
space:
mode:
authorian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>2012-02-09 08:19:58 +0000
committerian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>2012-02-09 08:19:58 +0000
commit2da6f72bb78de6e6ca3d387d970cb21bf36684be (patch)
tree7ca86535c5a6b99d4cc432ba5cfddabc5ee4ea16 /libgo/go/database/sql/convert.go
parent98ea39f2b59cc0a4a0a32b095e8f0faa84fd7882 (diff)
downloadgcc-2da6f72bb78de6e6ca3d387d970cb21bf36684be.tar.gz
libgo: Update to weekly.2012-02-07.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184034 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libgo/go/database/sql/convert.go')
-rw-r--r--libgo/go/database/sql/convert.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/libgo/go/database/sql/convert.go b/libgo/go/database/sql/convert.go
index e80420e5bb3..4924ac14e46 100644
--- a/libgo/go/database/sql/convert.go
+++ b/libgo/go/database/sql/convert.go
@@ -49,6 +49,11 @@ func convertAssign(dest, src interface{}) error {
case *string:
*d = string(s)
return nil
+ case *interface{}:
+ bcopy := make([]byte, len(s))
+ copy(bcopy, s)
+ *d = bcopy
+ return nil
case *[]byte:
*d = s
return nil
@@ -80,6 +85,9 @@ func convertAssign(dest, src interface{}) error {
*d = bv.(bool)
}
return err
+ case *interface{}:
+ *d = src
+ return nil
}
if scanner, ok := dest.(ScannerInto); ok {