1 Star 1 Fork 0

wmdng / lua

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
util_com.go 1.40 KB
一键复制 编辑 原始数据 按行查看 历史
wmdng 提交于 2021-01-12 20:21 . add init ver
// +build !js !wasm
/*
Copyright 2019 by ofunc
This software is provided 'as-is', without any express or implied warranty. In
no event will the authors be held liable for any damages arising from the use of
this software.
Permission is granted to anyone to use this software for any purpose, including
commercial applications, and to alter it and redistribute it freely, subject to
the following restrictions:
1. The origin of this software must not be misrepresented; you must not claim
that you wrote the original software. If you use this software in a product, an
acknowledgment in the product documentation would be appreciated but is not
required.
2. Altered source versions must be plainly marked as such, and must not be
misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.
*/
package util
import (
"gitee.com/wmdng/lua"
"gitee.com/wmdng/lua/lmodbase"
"gitee.com/wmdng/lua/lmodio"
"gitee.com/wmdng/lua/lmodmath"
"gitee.com/wmdng/lua/lmodos"
"gitee.com/wmdng/lua/lmodstring"
"gitee.com/wmdng/lua/lmodtable"
"gitee.com/wmdng/lua/lmodutf8"
)
// Open opens the buildin modules.
func Open(l *lua.State) {
l.Push(lmodbase.Open)
l.Call(0, 0)
l.Preload("string", lmodstring.Open)
l.Preload("utf8", lmodutf8.Open)
l.Preload("table", lmodtable.Open)
l.Preload("math", lmodmath.Open)
l.Preload("io", lmodio.Open)
l.Preload("os", lmodos.Open)
}
Go
1
https://gitee.com/wmdng/lua.git
git@gitee.com:wmdng/lua.git
wmdng
lua
lua
88f43f81e7f3

搜索帮助