2024-05-02 16:19:02 -05:00
|
|
|
#![feature(patchable_function_entry)]
|
|
|
|
fn main() {}
|
|
|
|
|
2024-06-26 12:11:25 -05:00
|
|
|
#[patchable_function_entry(prefix_nops = 256, entry_nops = 0)]//~error: integer value out of range
|
2024-05-02 16:19:02 -05:00
|
|
|
pub fn too_high_pnops() {}
|
|
|
|
|
2024-06-26 12:11:25 -05:00
|
|
|
#[patchable_function_entry(prefix_nops = "stringvalue", entry_nops = 0)]//~error: invalid literal value
|
2024-05-02 16:19:02 -05:00
|
|
|
pub fn non_int_nop() {}
|
|
|
|
|
|
|
|
#[patchable_function_entry]//~error: malformed `patchable_function_entry` attribute input
|
|
|
|
pub fn malformed_attribute() {}
|
|
|
|
|
2024-06-26 12:11:25 -05:00
|
|
|
#[patchable_function_entry(prefix_nops = 10, something = 0)]//~error: unexpected parameter name
|
2024-05-02 16:19:02 -05:00
|
|
|
pub fn unexpected_parameter_name() {}
|
|
|
|
|
2024-06-26 12:11:25 -05:00
|
|
|
#[patchable_function_entry()]//~error: must specify at least one parameter
|
2024-05-02 16:19:02 -05:00
|
|
|
pub fn no_parameters_given() {}
|