Answer prose round 1: mark the reading-cost item decision, split the rise rule's reasons, and say the trend counts since the last reset

This commit is contained in:
2026-10-08 16:46:20 +02:00
parent 5e5eea21e5
commit 35907caefa
5 changed files with 12 additions and 12 deletions
+2 -2
View File
@@ -32,7 +32,7 @@ def shell_reads(command: str, cwd: str, home: str) -> Reads:
def shell_lines(command: str) -> typing.Iterator[list[str]]:
"""Each line's tokens, skipping a heredoc's body, which feeds a program rather than naming files."""
"""Each line's tokens, skipping a heredoc's body, which feeds a program."""
ends = None
for line in command.splitlines():
if ends is not None:
@@ -56,7 +56,7 @@ def segments(tokens: list[str]) -> list[list[str]]:
if target:
target = False
elif all(char in "();<>|&" for char in token):
# A redirect's target is written or fed, not read by the command.
# A redirect's target is not an operand, so it does not count as a read.
target = "<" in token or ">" in token
found.append([])
else: