mirror of
https://github.com/aljazceru/turso.git
synced 2026-02-12 03:34:20 +01:00
core: silence some unused warnings when building without default features
This commit is contained in:
@@ -153,6 +153,7 @@ impl Database {
|
||||
}
|
||||
|
||||
pub fn register_builtins(&self) -> Result<(), String> {
|
||||
#[allow(unused_variables)]
|
||||
let ext_api = self.build_limbo_ext();
|
||||
#[cfg(feature = "uuid")]
|
||||
if unsafe { !limbo_uuid::register_extension_static(&ext_api).is_ok() } {
|
||||
|
||||
@@ -166,14 +166,17 @@ impl Buffer {
|
||||
cfg_block! {
|
||||
#[cfg(all(target_os = "linux", feature = "io_uring"))] {
|
||||
mod io_uring;
|
||||
#[cfg(feature = "fs")]
|
||||
pub use io_uring::UringIO;
|
||||
mod unix;
|
||||
#[cfg(feature = "fs")]
|
||||
pub use unix::UnixIO;
|
||||
pub use io_uring::UringIO as PlatformIO;
|
||||
}
|
||||
|
||||
#[cfg(any(all(target_os = "linux",not(feature = "io_uring")), target_os = "macos"))] {
|
||||
mod unix;
|
||||
#[cfg(feature = "fs")]
|
||||
pub use unix::UnixIO;
|
||||
pub use unix::UnixIO as PlatformIO;
|
||||
}
|
||||
|
||||
@@ -22,6 +22,7 @@ pub struct UnixIO {
|
||||
}
|
||||
|
||||
impl UnixIO {
|
||||
#[cfg(feature = "fs")]
|
||||
pub fn new() -> Result<Self> {
|
||||
debug!("Using IO backend 'syscall'");
|
||||
Ok(Self {
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
use crate::{error::LimboError, io::Completion, Buffer, Result};
|
||||
#[cfg(feature = "fs")]
|
||||
use crate::error::LimboError;
|
||||
use crate::{io::Completion, Buffer, Result};
|
||||
use std::{cell::RefCell, rc::Rc};
|
||||
|
||||
/// DatabaseStorage is an interface a database file that consists of pages.
|
||||
|
||||
@@ -159,6 +159,7 @@ macro_rules! expect_arguments_min {
|
||||
}};
|
||||
}
|
||||
|
||||
#[allow(unused_macros)]
|
||||
macro_rules! expect_arguments_even {
|
||||
(
|
||||
$args:expr,
|
||||
|
||||
Reference in New Issue
Block a user