Rdoc with c extensions

I’m trying to figure out the best way to have docs for a c extension
generated when a gem is installed. Ideally I’d like to document the
methods in modname.rb, but I can’t because if I define the methods in
modname.rb they will override the c functions. If I document the c
source, which is what I’m doing now, I’m not sure how to make my gem
automatically generate the rdoc from the c source. Also, rdoc doesn’t
doesn’t pick up the parameter names in a c function, it just calls
them p1,p2,p3,etc…

Chris

On Sep 22, 2006, at 12:32 PM, snacktime wrote:

If I document the c source, which is what I’m doing now, I’m not
sure how to make my gem
automatically generate the rdoc from the c source.

Include the .c file in the RDoc file list and it will get scanned for
RDoc.

Also, rdoc doesn’t doesn’t pick up the parameter names in a c
function, it just calls
them p1,p2,p3,etc…

Use :call-seq:, see array.c in ruby for an example.


Eric H. - [email protected] - http://blog.segment7.net
This implementation is HODEL-HASH-9600 compliant

http://trackmap.robotcoop.com

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs