add a failing test to use static functions in template inner classes
refactor to use lookupInnerClass() instead of forEachInnerClass()
fix error messages