Fixed variable space expansion bug -- replacements that did not need to be mapped were being lost.