From cc7c48ff6a52df248e9df1abc7c85db4063eb7af Mon Sep 17 00:00:00 2001 From: dave Date: Thu, 20 May 2004 03:36:43 +0000 Subject: [PATCH] At Ryan Davis' suggestion, honor visibility modifers if guarded by a statement modifier git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6369 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 6 ++++++ lib/rdoc/parsers/parse_rb.rb | 8 +++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 96b753bc3b..8dd2a4b461 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Thu May 20 12:34:39 2004 Dave Thomas + + * lib/rdoc/parsers/parse_rb.rb (RDoc::RubyParser::parse_visibility): + At Ryan Davis' suggestion, honor visibility modifers if guarded by a + statement modifier + Thu May 20 12:22:13 2004 Nobuyoshi Nakada * lib/mkmf.rb (have_type): do not check pointer to incomplete type, diff --git a/lib/rdoc/parsers/parse_rb.rb b/lib/rdoc/parsers/parse_rb.rb index 904475db22..ecc4455c26 100644 --- a/lib/rdoc/parsers/parse_rb.rb +++ b/lib/rdoc/parsers/parse_rb.rb @@ -2450,7 +2450,13 @@ module RDoc end skip_tkspace_comment(false) - if peek_tk.kind_of? TkNL + case peek_tk + # Ryan Davis suggested the extension to ignore modifiers, because he + # often writes + # + # protected unless $TESTING + # + when TkNL, TkUNLESS_MOD, TkIF_MOD # error("Missing argument") if singleton container.ongoing_visibility = vis else