[pygccxml-development] More comments on matcher code...
Brought to you by:
mbaas,
roman_yakovenko
|
From: Allen B. <al...@vr...> - 2006-07-26 19:10:28
|
I've just been running through the matcher code to try to track down an error in my bindings and I have a couple of questions. Note these questions have to do with why certain coding decisions were made so hopefully you are open to some friendly code critiquing. :) - Why is the file declarations/filters.py not called declarations/matchers.py? This file defines the matcher_base_t class and all matchers that derive from that class. It is the place in the code where all matchers are defined and every class in that file is called *_matcher_* but yet it is called filters.py. Seems confusing to me. - declarations/matcher.py This file seems to just define 3 static methods for calling find with matchers and the 2 associated exceptions that can be thrown. Why define the class "matcher" when just having these methods and exception types in the file matcher.py already creates the namespace it seems like you want them to be within? For that matter, why does this file even need to exist? The only place that calls these methods is scopedef_t so the methods could either move over to there or could move into the same file where all the matchers are defined (filters.py right now, but matchers.py may make more sense as described above). Anyway, those are my comments. Please let me know if this type of critique is helpful, if it is I will write a message when I see this type of thing in the code. -Allen |