addresses #365 - static Func variable resolution

Suggested fix to issue #635 (the sample code compiles now), but I don't know if this would introduce any other regressions.