added needed coding style changes, to be accepted by carl