Fix a bug where file-specific annotation hooks are not cleaned after compiling a source file