Open ndmitchell opened 8 years ago
RR = Relative Read
I made a mistake in the suite, the upper case variants mean fsatrace was unable to determine the full absolute path for the access. Should be fixed now.
As for the os
thing, yes, it also left me wondering why it reports "mingw32". I was aware of isWindows
, just decided to go with that to avoid another dependency just for the tests.
So is the upper-case R
relative thing something Shake should handle? And what is it relative to - the current directory at the time it was captured? Under which circumstances is it generated?
Yep, depending on an extra dependency is always annoying.
I don't think Shake should handle it. It's something that should disappear as soon as everything is working properly. It's there mainly to help figuring out if some tool is using an unimplemented feature.
It's mainly related to the usage of xxxat() function variants, like:
https://github.com/jacereda/fsatrace/blob/master/src/unix/fsatraceso.c#L267
I've never used them and haven't seen them used in any of the major compilers, so I didn't bother to implement them. Those could be assert
s, but I decided to report them anyways.
They can also be reported on Windows if obtaining the path associated with a handle fails for some reason. I haven't seen it so far.
The "at" variants of functions are wonderful system calls, and it seems well worth supporting them! (And they aren't that hard. Here is how I do it in bigbro:
https://github.com/droundy/bigbro/blob/master/linux-proc.h#L3
I had a look through the test suite. A couple of questions:
RR FilePath
f ('R':'|':xs) = Just $ R xs
. It would be ideal if you guaranteed only to produce one form.os == "mingw32"
- this always scares me that Haskell programs use a value called OS, matching against a string which is clearly not an OS, and is a toolkit not even installed probably at the wrong bit size. I prefer theisWindows
from the extra library - but what you are doing is the Haskell expected pattern, I just don't like it, so go with whatever you prefer.