2012-12-13 13:05:22 -08:00
|
|
|
// xfail-fast
|
|
|
|
|
2012-12-10 17:32:48 -08:00
|
|
|
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
|
|
|
|
// file at the top-level directory of this distribution and at
|
|
|
|
// http://rust-lang.org/COPYRIGHT.
|
|
|
|
//
|
|
|
|
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
|
|
|
|
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
|
|
|
|
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
|
|
|
|
// option. This file may not be copied, modified, or distributed
|
|
|
|
// except according to those terms.
|
|
|
|
|
2013-05-20 17:07:24 -07:00
|
|
|
extern mod extra;
|
2012-11-24 12:49:31 -08:00
|
|
|
|
2013-10-02 20:00:54 -07:00
|
|
|
use extra::getopts::{optopt, getopts};
|
2012-11-24 12:49:31 -08:00
|
|
|
|
2013-02-01 19:43:17 -08:00
|
|
|
pub fn main() {
|
2012-11-24 12:49:31 -08:00
|
|
|
let args = ~[];
|
2013-08-17 08:37:42 -07:00
|
|
|
let opts = ~[optopt("b")];
|
2012-11-24 12:49:31 -08:00
|
|
|
|
|
|
|
match getopts(args, opts) {
|
2013-05-24 19:35:29 -07:00
|
|
|
Ok(ref m) =>
|
2013-09-18 03:42:23 +02:00
|
|
|
assert!(!m.opt_present("b")),
|
2013-10-21 13:08:31 -07:00
|
|
|
Err(ref f) => fail!("{:?}", (*f).clone().to_err_msg())
|
2012-11-24 12:49:31 -08:00
|
|
|
};
|
|
|
|
|
2012-12-05 16:51:32 -08:00
|
|
|
}
|