Skip to content

Commit

Permalink
1. Removing Travis
Browse files Browse the repository at this point in the history
2. Refactoring tests
3. Minor changes
  • Loading branch information
denisandroid committed May 11, 2024
1 parent 1b9b89f commit a242791
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 19 deletions.
10 changes: 0 additions & 10 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion examples/generic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
use core::fmt::Display;
use cluFullTransmute::transmute_or_panic;

/// Implementation of a simple transmutation with a generic parameter inside.
// Implementation of a simple transmutation with a generic parameter inside.

#[derive(Debug)]
#[repr(transparent)]
Expand Down
16 changes: 10 additions & 6 deletions src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//Copyright 2022 #UlinProject Denis Kotlyarov (Денис Котляров)
//Copyright 2022-2024 #UlinProject Denis Kotlyarov (Денис Котляров)

//Licensed under the Apache License, Version 2.0 (the "License");
//you may not use this file except in compliance with the License.
Expand All @@ -12,7 +12,7 @@
//See the License for the specific language governing permissions and
// limitations under the License.

// #Ulin Project 2022
// #Ulin Project 2022-2024
/*!
A more complete and extended version of data type conversion without constraint checks.
Expand All @@ -32,7 +32,7 @@ A more complete and extended version of data type conversion without constraint
# Use
### 1. GenericType
### 1. Generic
```rust
use core::fmt::Display;
Expand Down Expand Up @@ -157,7 +157,7 @@ fn main() {
#![cfg_attr(docsrs, feature(doc_cfg))]
#![cfg_attr(not(feature = "support_stderr"), no_std)]

/// Basic functions for dealing with memory.
/// Basic functions for dealing with memory.
///
/// (An optional module for ensuring compatibility with the standard library, which is turned on and off with the `compatible_stdapi` build flag.)
#[cfg_attr(docsrs, doc(cfg(feature = "compatible_stdapi")))]
Expand Down Expand Up @@ -252,7 +252,9 @@ pub const unsafe fn inline_transmute_or_panic<D, To>(in_data: D) -> To {
/// If the size does not match, an error occurs.
#[cfg_attr(docsrs, doc(cfg(feature = "support_size_check_transmute")))]
#[cfg( any(test, feature = "support_size_check_transmute") )]
pub const unsafe fn transmute_or_errresult<D, To>(in_data: D) -> Result<To, TransmuteErr<D>> {
pub const unsafe fn transmute_or_errresult<D, To>(
in_data: D
) -> Result<To, TransmuteErr<D>> {
{ // #1: Data dimension check
let size_d = size_of::<D>();
let size_to = size_of::<To>();
Expand All @@ -279,7 +281,9 @@ pub const unsafe fn transmute_or_errresult<D, To>(in_data: D) -> Result<To, Tran
#[cfg( any(test, feature = "inline") )]
#[cfg_attr(docsrs, doc(cfg(feature = "support_size_check_transmute")))]
#[cfg( any(test, feature = "support_size_check_transmute") )]
pub const unsafe fn inline_transmute_or_errresult<D, To>(in_data: D) -> Result<To, TransmuteErr<D>> {
pub const unsafe fn inline_transmute_or_errresult<D, To>(
in_data: D
) -> Result<To, TransmuteErr<D>> {
{ // #1: Data dimension check
let size_d = size_of::<D>();
let size_to = size_of::<To>();
Expand Down
File renamed without changes.
2 changes: 0 additions & 2 deletions tests/easy.rs → tests/generic.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@

extern crate cluFullTransmute;

use std::hash::Hasher;
use std::hash::Hash;
use std::collections::hash_map::DefaultHasher;
Expand Down
File renamed without changes.

0 comments on commit a242791

Please sign in to comment.