AS of sdcc 3.2.1 #8084, ther eis a false "may be used before initialization" when before the use, there is a branch, so that in some cases the variable is initialized, and in other cases a function that does not return is called. Interestingly, the problem does not occour when the variable is initialized in all branches, and does not occour, when a function that does not return is called in all branches: It is only the mixed case that gets the warning.
P.S.: Compiling the attached test.c gives:
test.c:13: warning 84: 'auto' variable 'p' may be used before initialization
Log in to post a comment.