Skip to content

Commit

Permalink
refactor(sys): modify stub
Browse files Browse the repository at this point in the history
  • Loading branch information
qevolg committed Dec 23, 2024
1 parent 46d2759 commit 85538a9
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 16 deletions.
10 changes: 0 additions & 10 deletions taos-sys/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,6 @@ pub enum TSDB_OPTION {
TSDB_MAX_OPTIONS = 7,
}

#[no_mangle]
pub extern "C" fn taos_init() -> c_int {
todo!()
}

#[no_mangle]
pub extern "C" fn taos_cleanup() {
todo!()
}

#[allow(clippy::just_underscores_and_digits)]
#[no_mangle]
pub unsafe extern "C" fn taos_options(option: TSDB_OPTION, arg: *const c_void, ...) -> c_int {
Expand Down
18 changes: 12 additions & 6 deletions taos-sys/src/stub.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,18 @@

use std::ffi::{c_char, c_int, c_ulong, c_void};

use crate::{
query::{__taos_async_fn_t, TAOS_FIELD},
stmt::TAOS_FIELD_E,
tmq::tmq_t,
TAOS, TAOS_RES,
};
use crate::query::{__taos_async_fn_t, TAOS_FIELD};
use crate::stmt::TAOS_FIELD_E;
use crate::tmq::tmq_t;
use crate::{TAOS, TAOS_RES};

#[no_mangle]
pub extern "C" fn taos_init() -> c_int {
0
}

#[no_mangle]
pub extern "C" fn taos_cleanup() {}

#[no_mangle]
pub extern "C" fn taos_connect_auth(
Expand Down

0 comments on commit 85538a9

Please sign in to comment.