Skip to content

Commit b182cd7

Browse files
committed
Fix integers in tests (fixup #22700)
1 parent 2d74b53 commit b182cd7

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

Diff for: src/libstd/sync/mpsc/select.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -473,7 +473,7 @@ mod test {
473473

474474
#[test]
475475
fn stress() {
476-
static AMT: u32 = 10000;
476+
static AMT: i32 = 10000;
477477
let (tx1, rx1) = channel::<i32>();
478478
let (tx2, rx2) = channel::<i32>();
479479
let (tx3, rx3) = channel::<()>();

Diff for: src/libstd/sync/rwlock.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -425,8 +425,8 @@ mod tests {
425425
#[test]
426426
fn frob() {
427427
static R: StaticRwLock = RW_LOCK_INIT;
428-
static N: u32 = 10;
429-
static M: u32 = 1000;
428+
static N: usize = 10;
429+
static M: usize = 1000;
430430

431431
let (tx, rx) = channel::<()>();
432432
for _ in 0..N {

Diff for: src/libstd/sync/task_pool.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ mod test {
142142
use super::*;
143143
use sync::mpsc::channel;
144144

145-
const TEST_TASKS: u32 = 4;
145+
const TEST_TASKS: usize = 4;
146146

147147
#[test]
148148
fn test_works() {

0 commit comments

Comments
 (0)