-
Notifications
You must be signed in to change notification settings - Fork 1
/
wren.go
32 lines (28 loc) · 842 Bytes
/
wren.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
// Package wren provides bindings for Go programs to utilize and interact with the Wren scripting langues http://wren.io
package wren
/*
#cgo CFLAGS:
#cgo LDFLAGS: -lm
#include "wren.h"
*/
import "C"
//go:generate go run getWren.go
//go:generate go run createBindings.go -bindings 512
const (
// VersionString Wren's version as a string
VersionString string = C.WREN_VERSION_STRING
// VersionMajor Wren's major version number
VersionMajor int = C.WREN_VERSION_MAJOR
// VersionMinor Wren's minor version number
VersionMinor int = C.WREN_VERSION_MINOR
// VersionPatch Wren's patch version number
VersionPatch int = C.WREN_VERSION_PATCH
)
// VersionTuple returns Wren's version numbers as an array of 3 numbers
func VersionTuple() [3]int {
return [3]int{
C.WREN_VERSION_MAJOR,
C.WREN_VERSION_MINOR,
C.WREN_VERSION_PATCH,
}
}