This repository has been archived on 2022-02-08. You can view files and clone it, but cannot push or open issues or pull requests.
ext2-rs/src/lib.rs
2018-03-19 13:30:42 +01:00

32 lines
675 B
Rust

#![feature(alloc)]
#![feature(specialization)]
#![feature(swap_with_slice)]
#![feature(macro_lifetime_matcher)]
#![cfg_attr(all(not(test), feature = "no_std"), no_std)]
extern crate alloc;
#[macro_use]
extern crate bitflags;
#[cfg(any(test, not(feature = "no_std")))]
extern crate core;
pub mod error;
pub mod sys;
pub mod buffer;
pub mod fs;
#[cfg(test)]
mod tests {
use sys::superblock::*;
use sys::block_group::*;
use sys::inode::*;
#[test]
fn sizes() {
use std::mem::size_of;
assert_eq!(size_of::<Superblock>(), 1024);
assert_eq!(size_of::<BlockGroupDescriptor>(), 32);
assert_eq!(size_of::<Inode>(), 128);
}
}