Most of you might already know what I'm talking about: It parses the source code for special comments (@param, @version, @return etc.) and uses them to generate a basic source documentation e.g. in HTML. A parsable source could look like this:
Code: Select all
;**
; Calculates square number and creates a string of it.
; @param Number The number to calculate with.
; @return Square number as string.
; @version: 1.0, 2012-11-10 09:08:07
;*
Procedure.s SquareStr(Number.i)
ProcedureReturn Str(Number * Number)
EndProcedure
Debug SquareStr(2)
Now the question: Does such a tool exist for PureBasic? Or is there anything more general which I could configure to parse PB code?Procedures:
- SquareStr()
++ Information:
--- Location: "C:\Test.pb", Line 7-9
--- Body Size: 37 Characters
--- Version: 1.0
--- Date: 10 Nov., 2012
++ Purpose: Calculates square number and creates a string of it.
++ Parameters:
--- Number (integer) - The number to calculate with.
[...]
(P.S. If anyone comes up with "just use language XYZ which is way better than PB and already has all you need": Well thanks for the suggestion, but I want to stay with PureBasic that's why I'm posting here...
