Partial evaluation is ordinarily intended to be used to increase program efficiency. This paper shows how partial evaluation can be used in place of a preprocessor phase and of source-code templates (e.g. C++ templates or Ada generics). In this way it can be used to support portability features provided by a preprocessor, and the reusability provided by code templates, but with higher maintainability due to the simpler syntax required. The important mechanisms needed are: annotating variables and functions with an evaluation time, treating declarations as translation-time "executable" statements, treating user-defined types as translation-time variables, giving programmers control over the scope of symbols, and providing translation-time name binding. The effects of these changes on the size and complexity of a compiler are estimated. A translator for a language called "Safer_C" which supports these techniques has been implemented. Important existing C software is analyzed to evaluate the applicability of these techniques in replacing the preprocessor.