Skip to content

Nested \cond sections are not started #8802

Closed
@tomchy

Description

@tomchy

Description
Based on my observations, the \cond command is not handled if it is present in a different \cond section, that is not satisfied. What's more surprising, the corresponding \endcond is handled, which leads to an unintended termination of the outer section.

I am still far from full understanding of the parser logic, but I cannot find regex that will call startCondSection if the SkipCond is activated in src/pre.l.

Expected behavior
The inner \cond section would be either added to the stack (state->condStack) or the \endcond command will be skipped.

To Reproduce

  1. Apply the patch from Add a warning message for an unbalanced \endcond #8800
  2. Create a file with nested \cond commands
  3. Do not satisfy expressions, passed to the \cond commands
  4. Run doxygen on the file. The new warning should be appear.

Version
Found in v1.8.17 (Ubuntu 18.04). Unfortunately my input files are not compatible with 1.9.x. The issue should be fairly simple to check in newer versions.

Additional context
If needed, I may try to install and reproduce the issue using other versions of doxygen, but first I would like to confirm that this case should be supported bu the tool.

Attachments
Sample project, reproducing the issue: doxygen_test.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions