mirror of
https://github.com/tribufu/tribufu-rust
synced 2026-06-01 09:42:37 +00:00
Create Rust Project
This commit is contained in:
parent
b456f20a4f
commit
36df99c7e0
13 changed files with 230 additions and 0 deletions
28
Source/Friends/mod.rs
Normal file
28
Source/Friends/mod.rs
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
// Copyright (c) TribuFu. All Rights Reserved
|
||||
|
||||
use libc::c_char;
|
||||
|
||||
pub fn AddFriend(id1: *const c_char, id2: *const c_char) {}
|
||||
|
||||
pub fn AcceptFriend(id1: *const c_char, id2: *const c_char) {}
|
||||
|
||||
pub fn GetFriends(id: *const c_char) {}
|
||||
|
||||
mod External {
|
||||
use libc::c_char;
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn AddFriend(id1: *const c_char, id2: *const c_char) {
|
||||
super::AddFriend(id1, id2);
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn AcceptFriend(id1: *const c_char, id2: *const c_char) {
|
||||
super::AcceptFriend(id1, id2);
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn GetFriends(id: *const c_char) {
|
||||
super::GetFriends(id);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue