Skip to content

Incorrect member function link and description on hiding member functions in inherited class. #840

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
redboltz opened this issue Jan 31, 2025 · 3 comments

Comments

@redboltz
Copy link

Behavior

The member function documentation for base::func and derived::func is generated correctly.
However, the class documentation for derived contains an incorrect member function link and description.

The link incorrectly points to base::func, but it should reference derived::func.
Additionally, the description should be derived func, but the generated output is base func derived func.

Reproduction Code

/**
 * @brief base
 */
class base {
public:
    /**
     * @brief base func
     */
    void func();
};

/**
 * @brief derived
 */
class derived : public base {
public:
    /**
     * @brief derived func
     *
     * @return value
     */
    int func();
};

Environment

Mr.Docs version 0.0.3 54e75a7

@alandefreitas
Copy link
Collaborator

This is what I currently get from develop:

Reference

Global namespace

Types

NameDescription
base base
derived derived

base

base

Synopsis

Declared in <copy-dependencies.cpp>

class base;

Member Functions

NameDescription
func base func

base::func

base func

Synopsis

Declared in <copy-dependencies.cpp>

void
func();

derived

derived

Synopsis

Declared in <copy-dependencies.cpp>

class derived
    : public base;

Member Functions

NameDescription
func derived func

derived::func

derived func

Synopsis

Declared in <copy-dependencies.cpp>

int
func();

Return Value

value

Created with MrDocs

@alandefreitas
Copy link
Collaborator

alandefreitas commented Jan 31, 2025

I think the problem is probably solved by aea4acf, which explicitly implements the strategies defined in inherit-base-members

alandefreitas added a commit to alandefreitas/mrdocs that referenced this issue Jan 31, 2025
@redboltz
Copy link
Author

redboltz commented Feb 1, 2025

Thank you. I've confirmed it.

From now on, I'll test the develop branch when reporting new issues. I just noticed that the develop binary is deployed daily at
https://www.mrdocs.com/docs/mrdocs/develop/install.html

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

No branches or pull requests

2 participants