mcm icon indicating copy to clipboard operation
mcm copied to clipboard

luacat: file references

Open zombiezen opened this issue 9 years ago • 0 comments

I want some mechanism to be able to pass files around into mcm.resource. The idea is that if you just want to include a binary file, it can be much more efficient to have the C++ side of it read it (or mmap it) into a Cap'n Proto segment.

However, luacat programs should be able to read the data into memory if need be (to allow templating etc.). So perhaps a fileref:read() call, along with some flag in luacat to provide a limit on how large of a file that can be read in in this manner.

zombiezen avatar Dec 18 '16 20:12 zombiezen