We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
在自动生成的代码 tabtoy/v3/example/golang/table_gen.go 中,连续两次给 self.indexHandler["ExampleData"] 赋值,后面的值会冲掉前面的值吧?这导致 self.ExampleDataByID 一直为空
` // 初始化表实例 func NewTable() *Table {
self := &Table{ indexHandler: make(map[string]func()), resetHandler: make(map[string]func()), } self.indexHandler["ExampleData"] = func() { for _, v := range self.ExampleData { self.ExampleDataByID[v.ID] = v } } self.indexHandler["ExampleData"] = func() { for _, v := range self.ExampleData { self.ExampleDataByID2[v.ID2] = v } } ...
`
实际运行go实例效果如下: $ go run main.go table_gen.go tab pre load clear tab post load done <nil> KV: 8.8.8.8
load specified table: ExampleData load specified table: ExampleKV 0 &{8.8.8.8 1024 [10 20]}
The text was updated successfully, but these errors were encountered:
是bug, 稍后修正提交
Sorry, something went wrong.
7ec14e7 已提交, 可以自己取下代码编译生成一个新的tabtoy
可以了
赞美~
No branches or pull requests
在自动生成的代码 tabtoy/v3/example/golang/table_gen.go 中,连续两次给 self.indexHandler["ExampleData"] 赋值,后面的值会冲掉前面的值吧?这导致 self.ExampleDataByID 一直为空
`
// 初始化表实例
func NewTable() *Table {
`
实际运行go实例效果如下:
$ go run main.go table_gen.go
tab pre load clear
tab post load done
<nil>
KV: 8.8.8.8
load specified table: ExampleData
load specified table: ExampleKV
0 &{8.8.8.8 1024 [10 20]}
The text was updated successfully, but these errors were encountered: