System.FilePath.joinDrive problem

Twan van Laarhoven twanvl at gmail.com
Sat Nov 3 13:56:33 EDT 2007


Hello all,

The joinDrive function currently produces paths such as "C:File" when 
calling  "C:" </> "File". This is apparently handled in a special case:

 >              | otherwise = case a of
 >                                [a1,':'] | isLetter a1 -> a ++ b
 >                                _ -> a ++ [pathSeparator] ++ b

This seems wrong, as far as I know "C:File" is not a valid path. What is 
the reason for this special case?

In particular this problem results in cabal wanting to install packages 
to "E:Haskell" on my computer (unless I pass a --prefix flag).

Twan


More information about the Libraries mailing list