<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/src/test/compile-fail/struct-no-fields-2.rs, branch 0.11.0</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=0.11.0</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=0.11.0'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2014-06-23T22:39:29+00:00</updated>
<entry>
<title>libsyntax: Disallow struct literals after `if`, `while`, `match`, and</title>
<updated>2014-06-23T22:39:29+00:00</updated>
<author>
<name>Patrick Walton</name>
<email>pcwalton@mimiga.net</email>
</author>
<published>2014-06-14T02:09:12+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=654d6444feafaa7bae17057d8b98823c7556ea14'/>
<id>urn:sha1:654d6444feafaa7bae17057d8b98823c7556ea14</id>
<content type='text'>
`for...in`.

Closes #14803.

If you used a structure literal after one of these keywords, surround it
in parentheses.

[breaking-change]
</content>
</entry>
<entry>
<title>Fixed error starting with uppercase</title>
<updated>2014-02-08T19:59:38+00:00</updated>
<author>
<name>mr.Shu</name>
<email>mr@shu.io</email>
</author>
<published>2014-02-06T09:38:08+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=ee3fa68fed13e7b8cde523e4bc73b9a07d082212'/>
<id>urn:sha1:ee3fa68fed13e7b8cde523e4bc73b9a07d082212</id>
<content type='text'>
Error messages cleaned in librustc/middle

Error messages cleaned in libsyntax

Error messages cleaned in libsyntax more agressively

Error messages cleaned in librustc more aggressively

Fixed affected tests

Fixed other failing tests

Last failing tests fixed
</content>
</entry>
<entry>
<title>Make cfail test error messages more precise</title>
<updated>2014-02-05T02:05:13+00:00</updated>
<author>
<name>Alex Crichton</name>
<email>alex@alexcrichton.com</email>
</author>
<published>2014-02-03T18:25:12+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=03c28b4ac56dd3688a8d324bb2e7683a351e656b'/>
<id>urn:sha1:03c28b4ac56dd3688a8d324bb2e7683a351e656b</id>
<content type='text'>
Closes #3192
</content>
</entry>
<entry>
<title>Add parse-error recovery for erroneous `struct_id { }` form.</title>
<updated>2013-08-09T16:32:46+00:00</updated>
<author>
<name>Felix S. Klock II</name>
<email>pnkfelix@pnkfx.org</email>
</author>
<published>2013-08-05T20:18:29+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=eee044734c55bcdc540e334d6edc8cb7d7a040d7'/>
<id>urn:sha1:eee044734c55bcdc540e334d6edc8cb7d7a040d7</id>
<content type='text'>
There are 4 different new tests, to check some different scenarios for
what the parse context is at the time of recovery, becasue our
compile-fail infrastructure does not appear to handle verifying
error-recovery situations.

Differentiate between unit-like struct definition item and unit-like
struct construction in the error message.

----

More generally, outlines a more generic strategy for parse error
recovery: By committing to an expression/statement at set points in
the parser, we can then do some look-ahead to catch common mistakes
and skip over them.

One detail about this strategy is that you want to avoid emitting the
"helpful" message unless the input is reasonably close to the case of
interest.  (E.g. do not warn about a potential unit struct for an
input of the form `let hmm = do foo { } { };`)

To accomplish this, I added (partial) last_token tracking; used for
`commit_stmt` support.

The check_for_erroneous_unit_struct_expecting fn returns bool to
signal whether it "made progress"; currently unused; this is meant for
use to compose several such recovery checks together in a loop.
</content>
</entry>
</feed>
