Spurious compiler warning ?

kenji hara k.hara.pg at gmail.com
Thu Nov 3 05:21:28 PDT 2011


2011/11/3 Nick Sabalausky <a at a.a>:
> I don't know much about the internals of DMD, but would this make any
> sense?:
>
> When unrolling code, keep track of where the unrolled parts came from. Only
> issue an unreachable code warning if *all* the unrolled versions of the
> original line X are unreachable.

First, when we use -w option, we usually want to show *all* warnings of codes.
Isn't it your expects?

Second, each unrolled loop bodies is separately analyzable by the compiler.
There is no reason to drop the detectable information, unless other
factors affect (such as performance).

I don't know why you want to reduce warnings that (probably) you expects.

Kenji Hara


More information about the Digitalmars-d mailing list