We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 49d2825 commit 16eaecbCopy full SHA for 16eaecb
src/librustc/session/config.rs
@@ -1136,6 +1136,10 @@ pub fn build_session_options(matches: &getopts::Matches) -> Options {
1136
(Some("3"), _) => OptLevel::Aggressive,
1137
(Some("s"), true) => OptLevel::Size,
1138
(Some("z"), true) => OptLevel::SizeMin,
1139
+ (Some("s"), false) | (Some("z"), false) => {
1140
+ early_error(error_format, &format!("the optimizations s or z are only \
1141
+ accepted on the nightly compiler"));
1142
+ },
1143
(Some(arg), _) => {
1144
early_error(error_format, &format!("optimization level needs to be \
1145
between 0-3 (instead was `{}`)",
0 commit comments