Skip to content

Commit

Permalink
Relax chk-invalid-headers checks to match SCRAM rules:
Browse files Browse the repository at this point in the history
- file in PackageA/SubpackageA can include any file from that subpackage,but only interface (public header) from other package or subpackage
- file in PackageA/SubpackageA/test can, in addition, include file from any other package's `test` directory
  • Loading branch information
iarspider committed Jul 1, 2024
1 parent 2b9aaa6 commit bbe61d0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion chk-invalid-headers.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,9 @@ def main():
continue
for src in usedby[inc].split(" "):
sitems = src.split("/")
if (items[0] == sitems[0]) and (items[1] == sitems[1]) and (items[2] == sitems[2]):
if (items[0] == sitems[0]) and (items[1] == sitems[1]):
continue
if (items[2] == sitems[2]) and (items[2] == "test"):
continue
if hasInclude(inc, src, includes):
if src not in errs:
Expand Down

0 comments on commit bbe61d0

Please sign in to comment.