(l *State, name string)
| 39 | } |
| 40 | |
| 41 | func ioFile(l *State, name string) *os.File { |
| 42 | l.Field(RegistryIndex, name) |
| 43 | s := l.ToUserData(-1).(*stream) |
| 44 | if s.close == nil { |
| 45 | Errorf(l, fmt.Sprintf("standard %s file is closed", name[len("_IO_"):])) |
| 46 | } |
| 47 | return s.f |
| 48 | } |
| 49 | |
| 50 | func forceOpen(l *State, name, mode string) { |
| 51 | s := newFile(l) |
no test coverage detected