-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Extracting comments from C code -- -- Language C Comments is a Haskell library for extracting comments from -- C code. It will parse both single- and multi-line comments, and -- correctly handles split lines. @package language-c-comments @version 0.2 module Language.C.Comments -- | Comment positions use Language.C.Data.Position for compatibility with -- Language.C. data Comment -- | Comments can be either single- or multi-line style. data CommentFormat SingleLine :: CommentFormat MultiLine :: CommentFormat -- | The position of the comment within the source file. commentPosition :: Comment -> Position -- | The text of a comment (including the comment marks). commentText :: Comment -> String -- | The text of a comment, but with the comment marks removed. commentTextWithoutMarks :: Comment -> String -- | The format of a comment (single- or multi-line). commentFormat :: Comment -> CommentFormat -- | Extract comments from a C file. comments :: FilePath -> IO [Comment] -- | Extract comments from a string. A comment's position contains a -- filename; this method uses the empty string in its place. commentsFromString :: String -> [Comment] instance Eq Comment instance Show Comment instance Ord Comment