scottrogowski / code2flow

Pretty good call graphs for dynamic languages
MIT License
3.98k stars 295 forks source link

Take code annotations into account #96

Open maxjeblick opened 7 months ago

maxjeblick commented 7 months ago

I noticed that for code with annotations the annotations are not taken into account when creating the dependency graph.

As an example, for

def do_stuff(config: Config, model: MyModel):
    model.apply_config(config)
    return model.eval()

do_stuff is marked as being independent of Config and MyModel, as it does not call Config and MyModel class explicitly in the body.