method
do_attrs
v1_9_3_125 -
Show latest stable
- Class:
RDoc::Parser::C
do_attrs()public
Scans #content for rb_attr and rb_define_attr
# File lib/rdoc/parser/c.rb, line 196
def do_attrs
@content.scan(/rb_attr\s*\(
\s*(\w+),
\s*([\w"()]+),
\s*([01]),
\s*([01]),
\s*\w+\);/m) do |var_name, attr_name, read, write|
handle_attr var_name, attr_name, read, write
end
@content.scan(%rb_define_attr\(
\s*([\w\.]+),
\s*"([^"]+)",
\s*(\d+),
\s*(\d+)\s*\);
%m) do |var_name, attr_name, read, write|
handle_attr var_name, attr_name, read, write
end
end Related methods
- Instance methods
- do_aliases
- do_attrs
- do_classes
- do_constants
- do_includes
- do_methods
- find_alias_comment
- find_attr_comment
- find_body
- find_class
- find_class_comment
- find_const_comment
- find_modifiers
- find_override_comment
- handle_attr
- handle_class_module
- handle_constants
- handle_ifdefs_in
- handle_method
- handle_singleton
- handle_tab_width
- look_for_directives_in
- rb_scan_args
- remove_commented_out_lines
- remove_private_comments
- scan
- Class methods
- new
- reset