Replaced more code with compile time generated code.