fn_abiA proc attribute macro that sets the ABI/calling convention for the attributed function.
```rust
extern crate fn_abi;
extern fn hello_world() { println!("hello world!"); }
extern fn hello_world() { println!("hello world!"); } ```
fn_abi supports a number of target shortcuts that you can use.
```rust
linux32 = "C",
linux64 = "C",
win32 = "thiscall",
win64 = "fastcall"
)] extern fn hello_world() { println!("hello world!"); } ```
Currently, the macro will translate the following targets to their respective cfg attributes:
| Shorthand | Expansion |
|:---:|:---:|
| linux | cfg(target_os = "linux") |
| win | cfg(target_os = "windows") |
| macos | cfg(target_os = "macos") |
| linux32 | cfg(all(target_os = "linux", target_pointer_width = "32")) |
| linux64 | cfg(all(target_os = "linux", target_pointer_width = "32")) |
| win32 | cfg(all(target_os = "windows", target_pointer_width = "32")) |
| win64 | cfg(all(target_os = "windows", target_pointer_width = "32")) |
| macos32 | cfg(all(target_os = "macos", target_pointer_width = "32")) |
| macos64 | cfg(all(target_os = "macos", target_pointer_width = "32")) |
Please feel free to contribute if you find a target that is not supported.