Issue |
89965
|
Summary |
potentially incorrect Emacs marker in headers
|
Labels |
new issue
|
Assignees |
|
Reporter |
firewave
|
According to https://llvm.org/docs/CodingStandards.html#file-headers the way to tell Emacs that a file is C++ is `-*- C++ -*-`.
But while implementing and testing support for this I ran into a few files which appears to have mistakes in that. Those markers are looking like this:
```
-*- C++ --*-
-*- C++ ---*-
-*- C++ ------*-
-*- C++ -------*-
-*- C++ --------*-
-*- C++ ---------*-
-*- C++ ----------*-
-*- C++/-*-
```
Since it is really hard to find a proper specification for this I cannot tell if these would actually be valid. But since no other files in the `/usr/include` of my distro have such markers I assume they are wrong.
Here is the list of affected files.
```
/usr/include/clang/Analysis/Analyses/LiveVariables.h
/usr/include/clang/Analysis/Analyses/ReachableCode.h
/usr/include/clang/Analysis/Analyses/ThreadSafetyLogical.h
/usr/include/clang/Tooling/AllTUsExecution.h
/usr/include/clang/Tooling/Execution.h
/usr/include/clang/Tooling/StandaloneExecution.h
/usr/include/clang/Tooling/Syntax/Mutations.h
/usr/include/llvm/Analysis/InlineAdvisor.h
/usr/include/llvm/Analysis/InlineOrder.h
/usr/include/llvm/Analysis/ReplayInlineAdvisor.h
/usr/include/llvm/BinaryFormat/DXContainer.h
/usr/include/llvm/BinaryFormat/XCOFF.h
/usr/include/llvm/MC/MCDXContainerWriter.h
/usr/include/llvm/Remarks/RemarkFormat.h
/usr/include/llvm/Remarks/Remark.h
/usr/include/llvm/Remarks/RemarkLinker.h
/usr/include/llvm/Remarks/RemarkParser.h
/usr/include/llvm/Remarks/RemarkStringTable.h
/usr/include/llvm/Transforms/Utils/MemoryOpRemark.h
```
While at it, it might also make sense to check if there are files which are completely lacking the marker.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs