Removed dead code. Removed 'require' for code that is being parsed. Added state for defines