Closed steveklabnik closed 8 years ago
I have been waiting for this... Awesome..
Wow, this is impressive!
I really like the approach of combining naked functions with macros. Maybe you should fly more often ;)
@phil-opp yup @steveklabnik should fly more often... :laughing:
waiting for next steve_was_on_a_plane
PR..
maybe you should fly on a plane more often
hahahah
Sooooo more "Steve is doing coding on a plane."
In #33, both @ticki and @eddyb suggested moving to
naked fn
s for the interrupt handlers. Given that Rust was so nice to implement this feature just for OSdev, why not?So I started hacking away. I realized that if I had the trampoline in Rust, I really didn't want to copy it over and over. But each function would need to be able to call into the right one... so a macro. So I started working on a macro-based solution... and then I thought, hmmm, this code seems familiar... and turns out, @Ericson2314 introduced me to this technique a few weeks ago. I guess it percolated in my brain until now. It's not the exact same code, but the same basic strategy: use a macro to generate an
IDTEntry
, and go from there.:confetti_ball: