[clang] [clang][analyzer][NFC] Add more tests of 'StreamChecker' about 'tmpfile' (PR #70540)

Ben Shi via cfe-commits cfe-commits at lists.llvm.org
Tue Oct 31 01:56:46 PDT 2023


benshi001 wrote:

> I would like to have the new test in `stream.c` (not `stream.cpp`) because the C++ test file contains only C++ related StreamChecker tests (`tmpfile` belongs not here). And a "FIXME" could be added to the test to indicate that this is a faulty behavior (in the current case). The test and code change can be in a single PR, this is a bugfix and addition of a related test, these are done usually together.

Unfortunately I can not add `extern FILE *tmpfile(char *)` in `stream.c`, since pure C program does not support function overload. So I add it to `stream.cpp`.

https://github.com/llvm/llvm-project/pull/70540


More information about the cfe-commits mailing list