Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rustfmt doesn't recognize x86-interrupt calling convention #1375

Closed
phil-opp opened this issue Mar 13, 2017 · 2 comments
Closed

rustfmt doesn't recognize x86-interrupt calling convention #1375

phil-opp opened this issue Mar 13, 2017 · 2 comments
Labels
bug Panic, non-idempotency, invalid code, etc. good first issue Issues up for grabs, also good candidates for new rustfmt contributors

Comments

@phil-opp
Copy link

rustfmt throws the following error if the source contains functions using the new x86-interrupt calling convention (see rust-lang/rust#39832):

error: invalid ABI: expected one of [cdecl, stdcall, fastcall, vectorcall, aapcs, win64, sysv64, ptx-kernel, msp430-interrupt, Rust, C, system, rust-intrinsic, rust-call, platform-intrinsic, unadjusted], found `x86-interrupt`
  --> /….rs:73:8
   |
73 | extern "x86-interrupt" fn divide_by_zero_handler(stack_frame: &mut ExceptionStackFrame) {
   |  
@nrc nrc added bug Panic, non-idempotency, invalid code, etc. good first issue Issues up for grabs, also good candidates for new rustfmt contributors labels Mar 13, 2017
@nrc
Copy link
Member

nrc commented Mar 13, 2017

I expect this just needs a Syntex update

phil-opp added a commit to phil-opp/blog_os that referenced this issue Mar 19, 2017
kevinaboos pushed a commit to theseus-os/Theseus that referenced this issue Jul 27, 2017
@japaric
Copy link
Member

japaric commented Oct 9, 2017

This appears to be fixed as of 0.2.8-nightly (6c9ee31 2017-10-07). Tested with:

extern "x86-interrupt" fn foo() {}

struct VeryVeryLongStructName;

extern "x86-interrupt" fn bar(
    a: VeryVeryLongStructName,
    b: VeryVeryLongStructName,
    c: VeryVeryLongStructName,
    d: VeryVeryLongStructName,
) {
}

Got no errors

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Panic, non-idempotency, invalid code, etc. good first issue Issues up for grabs, also good candidates for new rustfmt contributors
Projects
None yet
Development

No branches or pull requests

3 participants