Skip to content

Commit

Permalink
Auto merge of rust-lang#2612 - ChrisDenton:getfiletype, r=RalfJung
Browse files Browse the repository at this point in the history
add GetFileType stub

because I'm planning to break miri again rust-lang#103360

See [GetFileType](https://learn.microsoft.com/en-us/windows/win32/api/fileapi/nf-fileapi-getfiletype)
  • Loading branch information
bors committed Oct 21, 2022
2 parents 6504d2e + 590834b commit fc3bcac
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/tools/miri/src/shims/windows/foreign_items.rs
Original file line number Diff line number Diff line change
Expand Up @@ -425,6 +425,13 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriInterpCxExt<'mir, 'tcx> {
// Just make it fail.
this.write_null(dest)?;
}
"GetFileType" if this.frame_in_std() => {
#[allow(non_snake_case)]
let [_hFile] =
this.check_shim(abi, Abi::System { unwind: false }, link_name, args)?;
// Return unknown file type.
this.write_null(dest)?;
}
"AddVectoredExceptionHandler" if this.frame_in_std() => {
#[allow(non_snake_case)]
let [_First, _Handler] =
Expand Down

0 comments on commit fc3bcac

Please sign in to comment.