[m-users.] Greetings

Paul Bone paul at bone.id.au
Wed Apr 2 12:46:43 AEDT 2014

On Wed, Apr 02, 2014 at 11:09:12AM +1100, Peter Ross wrote:
> On 2 April 2014 11:16, Paul Bone <paul at bone.id.au> wrote:
> > in the long term I'd like to see better API documentation tools for Mercury.
> > Along the lines of javadoc/doxygen.  I think that the right way to do this
> > is to have the compiler generate some machine-readable information that
> > would be necessary.  Then use a separate tool to actually format that
> > machine readable information into something useful for humans (like HTML,
> > PDF whatever).  This is relevant because an IDE plugin should also be able
> > to use the same machine readable information to make things like
> > code-completion more useful.  Specifically your IDE could show you
> > completions that match the type of a parameter.
> >
> >
> I added to the compiler, a long time ago, an option which output all
> the comments located near a predicate, typeclass method, type field
> into an xml file.  A quick search of the source, should find the
> option and see if it still works.

I remember this, I agree this is the right approach.  I assume it will need
reviewing as we may need to include more information in order to create
hyperlinks and other features.  For example, the compiler may need to
disambiguate references to create the right hyperlinks.

It'd also be useful to export def-use information so that source code
browsing (like a more accurate ctags/mtags) was easier to implement.


Paul Bone

More information about the users mailing list