ITADN

[v2.0 audit][L13] IdentifierUtils.Counted uses fresh HashSet per GenerateCode() call

#1056Openchristianhelle 创建于 2026-04-18
bugpriority:p2audit:v2.0
C
christianhellecommented
**Severity:** Low | **Component:** Refitter.Core | **v2.0 audit (since v1.7.3)** The `HashSet` for de-dup is local to one call to `GenerateCode()`. If `RefitGenerator` invokes the interface generator more than once, the set is fresh each time. Currently fine for single-interface case, but duplicate-name detection no longer cooperates with `OperationNameGenerator.CheckForDuplicateOperationIds` if call ordering changes. ### Code - `src/Refitter.Core/RefitInterfaceGenerator.cs:50, 64-65` ### Fix Document the invariant or move the set onto the generator instance.
0 条评论