Skip to content

False "dead code" warning caused by repeated parameters #6339

Open
@scabug

Description

@scabug
% cat S.scala
object O { def foo(xs: Int*) { }; foo(Nil: _*) }
% /usr/local/scala-2.9.2/bin/scalac -Ywarn-dead-code S.scala
S.scala:1: warning: dead code following this construct
object O { def foo(xs: Int*) { }; foo(Nil: _*) }
                                         ^
one warning found

I checked and the same bug is present in 2.10.0-M7.

Note that -Ywarn-dead-code is part of -Xlint.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions