On Wed, Apr 27, 2011 at 3:20 PM, <jbrosenb...@google.com> wrote: > If I understand correctly, part of staticification is that all > call-sites to myVar.foo(x) will be replaced by $foo(myVar, x), and thus > foo(x) will be unused, and thus pruned. So, the delegation issues goes > away, no?
Yes, as long as all call sites can be devirtualized, the instance method goes away. On Wed, Apr 27, 2011 at 3:51 PM, <jbrosenb...@google.com> wrote: > It looks like there might be some logic in > ControlFlowAnalyzer.RescueVisitor.Rescue, which can also be removed if > inlining staticImpl's is not an issue. Whoops! Yes, I need to remove that, my bad. On Wed, Apr 27, 2011 at 4:34 PM, <jbrosenb...@google.com> wrote: > I see now (looking at MakeCallsStatic.RewriteCallSites) that not all > call sites get replaced, there are a few edge cases, relating to split > points, etc., where the call sites are not replaced....But I'm guessing > it won't be a large number of cases. Yes, there will be cases where both the instance and static method make it into the final output. In some of those cases, JsInliner will actually do the inlining. In others, my theory is that not inlining them won't have a negative effect on code size. -- http://groups.google.com/group/Google-Web-Toolkit-Contributors