我想从 gcc/g++ 编译错误消息中删除文件名。
当我运行gcc myfolder/temp.c
时,结果是:
myfolder/temp.c:5:1: error: unknown type name ‘voi’
myfolder/temp.c:87:6: error: conflicting types for ‘max’
myfolder/temp.c:5:5: note: previous declaration of ‘max’ was here
但我想要这个:
5:1: error: unknown type name ‘voi’
87:6: error: conflicting types for ‘max’
5:5: note: previous declaration of ‘max’ was here
有 gcc 标志吗?