Branch: Tag:

2010-08-29

2010-08-29 13:10:05 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added some Autodoc mk II markup.

Rev: lib/modules/Tools.pmod/AutoDoc.pmod/module.pmod:1.11

72:    return s;   }    + //! Class used to keep track of where in the source a piece of + //! documentation originated.   class SourcePosition { -  +  //!    string filename; -  +  +  //! Range of lines.    int firstline;    int lastline;    -  +  //!    protected void create(string filename, int firstline,    int|void lastline)    {
93:    this_program::lastline = lastline;    }    +  //! @returns +  //! Returns a copy of the current object.    SourcePosition copy() {    return SourcePosition(filename, firstline, lastline);    }
108:    return res + ")";    }    +  //! @returns +  //! Returns a string with an XML-fragment describing the source position.    string xml() {    mapping(string:string) m = ([]);    m["file"] = filename || "?";
117:    }   }    - class AutoDocError { -  SourcePosition position; -  string part; // which part of the autodoc system... -  string message; -  protected void create(SourcePosition _position, string _part, string _message) { -  position = _position; -  part = _part; -  message = _message; -  } + //! Base class for errors generated by the autodoc extraction system. + class AutoDocError ( +  //! +  SourcePosition position, +  +  //! Which part of the autodoc system. +  string part, +  +  //! Error message. +  string message +  ) {    string _sprintf(int t) {    return t=='O' && sprintf("%O(%O, %O, %O)", this_program,    position, part, message);    }   }