3

The following code snipped:

# ansi console color constants
COLOR_BLACK = 0
COLOR_RED = 1
COLOR_GREEN = 2
COLOR_YELLOW = 3
COLOR_BLUE = 4
COLOR_MAGENTA = 5
COLOR_CYAN = 6
COLOR_WHITE = 7

# functional color aliases
COLOR_WARN = COLOR_YELLOW
COLOR_ALERT = COLOR_RED
COLOR_CONFIRM = COLOR_GREEN
COLOR_NOTE = COLOR_BLUE

gets reported as 10 undocumented constants. Is there a way to "comment constants by groups" in RDoc? Documenting each constant separately would be slightly idiotic, and I don't want to omit them from doc.

sawa
  • 165,429
  • 45
  • 277
  • 381
rhavin
  • 1,512
  • 1
  • 12
  • 33
  • is your problem the result of rdoc? or is html doc rendered wrongly? – Roger Nov 18 '12 at 13:05
  • it an "rdoc feature missing problem" ^^… i'd like to have the constants in the doc, but dont want to get them counted as undocumented and also dont want to dublicate them into commentary blocks; i'm looking for a pricipial solution, not a workaround – rhavin Nov 19 '12 at 03:04

1 Answers1

0

I got the following answer per mail from a rdoc-developer, after i suggested implementing a :constlist: directive, that would get COLOR_BLACK = 0 simply documented as COLOR_BLACK(0):

I'll see what I can do, but I may not be able to add it to RDoc 4.0 as my time is limited.

I think I can make this work by putting the constants in a section (internally) using a separate directive that also marks them as documented for the purposes of the coverage report.

rhavin
  • 1,512
  • 1
  • 12
  • 33