Fix for test miscMath3.

The problem with this test is that

void <S> loop(S s){ this.<S>loop(s);}

is not correct template method definition.

<S> void loop(S s){ this.<S>loop(s);}

is correct definition, at it parses ok.

Added additional test for the template methods.