This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fix PR39799: missing uninitialized vars warning


> +    int b; /* { dg-message "note: 'b' was declared here" } */
> +    if (b < 40) {
> +      ptr[0] = b; /* { dg-warning "may be used uninitialized" } */
> +    }
> +    b += 1;

I'd be interested to know why the warning appears on the 
second use of the uninitialized variable and not the first.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]