Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/librustc/driver/driver.rs
Original file line number Diff line number Diff line change
Expand Up @@ -894,6 +894,11 @@ pub fn build_output_filenames(input: &Input,
};

let mut stem = input.filestem();

//Prevents damage to unstemmed source files
if stem == source_name(input){
sess.err(format!("File `{}` has a missing file extension", stem).as_slice());
}

// If a crateid is present, we use it as the link name
let crateid = attr::find_crateid(attrs);
Expand Down