Skip to content

Commit 64bc715

Browse files
committed
errors: improve error messages for cxx_file_stem and multiple dirs
1 parent 9fe8898 commit 64bc715

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

crates/cxx-qt-build/src/lib.rs

+5-1
Original file line numberDiff line numberDiff line change
@@ -773,7 +773,11 @@ impl CxxQtBuilder {
773773
})
774774
.collect::<HashSet<String>>();
775775
if dirs.len() > 1 {
776-
panic!("Only one directory is support per QmlModule for rust_files");
776+
panic!(
777+
"Only one directory is supported per QmlModule for rust_files.\n\
778+
This is due to Qt bug https://bugreports.qt.io/browse/QTBUG-93443\n\
779+
Found directories: {dirs:?}"
780+
);
777781
}
778782

779783
for files in generate_cxxqt_cpp_files(

crates/cxx-qt-gen/src/parser/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ impl Parser {
8585
} else if name_value.path.is_ident("cxx_file_stem") {
8686
return Err(Error::new(
8787
meta.span(),
88-
"cxx_file_stem is unsupported: TODO new system message",
88+
"cxx_file_stem is unsupported, instead the input file name will be used",
8989
));
9090
}
9191
}

0 commit comments

Comments
 (0)