on master help sign in
Canonicalize the set of loaded files for comparing watch events to.

Resolves ., .., and symlinks, though docs say symlink resolution doesn't work on Windows. For #2909

commit55853786da868305bd3b0d45ce13b09caf3e894e authorLeif Warner <abimelech@gmail.com> dateMon 25 Jan 2016, 22:44 (11 years ago) parent2518f83
1 file changed+2−2
src/Idris/REPL.hs+2−2
src/Idris/REPL.hs+2−2
@@ -690,9 +690,9 @@ reload orig inputs = do
690690
691691watch :: IState -> [FilePath] -> Idris (Maybe [FilePath])
692692watch orig inputs = do
693− let inputSet = S.fromList inputs
694− let dirs = nub $ map takeDirectory inputs
695693 resp <- runIO $ do
694+ let dirs = nub $ map takeDirectory inputs
695+ inputSet <- fmap S.fromList $ mapM canonicalizePath inputs
696696 signal <- newEmptyMVar
697697 withManager $ \mgr -> do
698698 forM_ dirs $ \dir ->