Skip to content

Commit c7205b5

Browse files
hyperpolymathclaude
andcommitted
fix(clippy): replace Vec::new()+push with vec![] macro (clippy::vec_init_then_push)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent a6331f1 commit c7205b5

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

src/rust/src/robot.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,7 @@ pub struct Robot {
5151
impl Robot {
5252
/// Create a new robot
5353
pub fn new(position: Position) -> Self {
54-
let mut path_history = Vec::new();
55-
path_history.push(position);
54+
let path_history = vec![position];
5655

5756
Self {
5857
position,

0 commit comments

Comments
 (0)