Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

suggested fix for span assignment related to forward declarations #100

Open
Labels
PR WelcomeExtra attention is needed enhancementNew feature or request
@jmkinzer

Description

Hi,

There is an issue with how CppElement.Span is assigned in the case of headers containing forward declarations. The problem is that (in at least in some situations) the span will point to the forward declaration and not the real definition. The issue I believe lies here:

bool isForwardDeclaration = (element is CppClass || element is CppEnum) && !cursor.IsDefinition;

Where cursor.IsDefinition does not always yield the result we want. I was able to get the correct behavior using this instead:

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    PR WelcomeExtra attention is needed enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /