mirror of https://github.com/Hilbis/Hilbish
11 lines
207 B
Go
11 lines
207 B
Go
|
package util
|
||
|
|
||
|
import "github.com/yuin/gopher-lua"
|
||
|
|
||
|
func Document(L *lua.LState, module lua.LValue, doc string) {
|
||
|
mt := L.NewTable()
|
||
|
L.SetField(mt, "__doc", lua.LString(doc))
|
||
|
|
||
|
L.SetMetatable(module, mt)
|
||
|
}
|