aboutsummaryrefslogtreecommitdiffstats
path: root/go/bls/bls.go
diff options
context:
space:
mode:
Diffstat (limited to 'go/bls/bls.go')
-rw-r--r--go/bls/bls.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/go/bls/bls.go b/go/bls/bls.go
index 0506c10..2f7e8ca 100644
--- a/go/bls/bls.go
+++ b/go/bls/bls.go
@@ -88,6 +88,14 @@ func (sec *SecretKey) SetStr(s string) error {
return nil
}
+func (sec *SecretKey) SetArray(v []uint64) error {
+ if len(v) != 4 {
+ return fmt.Errorf("bad size", len(v))
+ }
+ C.blsSecretKeySetArray(sec.self, (*C.uint64_t)(unsafe.Pointer(&v[0])))
+ return nil
+}
+
func (sec *SecretKey) Init() {
C.blsSecretKeyInit(sec.self)
}