gircore / gir.core

A C# binding generator for GObject based libraries providing a C# friendly API surface
https://gircore.github.io/
MIT License
307 stars 28 forks source link

Idea: Analyzer to verify api versions #1057

Open badcel opened 4 months ago

badcel commented 4 months ago

Any GObject API could have an attribute since when it was introduced.

There could be an analyzer project which checks another attribute in the user code that defines per GirCore assembly which api version is allowed to be used.

If a newer api call is found a warning is raised.

This could benefit projects which depend on an older version of for example GTK and can't use newly introduced API. In this way they can use the newest GirCore version and be sure no exception is raised during runtime.

This could probably be a project independent of GirCore.