StringOpen opens the string library. Usually passed to Require.
(l *State)
| 235 | |
| 236 | // StringOpen opens the string library. Usually passed to Require. |
| 237 | func StringOpen(l *State) int { |
| 238 | NewLibrary(l, stringLibrary) |
| 239 | l.CreateTable(0, 1) |
| 240 | l.PushString("") |
| 241 | l.PushValue(-2) |
| 242 | l.SetMetaTable(-2) |
| 243 | l.Pop(1) |
| 244 | l.PushValue(-2) |
| 245 | l.SetField(-2, "__index") |
| 246 | l.Pop(1) |
| 247 | return 1 |
| 248 | } |
nothing calls this directly
no test coverage detected