On Tuesday, 28 May 2013 at 17:46:36 UTC, Jonathan M Davis wrote:
(and I honestly don't know what
you'd be trying to do with it where it would make any sense for to operate on anything other than an actual file).

That's easy! Suppose you have a nice library that's practically unchangeable:

SomethingHard readComplicatedFileFormat(File f);

and you'd like to embed the data in the exe. If it took string, that'd be easy:

auto t = readComplicatedFileFormat(import("my.file"));

but since it only takes File, you need some kind of adapter.

Reply via email to