Skip to content
This repository was archived by the owner on Aug 5, 2022. It is now read-only.

Commit 904d0aa

Browse files
committed
Update rand, correct some compiletest_rs changes due to Rust version
1 parent e112954 commit 904d0aa

File tree

6 files changed

+7
-7
lines changed

6 files changed

+7
-7
lines changed

β€Žexamples/game-loop/main.rsβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ struct TestTunables {
108108

109109
// A random number generator, used to generate numbers between the above
110110
// min/max configurations.
111-
rng: rand::ThreadRng,
111+
rng: rand::rngs::ThreadRng,
112112
}
113113

114114
fn main() {

β€Žsm/Cargo.tomlβ€Ž

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ edition = "2018"
1515
sm_macro = { version = "1.0", path = "../sm_macro", optional = true }
1616

1717
[dev-dependencies]
18-
compiletest_rs = { version = "0.3", features = [ "stable" ] }
18+
compiletest_rs = { version = "*" }
1919
criterion = "0.3"
20-
rand = "0.5"
20+
rand = "0.7"
2121
sm_macro = { version = "1.0", path = "../sm_macro" }
2222

2323
[features]

β€Žsm/tests/compile-fail/undefined-event.rsβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,5 @@ fn main() {
1515

1616
sm.transition(Invalid);
1717
//~^ ERROR cannot find value `Invalid` in this scope
18-
//~| ERROR no method named `transition` found for type `Lock::Machine<Lock::Locked, sm::NoneEvent>` in the current scope
18+
//~| ERROR no method named `transition` found for struct `Lock::Machine<Lock::Locked, sm::NoneEvent>` in the current scope
1919
}

β€Žsm/tests/compile-fail/undefined-transition.rsβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,5 @@ fn main() {
1616
let sm = Machine::new(Unlocked);
1717

1818
sm.transition(TurnKey);
19-
//~^ ERROR no method named `transition` found for type `Lock::Machine<Lock::Unlocked, sm::NoneEvent>` in the current scope
19+
//~^ ERROR no method named `transition` found for struct `Lock::Machine<Lock::Unlocked, sm::NoneEvent>` in the current scope
2020
}

β€Žtest_suite/Cargo.tomlβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ sm = { path = "../sm" }
1010
sm_macro = { path = "../sm_macro" }
1111

1212
[dependencies]
13-
compiletest_rs = { version = "0.3", features = [ "stable" ] }
13+
compiletest_rs = { version = "*" }

β€Žtest_suite/tests/compile-fail/macros/sm/invalid-transition.rsβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@ fn main() {
1414

1515
let sm = Machine::new(Unlocked);
1616
sm = sm.transition(TurnKey);
17-
//~^ ERROR no method named `transition` found for type `Lock::Machine<Lock::Unlocked, sm::NoneEvent>` in the current scope
17+
//~^ ERROR no method named `transition` found for struct `Lock::Machine<Lock::Unlocked, sm::NoneEvent>` in the current scope
1818
}

0 commit comments

Comments
Β (0)