summaryrefslogtreecommitdiff
path: root/exercises/structs/structs3.rs
diff options
context:
space:
mode:
authormokou <mokou@fastmail.com>2022-07-15 14:31:49 +0200
committermokou <mokou@fastmail.com>2022-07-15 14:31:49 +0200
commitc791cf4232fbfc313279b19b483c1adbca1c6862 (patch)
tree655ad6c9d33dab11dfd70f28d0ec29d03749a70b /exercises/structs/structs3.rs
parentf1c4caa37fe5027d121aec6433dee85433d9329d (diff)
parentc265b681b188ea21b3f8585e65ea363fc02c4b50 (diff)
Merge branch '5.0-dev'
Diffstat (limited to 'exercises/structs/structs3.rs')
-rw-r--r--exercises/structs/structs3.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/exercises/structs/structs3.rs b/exercises/structs/structs3.rs
index e84f2eb..0b3615f 100644
--- a/exercises/structs/structs3.rs
+++ b/exercises/structs/structs3.rs
@@ -2,7 +2,7 @@
// Structs contain data, but can also have logic. In this exercise we have
// defined the Package struct and we want to test some logic attached to it.
// Make the code compile and the tests pass!
-// If you have issues execute `rustlings hint structs3`
+// Execute `rustlings hint structs3` or use the `hint` watch subcommand for a hint.
// I AM NOT DONE
@@ -16,7 +16,7 @@ struct Package {
impl Package {
fn new(sender_country: String, recipient_country: String, weight_in_grams: i32) -> Package {
if weight_in_grams <= 0 {
- // panic statement goes here...
+ panic!("Can not ship a weightless package.")
} else {
Package {
sender_country,