added function to mangle class member names; added utility function to replace dollar signs