Skip to content

block comment delimiters are in the documentation #600

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
mariusz-kowalski opened this issue Feb 21, 2018 · 1 comment · Fixed by #622
Closed

block comment delimiters are in the documentation #600

mariusz-kowalski opened this issue Feb 21, 2018 · 1 comment · Fixed by #622

Comments

@mariusz-kowalski
Copy link

If I use block comment, =begin and =end delimiters are part of the documentation, and they are interpreted as headings h1:

example_class.rb

=begin
This is documentation
=end
class ExampleClass; end

This

rdoc example_class.rb

will generate the documentation with heading (h1) "begin" at the beginning and heading "end" at the end.

<h1 id="class-ExampleClass" class="class">
  class ExampleClass
</h1>
<section class="description">
  <h1 id="class-ExampleClass-label-begin">
    begin
    <span><a href="#class-ExampleClass-label-begin"></a> <a href="#top"></a></span>
  </h1>

  <p>This is documentation</p>

  <h1 id="class-ExampleClass-label-end">
    end
    <span><a href="#class-ExampleClass-label-end"></a> <a href="#top"></a></span>
  </h1>
</section>

=begin and =end are just comment delimiters and should not be a part of the documentation.

I'm using version 6.0.1 (ruby 2.5)

@topofocus
Copy link

Same feature here.
Is there a known walk around?

Worst: »begin» and »end» are included in /rdoc/table_of_contents.html#classes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants