[clang] [clang][analyzer] Improve modeling of `fileno` in the StreamChecker (PR #76207)
Ben Shi via cfe-commits
cfe-commits at lists.llvm.org
Thu Dec 21 22:54:22 PST 2023
benshi001 wrote:
`fileno` and `ftell` are quite similar,
1. both of them return `0` on success, and `-1` on failure.
2. both of them set `errno` on failure.
The differences are
1. `fileno` returns `int` type but `ftell` returns `long` type.
2. `ftell` will not affect the value of `error` on success, but this is not mentioned for `fileno`.
https://github.com/llvm/llvm-project/pull/76207
More information about the cfe-commits
mailing list