2013-02-01 21:43:17 -06:00
|
|
|
pub fn main() {
|
2013-02-26 12:58:46 -06:00
|
|
|
let x = [1];
|
2012-12-08 14:22:43 -06:00
|
|
|
match x {
|
2013-02-26 12:58:46 -06:00
|
|
|
[_, _, _, _, _, .._] => ::core::util::unreachable(),
|
|
|
|
[.._, _, _, _, _] => ::core::util::unreachable(),
|
|
|
|
[_, .._, _, _] => ::core::util::unreachable(),
|
|
|
|
[_, _] => ::core::util::unreachable(),
|
|
|
|
[a] => {
|
2013-03-06 15:58:02 -06:00
|
|
|
fail_unless!(a == 1);
|
2012-12-08 14:22:43 -06:00
|
|
|
}
|
2013-02-26 12:58:46 -06:00
|
|
|
[] => ::core::util::unreachable()
|
2012-12-08 14:22:43 -06:00
|
|
|
}
|
|
|
|
}
|