In moonscript, what does the *all
when reading a file mean ?
Sample script:
file = io.open('README.md', "rb")
content = file\read("*all")
If there is a *all
are there other pointers that reads half the file etc?
In moonscript, what does the *all
when reading a file mean ?
Sample script:
file = io.open('README.md', "rb")
content = file\read("*all")
If there is a *all
are there other pointers that reads half the file etc?
Copyright © 2021 Jogjafile Inc.
It means what it says: read the whole file (actually, what is left of it).
No, there is no direct way to read half the file.
You can read a given number of bytes.