Compute hash of compilation flags for change detection.
(flags: dict[str, list[str]])
| 87 | |
| 88 | |
| 89 | def compute_flags_hash(flags: dict[str, list[str]]) -> str: |
| 90 | """Compute hash of compilation flags for change detection.""" |
| 91 | # Combine all flags into a single sorted string for consistent hashing |
| 92 | all_flags = sorted(flags["defines"] + flags["compiler_flags"]) |
| 93 | flags_str = " ".join(all_flags) |
| 94 | return hashlib.sha256(flags_str.encode()).hexdigest() |
| 95 | |
| 96 | |
| 97 | def load_metadata() -> dict[str, str]: |
no outgoing calls
no test coverage detected