Another (cleaner?) solution would be to make activeLinkers a
List<String> and activePrimaryLinker String, as a pure reflection of
<add-linker> statements.  Meanwhile linkerTypesByName remains as pure
reflection of <define-linker> statements.

Then just generate the appropriate answers via the map on the fly in
response to getActiveLinkers()/getActivePrimaryLinker().


http://gwt-code-reviews.appspot.com/47813/diff/1/2
File dev/core/src/com/google/gwt/dev/cfg/ModuleDef.java (right):

http://gwt-code-reviews.appspot.com/47813/diff/1/2#newcode138
Line 138: } else if (!activeLinkers.contains(clazz)) {
Are we quite sure?

One could argue that an add-linker on an already-defined linker should
remove it from wherever it currently is, and re-add it to the end of the
list.

http://gwt-code-reviews.appspot.com/47813/diff/1/2#newcode223
Line 223: } else if (index != -1) {
} else {
   assert index >= 0

?

http://gwt-code-reviews.appspot.com/47813

--~--~---------~--~----~------------~-------~--~----~
http://groups.google.com/group/Google-Web-Toolkit-Contributors
-~----------~----~----~----~------~----~------~--~---

Reply via email to