Commit efed6182 authored by Michael Hanus's avatar Michael Hanus
Browse files

Merge branch 'master' into 'master'

Ensure ACY files are present for every module

CurryDoc fails when the initial call to the frontend does not generate ACY files for all dependent modules. With this patch, CurryDoc checks for an ACY file before generating the documentation for a module. If the file is missing, it calls the frontend to generate it.

See merge request !1
parents 263c6b90 c9753cfd
......@@ -28,6 +28,7 @@
module CurryDoc where
import AbstractCurry.Files
import Directory
import Distribution
import FileGoodies
......@@ -268,6 +269,10 @@ makeDocWithComments :: DocType -> DocParams -> Bool -> String -> AnaInfo
-> String -> String -> [(SourceLine,String)] -> IO ()
makeDocWithComments HtmlDoc docparams recursive docdir anainfo modname
modcmts progcmts = do
-- ensure that the AbstractCurry file for the module exists
loadpath <- getLoadPathForModule modname
modpath <- lookupFileInPath (abstractCurryFileName modname) [""] loadpath
unless (modpath /= Nothing) $ callFrontend ACY modname
writeOutfile docparams recursive docdir modname
(generateHtmlDocs docparams anainfo modname modcmts progcmts)
translateSource2ColoredHtml docdir modname
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment