[llvm] [utils][filecheck-lint]: speedup filecheck_lint (PR #94191)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 5 01:51:52 PDT 2024
================
@@ -49,27 +49,15 @@ def test_find_potential_directives_comment_prefix(self):
results = list(fcl.find_potential_directives(content))
assert len(results) == 3
pos, match = results[0]
- assert (
- pos.line == 1
- and pos.start_column == len("junk; ") + 1
- and pos.end_column == len(lines[0]) - 1
- )
+ assert pos.as_str() == "1:7-11"
----------------
klensy wrote:
This looks like copypaste and not maintainable - change in input lines only will break tests without fixes here too.
Maybe add comment like:
```
junk; CHCK1:
| |
| column 11
column 7
```
https://github.com/llvm/llvm-project/pull/94191
More information about the llvm-commits
mailing list