mozilla/rust — pull request #14444 by huonw (2014-05-26 12:47:52+00:00)
Title: Change `for` desugaring & make refutable pattern errors more precise

Change `for` desugaring & make refutable pattern errors more precise

This changes for to desugar to the `let`-based pattern match as described in #14390, and adjusts the compiler to use this information for error messages that even mention that it's in a `for` loop.

Also, it makes the compiler record the exact positions of refutable parts of a pattern, to point to exactly them in error messages.