From 7bfa1c3dc911f5c36ac64d6b4f410e4f12a7d4ca Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Sun, 17 Dec 2023 22:37:15 +0900 Subject: [PATCH] Revert "[DOC] Make undocumented socket constans nodoc" This reverts commit cbda94edd80b0f664eda927f9ce9405b2074633a, because `:nodoc:` does not work for constants. In the case of `rb_define_const`, RDoc parses the preceeding comment as in `"/* definition: comment */"` form. --- ext/socket/mkconstants.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/socket/mkconstants.rb b/ext/socket/mkconstants.rb index 557a3df611..4020bf02e6 100644 --- a/ext/socket/mkconstants.rb +++ b/ext/socket/mkconstants.rb @@ -38,7 +38,7 @@ opt.parse! h = {} -COMMENTS = Hash.new(":nodoc:") +COMMENTS = Hash.new { |h, name| h[name] = name } DATA.each_line {|s| name, default_value, comment = s.chomp.split(/\s+/, 3)