We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5f17dcb commit 5dac50cCopy full SHA for 5dac50c
diagram/src/main.rs
@@ -13,7 +13,7 @@ fn main() {
13
for (name, f) in diagrams {
14
let mut imgbuf = ImageBuffer::new(width, height);
15
for (col, row, pixel) in imgbuf.enumerate_pixels_mut() {
16
- *pixel = if char::from_u32(row * width + col).map_or(false, f) {
+ *pixel = if char::from_u32(row * width + col).is_some_and(f) {
17
Rgb([0u8, 0, 0])
18
} else {
19
Rgb([255, 255, 255])
0 commit comments