Rocket/codegen/tests/compile-fail/bad-error-fn.rs
Sergio Benitez 084481a84e Initial implementation of typed URIs.
This is a breaking change. All Rocket applications using code
generation must now additionally declare usage of the 'decl_macro'
feature.
2017-09-14 22:10:25 -07:00

19 lines
358 B
Rust

#![feature(plugin, decl_macro)]
#![plugin(rocket_codegen)]
extern crate rocket;
use rocket::{Error, Request};
#[error(404)]
fn err_a(_a: Error, _b: Request, _c: Error) -> &'static str { "hi" }
//~^ ERROR: can have at most 2
#[error(404)]
fn err_b(_a: (isize, usize)) -> &'static str { "hi" }
//~^ ERROR: unexpected error handler argument
fn main() {
}