-
-
Save dminuoso/065e043d05cd601008729bc3c8198239 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
parseNested :: FilePath -> Parser () | |
parseNested path = do | |
txt <- readBuf path | |
oldBase <- gets (_psCurrentPath) | |
setCurrentPath (takeDirectory path) | |
r <- lift $ runParserT principleFile' path txt | |
case r of | |
Left bundle -> liftIO $ throwIO (CpeNestedError bundle) | |
Right () -> setCurrentPath oldBase |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment