move ExtRefWrite definition
eliminate liftWriteRef'
refactoring
rename
rename
simplification
simplification
simplification
simplification
simplification
simplification
refactoring