Menu

#174 Add flags to assert that any class_specification matches code

Some sunny day
open
None
5
2015-09-08
2015-09-08
No

In order to keep the configuration up to date with a changing codebase, it would be useful to ensure that a given class_specification actually matches something. While removing, moving, or renaming classes or methods, it's very easy to misconfigure the build. By adding a flag or global directive, ProGuard could check this and fail the build.

Discussion

  • Eric Lafortune

    Eric Lafortune - 2015-09-08

    ProGuard currently implements a compromise: if the configuration mentions a class name that is not present in the codebase, ProGuard prints a note. This is usually a sign that the name contains a typo or that it is not fully qualified.

    ProGuard doesn't print notes if the class name contains wildcards or if the entire template doesn't match any classes, fields, or methods. It's not uncommon (cfr. the example configurations) and it would probably add way too much noise. Some sort of statistics might be useful; I'll think about it.

    You can currently also check the output of -printseeds, although it doesn't refer back to the configuration.

     

    Last edit: Eric Lafortune 2015-09-08
  • Eric Lafortune

    Eric Lafortune - 2015-09-08
    • assigned_to: Eric Lafortune
     

Log in to post a comment.

MongoDB Logo MongoDB