We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3bad558 commit fb996caCopy full SHA for fb996ca
crates/ra_proc_macro_srv/src/dylib.rs
@@ -199,6 +199,7 @@ impl Expander {
199
}
200
201
202
+#[cfg(windows)]
203
fn copy_to_temp_dir(path: &Path) -> io::Result<PathBuf> {
204
let mut to = std::env::temp_dir();
205
let file_name = path.file_name().ok_or_else(|| {
@@ -212,3 +213,8 @@ fn copy_to_temp_dir(path: &Path) -> io::Result<PathBuf> {
212
213
std::fs::copy(path, &to)?;
214
Ok(to)
215
216
+
217
+#[cfg(unix)]
218
+fn copy_to_temp_dir(path: &Path) -> io::Result<PathBuf> {
219
+ Ok(path.to_path_buf())
220
+}
0 commit comments