Skip to content

Commit 0518f2b

Browse files
committed
run rustfmt on the code
1 parent 7d218fe commit 0518f2b

File tree

6 files changed

+17783
-3199
lines changed

6 files changed

+17783
-3199
lines changed

src/buffer.rs

+6-3
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,8 @@ impl Default for NaiveBuffer {
265265

266266
impl NaiveBuffer {
267267
#[inline]
268-
#[must_use] pub fn new() -> Self {
268+
#[must_use]
269+
pub fn new() -> Self {
269270
let list = SMALL_PRIMES.iter().map(|&p| u64::from(p)).collect();
270271
NaiveBuffer {
271272
list,
@@ -359,7 +360,8 @@ impl NaiveBuffer {
359360
}
360361

361362
/// Returns all primes ≤ `limit` and takes ownership. The primes are sorted.
362-
#[must_use] pub fn into_primes(mut self, limit: u64) -> std::vec::IntoIter<u64> {
363+
#[must_use]
364+
pub fn into_primes(mut self, limit: u64) -> std::vec::IntoIter<u64> {
363365
self.reserve(limit);
364366
let position = match self.list.binary_search(&limit) {
365367
Ok(p) => p + 1,
@@ -379,7 +381,8 @@ impl NaiveBuffer {
379381
}
380382

381383
/// Returns primes of certain amount counting from 2 and takes ownership. The primes are sorted.
382-
#[must_use] pub fn into_nprimes(mut self, count: usize) -> std::vec::IntoIter<u64> {
384+
#[must_use]
385+
pub fn into_nprimes(mut self, count: usize) -> std::vec::IntoIter<u64> {
383386
let (_, bound) = nth_prime_bounds(&(count as u64))
384387
.expect("Estimated size of the largest prime will be larger than u64 limit");
385388
self.reserve(bound);

src/integer.rs

-1
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,6 @@ impl ExactRoots for BigInt {
157157
#[cfg(test)]
158158
mod tests {
159159
use super::*;
160-
161160

162161
#[test]
163162
fn exact_root_test() {

0 commit comments

Comments
 (0)