PSyclone
PSyclone copied to clipboard
Improve kwargs documentation
We had the same problem on the PSyIR Nodes and Symbols kwargs, and the Transformations options which are passed to the super class. I don't like having them duplicated as we never check them when they are updated, or when new arguments added to the subclasses, and would be quite hard to review.
Adding a link to the super() is a good and simple solution (which some IDEs, static type tools may be able to follow).
There is a more complex solution of programmatically modifying the __doc__
to include the BASE.__doc__
or even spit __doc__
to separate the kwargs so that they can be included in the subclass docsting, but this may be over-engineering it, and probably not for this PR.
Originally posted by @sergisiso in https://github.com/stfc/PSyclone/pull/2692#discussion_r1744024669