diff options
author | Som Snytt <som.snytt@gmail.com> | 2016-09-15 12:58:21 -0700 |
---|---|---|
committer | Som Snytt <som.snytt@gmail.com> | 2017-03-11 23:38:08 -0800 |
commit | bd280077d04a3ac84ca48f549faaa8915d46ef2e (patch) | |
tree | a7c8b244ef84b44df201c88b4233d17bcec306d1 /test/files/neg/t944.scala | |
parent | 1b415c904bece230a706c0d19462345fc87abf67 (diff) | |
download | scala-bd280077d04a3ac84ca48f549faaa8915d46ef2e.tar.gz scala-bd280077d04a3ac84ca48f549faaa8915d46ef2e.tar.bz2 scala-bd280077d04a3ac84ca48f549faaa8915d46ef2e.zip |
SI-9158 No warn for comprehension patvars
Midstream assignments should not cause unused warnings.
Currently the encoding doesn't pass them along, but
passes the value from which they were destructured.
For for-comprehensions only, the patvar transform
tags the binds so that they are not warned if they
turn up in a valdef and are unused.
Extractors are invoked multiple times if the patvar is
used later, as noted on the ticket.
In a yield, the valdef is emitted only if the patvar
is referenced (possibly saving the extra extraction),
so there is no warning there currently.
Diffstat (limited to 'test/files/neg/t944.scala')
0 files changed, 0 insertions, 0 deletions