Create placeholder object and type for undeclared variables to improve error handling and reporting