Skip to content
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

Replace type by parameter name (C++) #359

Open
alve89 opened this issue Jul 26, 2021 · 1 comment
Open

Replace type by parameter name (C++) #359

alve89 opened this issue Jul 26, 2021 · 1 comment

Comments

@alve89
Copy link

alve89 commented Jul 26, 2021

I'm using your package for documenting my C++ code. For documentation I'm using Doxygen, which expects as second part of the @param line the variable name. Your package automatically generates the variable type. Is there

  1. a way to change that quick-and-dirty and, much more important,

  2. a chance you either change that in your package or - rather - add an option in the package settings, e. g. which part of the function declaration should automatically be added?

     This is how it currently is (auto-generated comment)
     /**
      * [getTemperature description]
      * @param  byte [description]
      * @return      [description]
      */
     float getTemperature(uint8_t);
    
    
     This is how it could be with set the second part to 'variable name' 
     /**
      * [getTemperature description]
      * @param  sensorId [description]
      * @return  [description]
      */
     float getTemperature(uint8_t sensorId);
    
    
     This would be the perfect solution, but I don't know if your package can handle this
     /**
      * [getTemperature description]
      * @param  sensorId    [description]
      * @return  [description]
      */
     float getTemperature(uint8_t); // parameter name is not necessary in the declaration => get the parameter name from the cpp file, if no name is given in the declaration
    
@MoritzKn
Copy link
Collaborator

Yes, this makes sense. I don't see the point of having the types for C++ comments at all. I think for some languages this is already the case (e.g. TypeScript IIRC). Should be an easy enough change. Feel free to have a look and submit a PR.

But keep in mind this package is pretty much unmaintained: All I am doing at the moment is merging PRs. Be prepared to dive into the code on your own. It's been so long, even if I had the time, I probably couldn't help you much anyways.

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

No branches or pull requests

2 participants