Fortran-FOSS-Programmers / ford

Automatically generates FORtran Documentation from comments within the code.
https://forddocs.readthedocs.io
GNU General Public License v3.0
405 stars 131 forks source link

Refactor `_find_chain_item` #589

Open ZedThree opened 10 months ago

ZedThree commented 10 months ago

get_label_item constructs a dict from all the labels that could potentially be in the call chain and then looks up the label. This simplifies the look-up but we could probably refactor it to bail early once we've found it instead. Need to profile, but I feel like we can get a little bit of a speed up here, especially for larger projects.

We could also get rid of strip_type by adding a property to FortranVariable to return it, and use that in FortranVariable.full_type too.