Skip to content

Commit

Permalink
Bump version v0.3.2.
Browse files Browse the repository at this point in the history
Fixed clippy lint.
Updated feature gates.
  • Loading branch information
raldone01 committed Sep 29, 2022
1 parent bf27b8b commit 63c8ee1
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 113 deletions.
12 changes: 10 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,19 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [0.3.2] - 2022-09-29

- Updated feature gates.

### Fixes
- Fixed clippy lints.

## [0.3.1] - 2022-09-25

Moved to [ink-feather-org](https://github.com/ink-feather-org/const_sort_rs).

### Fixes
- Fixed clippy lints
- Fixed clippy lints.

## [0.3.0] - 2022-09-22

Expand All @@ -24,7 +31,8 @@ Moved to [ink-feather-org](https://github.com/ink-feather-org/const_sort_rs).

## [0.1.0] - 2022-09-14

[Unreleased]: https://github.com/ink-feather-org/const_sort_rs/compare/v0.3.1...HEAD
[Unreleased]: https://github.com/ink-feather-org/const_sort_rs/compare/v0.3.2...HEAD
[0.3.1]: https://github.com/ink-feather-org/const_sort_rs/compare/v0.3.1...v0.3.2
[0.3.1]: https://github.com/ink-feather-org/const_sort_rs/compare/v0.3.0...v0.3.1
[0.3.0]: https://github.com/ink-feather-org/const_sort_rs/compare/v0.2.1...v0.3.0
[0.2.1]: https://github.com/ink-feather-org/const_sort_rs/compare/v0.2.0...v0.2.1
Expand Down
2 changes: 1 addition & 1 deletion const_sort_rs/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "const_sort_rs"
version = "0.3.1"
version = "0.3.2"
edition = "2021"
license = "MIT OR Apache-2.0"
authors = [
Expand Down
17 changes: 8 additions & 9 deletions const_sort_rs/src/const_sort.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ use core::mem::{self, MaybeUninit};
use core::ptr;

use crate::fake_usize_ptr::FakeUsizePtr;
use crate::slice_const_split_at_mut::ConstSplitAtMutExtensions;

/// When dropped, copies from `src` into `dest`.
struct CopyOnDrop<T> {
Expand Down Expand Up @@ -546,7 +545,7 @@ where
let (mid, was_partitioned) = {
// Place the pivot at the beginning of slice.
v.swap(0, pivot);
let (pivot, v) = v.const_split_at_mut(1);
let (pivot, v) = v.split_at_mut(1);
let pivot = &mut pivot[0];

// Read the pivot into a stack-allocated variable for efficiency. If a following comparison
Expand Down Expand Up @@ -606,7 +605,7 @@ where
{
// Place the pivot at the beginning of slice.
v.swap(0, pivot);
let (pivot, v) = v.const_split_at_mut(1);
let (pivot, v) = v.split_at_mut(1);
let pivot = &mut pivot[0];

// Read the pivot into a stack-allocated variable for efficiency. If a following comparison
Expand Down Expand Up @@ -877,8 +876,8 @@ const fn recurse<'a, T, F>(
was_partitioned = was_p;

// Split the slice into `left`, `pivot`, and `right`.
let (left, right) = v.const_split_at_mut(mid);
let (pivot, right) = right.const_split_at_mut(1);
let (left, right) = v.split_at_mut(mid);
let (pivot, right) = right.split_at_mut(1);
let pivot = &pivot[0];

// Recurse into the shorter side only in order to minimize the total number of recursive
Expand Down Expand Up @@ -957,8 +956,8 @@ const fn partition_at_index_loop<'a, T, F>(
let (mid, _) = partition(v, pivot, is_less);

// Split the slice into `left`, `pivot`, and `right`.
let (left, right) = v.const_split_at_mut(mid);
let (pivot, right) = right.const_split_at_mut(1);
let (left, right) = v.split_at_mut(mid);
let (pivot, right) = right.split_at_mut(1);
let pivot = &pivot[0];

if mid < index {
Expand Down Expand Up @@ -1026,8 +1025,8 @@ where
partition_at_index_loop(v, index, &mut is_less, None);
}

let (left, right) = v.const_split_at_mut(index);
let (pivot, right) = right.const_split_at_mut(1);
let (left, right) = v.split_at_mut(index);
let (pivot, right) = right.split_at_mut(1);
let pivot = &mut pivot[0];
(left, pivot, right)
}
4 changes: 1 addition & 3 deletions const_sort_rs/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,12 @@
#![feature(const_ptr_read)] // const_sort_core
#![feature(const_deref)] // const_sort_core
#![feature(const_reverse)] // const_sort_core
#![feature(mixed_integer_ops)] // const_sort_core
#![feature(const_slice_split_at_mut)] // const_sort_core
#![feature(const_maybe_uninit_write)] // const_sort_core
#![feature(core_intrinsics)] // const_sort_core
#![feature(const_eval_select)] // const_sort_core
#![feature(const_slice_index)] // const_sort_core
#![feature(const_cmp)] // const_sort_core
#![feature(const_slice_from_raw_parts_mut)] // slice_const_split_at_mut FIXME: Replace with const_slice_split_at_mut once it lands.
#![feature(unboxed_closures)] // const_slice_sort_ext
#![feature(fn_traits)] // const_slice_sort_ext
// For tests
Expand Down Expand Up @@ -76,7 +75,6 @@ conditions.
*/

pub(crate) mod fake_usize_ptr;
pub(crate) mod slice_const_split_at_mut;

#[allow(
clippy::undocumented_unsafe_blocks,
Expand Down
98 changes: 0 additions & 98 deletions const_sort_rs/src/slice_const_split_at_mut.rs

This file was deleted.

0 comments on commit 63c8ee1

Please sign in to comment.