Logo
Explore Help
Register Sign In
rust-lang/rust
1
0
Fork 0
You've already forked rust
Code Issues Pull Requests Actions 2 Packages Projects Releases Wiki Activity
Files
eb9d0e89d19477e89fadf55c0de8376b5ba6dd5c
rust/src/test/compile-fail/do-while-constraints.rs

11 lines
249 B
Rust
Raw Normal View History

rustc: Lower case error messages
2012-03-05 16:27:27 -08:00
// error-pattern:unsatisfied precondition constraint (for example, init(y
Tests for while loops that may invalidate constraints Wrote some small test cases that use while loops and moves, to make sure the poststate for the loop body gets propagated into the new prestate and deinitialization gets reflected. Along with that, rewrite the code for intersecting states. I still find it dodgy, but I guess I'll continue trying to add more tests. Also, I'll probably feel better about it once I start formalizing the algorithm.
2011-06-27 18:12:37 -07:00
fn main() {
Reformat for new syntax
2011-07-27 14:19:39 +02:00
let y: int = 42;
let x: int;
do {
Register new snapshots, purge log_err and log_full in favour of log(...).
2011-12-22 17:53:53 -08:00
log(debug, y);
Reformat for new syntax
2011-07-27 14:19:39 +02:00
do { do { do { x <- y; } while true } while true } while true
} while true
Reformat This changes the indexing syntax from .() to [], the vector syntax from ~[] to [] and the extension syntax from #fmt() to #fmt[]
2011-08-19 15:16:48 -07:00
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.6 Page: 316ms Template: 3ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API