Cut down on void * casts within jit

By using templates.  Should have no actual functionality impact.

-[Unknown]