aboutsummaryrefslogtreecommitdiff
path: root/vendor/rayon-core/src/compile_fail
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/rayon-core/src/compile_fail')
-rw-r--r--vendor/rayon-core/src/compile_fail/mod.rs7
-rw-r--r--vendor/rayon-core/src/compile_fail/quicksort_race1.rs28
-rw-r--r--vendor/rayon-core/src/compile_fail/quicksort_race2.rs28
-rw-r--r--vendor/rayon-core/src/compile_fail/quicksort_race3.rs28
-rw-r--r--vendor/rayon-core/src/compile_fail/rc_return.rs17
-rw-r--r--vendor/rayon-core/src/compile_fail/rc_upvar.rs9
-rw-r--r--vendor/rayon-core/src/compile_fail/scope_join_bad.rs24
7 files changed, 0 insertions, 141 deletions
diff --git a/vendor/rayon-core/src/compile_fail/mod.rs b/vendor/rayon-core/src/compile_fail/mod.rs
deleted file mode 100644
index f2ec646..0000000
--- a/vendor/rayon-core/src/compile_fail/mod.rs
+++ /dev/null
@@ -1,7 +0,0 @@
-// These modules contain `compile_fail` doc tests.
-mod quicksort_race1;
-mod quicksort_race2;
-mod quicksort_race3;
-mod rc_return;
-mod rc_upvar;
-mod scope_join_bad;
diff --git a/vendor/rayon-core/src/compile_fail/quicksort_race1.rs b/vendor/rayon-core/src/compile_fail/quicksort_race1.rs
deleted file mode 100644
index 5615033..0000000
--- a/vendor/rayon-core/src/compile_fail/quicksort_race1.rs
+++ /dev/null
@@ -1,28 +0,0 @@
-/*! ```compile_fail,E0524
-
-fn quick_sort<T:PartialOrd+Send>(v: &mut [T]) {
- if v.len() <= 1 {
- return;
- }
-
- let mid = partition(v);
- let (lo, _hi) = v.split_at_mut(mid);
- rayon_core::join(|| quick_sort(lo), || quick_sort(lo)); //~ ERROR
-}
-
-fn partition<T:PartialOrd+Send>(v: &mut [T]) -> usize {
- let pivot = v.len() - 1;
- let mut i = 0;
- for j in 0..pivot {
- if v[j] <= v[pivot] {
- v.swap(i, j);
- i += 1;
- }
- }
- v.swap(i, pivot);
- i
-}
-
-fn main() { }
-
-``` */
diff --git a/vendor/rayon-core/src/compile_fail/quicksort_race2.rs b/vendor/rayon-core/src/compile_fail/quicksort_race2.rs
deleted file mode 100644
index 020589c..0000000
--- a/vendor/rayon-core/src/compile_fail/quicksort_race2.rs
+++ /dev/null
@@ -1,28 +0,0 @@
-/*! ```compile_fail,E0500
-
-fn quick_sort<T:PartialOrd+Send>(v: &mut [T]) {
- if v.len() <= 1 {
- return;
- }
-
- let mid = partition(v);
- let (lo, _hi) = v.split_at_mut(mid);
- rayon_core::join(|| quick_sort(lo), || quick_sort(v)); //~ ERROR
-}
-
-fn partition<T:PartialOrd+Send>(v: &mut [T]) -> usize {
- let pivot = v.len() - 1;
- let mut i = 0;
- for j in 0..pivot {
- if v[j] <= v[pivot] {
- v.swap(i, j);
- i += 1;
- }
- }
- v.swap(i, pivot);
- i
-}
-
-fn main() { }
-
-``` */
diff --git a/vendor/rayon-core/src/compile_fail/quicksort_race3.rs b/vendor/rayon-core/src/compile_fail/quicksort_race3.rs
deleted file mode 100644
index 16fbf3b..0000000
--- a/vendor/rayon-core/src/compile_fail/quicksort_race3.rs
+++ /dev/null
@@ -1,28 +0,0 @@
-/*! ```compile_fail,E0524
-
-fn quick_sort<T:PartialOrd+Send>(v: &mut [T]) {
- if v.len() <= 1 {
- return;
- }
-
- let mid = partition(v);
- let (_lo, hi) = v.split_at_mut(mid);
- rayon_core::join(|| quick_sort(hi), || quick_sort(hi)); //~ ERROR
-}
-
-fn partition<T:PartialOrd+Send>(v: &mut [T]) -> usize {
- let pivot = v.len() - 1;
- let mut i = 0;
- for j in 0..pivot {
- if v[j] <= v[pivot] {
- v.swap(i, j);
- i += 1;
- }
- }
- v.swap(i, pivot);
- i
-}
-
-fn main() { }
-
-``` */
diff --git a/vendor/rayon-core/src/compile_fail/rc_return.rs b/vendor/rayon-core/src/compile_fail/rc_return.rs
deleted file mode 100644
index 93e3a60..0000000
--- a/vendor/rayon-core/src/compile_fail/rc_return.rs
+++ /dev/null
@@ -1,17 +0,0 @@
-/** ```compile_fail,E0277
-
-use std::rc::Rc;
-
-rayon_core::join(|| Rc::new(22), || ()); //~ ERROR
-
-``` */
-mod left {}
-
-/** ```compile_fail,E0277
-
-use std::rc::Rc;
-
-rayon_core::join(|| (), || Rc::new(23)); //~ ERROR
-
-``` */
-mod right {}
diff --git a/vendor/rayon-core/src/compile_fail/rc_upvar.rs b/vendor/rayon-core/src/compile_fail/rc_upvar.rs
deleted file mode 100644
index d8aebcf..0000000
--- a/vendor/rayon-core/src/compile_fail/rc_upvar.rs
+++ /dev/null
@@ -1,9 +0,0 @@
-/*! ```compile_fail,E0277
-
-use std::rc::Rc;
-
-let r = Rc::new(22);
-rayon_core::join(|| r.clone(), || r.clone());
-//~^ ERROR
-
-``` */
diff --git a/vendor/rayon-core/src/compile_fail/scope_join_bad.rs b/vendor/rayon-core/src/compile_fail/scope_join_bad.rs
deleted file mode 100644
index 75e4c5c..0000000
--- a/vendor/rayon-core/src/compile_fail/scope_join_bad.rs
+++ /dev/null
@@ -1,24 +0,0 @@
-/*! ```compile_fail,E0373
-
-fn bad_scope<F>(f: F)
- where F: FnOnce(&i32) + Send,
-{
- rayon_core::scope(|s| {
- let x = 22;
- s.spawn(|_| f(&x)); //~ ERROR `x` does not live long enough
- });
-}
-
-fn good_scope<F>(f: F)
- where F: FnOnce(&i32) + Send,
-{
- let x = 22;
- rayon_core::scope(|s| {
- s.spawn(|_| f(&x));
- });
-}
-
-fn main() {
-}
-
-``` */