mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-19 03:54:01 +00:00
os, syscall: implement ReadAt for unix
Windows will take more work, so test is skipped there.
This commit is contained in:
@@ -22,3 +22,11 @@ func Pipe() (r *File, w *File, err error) {
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ReadAt reads up to len(b) bytes from the File starting at the given absolute offset.
|
||||
// It returns the number of bytes read and any error encountered, possibly io.EOF.
|
||||
// At end of file, Pread returns 0, io.EOF.
|
||||
// TODO: move to file_anyos once ReadAt is implemented for windows
|
||||
func (f unixFileHandle) ReadAt(b []byte, offset int64) (n int, err error) {
|
||||
return -1, ErrNotImplemented
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user