Fixed a warning.
Changed setupFunctionBody to static.
Fixed type parameters for more complicated cases.