Fix for trema/trema#292 

 Fix to eliminate const cast related warnings.  trema/trema#292