Properly handle undeclared variables.