Stricter error code checking.

This commit is contained in:
Sergio Benitez 2016-04-06 03:32:35 -07:00
parent dc5ef6a421
commit e00b1a535a
1 changed files with 2 additions and 2 deletions

View File

@ -37,8 +37,8 @@ fn get_error_params(ecx: &mut ExtCtxt, meta_item: &MetaItem) -> Params {
} }
}; };
if numeric_code < 100 || numeric_code > 599 { if numeric_code < 400 || numeric_code > 599 {
ecx.span_err(c.v_span, "Error codes must be >= 100 and <= 599."); ecx.span_err(c.v_span, "Error codes must be >= 400 and <= 599.");
} }
c.clone().map(|_| { numeric_code }) c.clone().map(|_| { numeric_code })