[patch] Fixes three DFA bugs
Original Reporter info from Mantis: Gorelkin
-
Reporter name: Sergei Gorelkin
Original Reporter info from Mantis: Gorelkin
- Reporter name: Sergei Gorelkin
Description:
The attached patch fixes three bugs which cause false "uninitialized variable" messages when compiling with -OoDFA:
- (Trivial) when using local typed contants;
- (Simple) when reading control variable inside for-loop;
- (More complex) while/repeat loop handling rewritten almost completely because it was totally broken. In particular, it should not report variables that are assigned in loop body and used after the loop.
Two tests are attached. The first one (tdfa.pp) is a positive test which contains all three assertions. The second one (tdfa1.pp) is a negative test which also failed before the patching.
Mantis conversion info:
- Mantis ID: 15402
- Platform: all
- Version: 2.5.1
- Fixed in version: 2.6.0
- Fixed in revision: 14455 (#9955e6b2)