You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
let data = String::from("1-5 w:dsjvly wge");
let min: i32;
let max: i32;
let c: char;
let pw: String;
scan!(data.bytes() => "{}-{} {}:{}", min, max, c, pw);
dbg!(pw);
Here, pw returns dsjvly only, skipping wge. How should one get around this so the complete string gets captured?
The text was updated successfully, but these errors were encountered:
If your pattern finishes with with anything but a capture, then that would work. So if your data contained a trailing . and your pattern was also finished by a . then it would work. I guess we could change scan! to always parse to the end in case the pattern ends with a placeholder, but this would not really work for using scan! for stdin or any other infinite input source.
Here,
pw
returnsdsjvly
only, skippingwge
. How should one get around this so the complete string gets captured?The text was updated successfully, but these errors were encountered: