Skip to content

Commit 16aa0c7

Browse files
committed
Compare module_bindings files by String, not bytes
1 parent 7ebd318 commit 16aa0c7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

crates/cli/src/subcommands/generate.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -200,8 +200,8 @@ pub async fn exec_ex(
200200
fs::create_dir_all(out_dir.join(parent))?;
201201
}
202202
let path = out_dir.join(fname);
203-
let contents = fs::read(&path);
204-
if contents.is_err() || contents.is_ok_and(|contents| !code.bytes().eq(contents)) {
203+
let contents = fs::read_to_string(&path);
204+
if contents.is_err() || contents.is_ok_and(|contents| code != contents) {
205205
fs::write(&path, code)?;
206206
}
207207
paths.insert(path);

0 commit comments

Comments
 (0)