#3747: getDirectoryContents yields wrong results
------------------------+---------------------------------------------------
    Reporter:  Meddix   |       Owner:                             
        Type:  bug      |      Status:  new                        
    Priority:  normal   |   Component:  libraries/directory        
     Version:  6.10.4   |    Keywords:                             
          Os:  Windows  |    Testcase:  getDirectoryContents "c:"  
Architecture:  x86      |     Failure:  Incorrect result at runtime
------------------------+---------------------------------------------------
 Executing getDirectoryContents on "c:" gives the contents of the current
 directory.[[BR]]
 The following program prints always True:


 {{{

 module Main (main) where

 import System.Directory

 main :: IO ()
 main = do
   rootContents <- getDirectoryContents "c:"
   currContents <- getCurrentDirectory >>= getDirectoryContents
   putStrLn . show $ currContents == rootContents

 }}}

 Thanks

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/3747>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to