(flags: RelocationFlags, expected_kind: RelocationKind, expected_size: u8)
| 224 | |
| 225 | #[track_caller] |
| 226 | fn assert_generic(flags: RelocationFlags, expected_kind: RelocationKind, expected_size: u8) { |
| 227 | match flags { |
| 228 | RelocationFlags::Generic { |
| 229 | kind, |
| 230 | encoding, |
| 231 | size, |
| 232 | } => { |
| 233 | assert_eq!(kind, expected_kind, "wrong relocation kind"); |
| 234 | assert_eq!( |
| 235 | encoding, |
| 236 | RelocationEncoding::Generic, |
| 237 | "wrong relocation encoding" |
| 238 | ); |
| 239 | assert_eq!(size, expected_size, "wrong relocation size in bits"); |
| 240 | } |
| 241 | other => panic!("expected RelocationFlags::Generic, got {other:?}"), |
| 242 | } |
| 243 | } |
| 244 | |
| 245 | #[test] |
| 246 | fn missing_eh_pe_falls_back_to_absolute_pointer() { |
no outgoing calls