@@ -5,27 +5,27 @@ pub struct ExceptionType(isize);
55
66impl ExceptionType {
77 /// Undefined Exception
8- pub const EXCEPT_EBC_UNDEFINED : ExceptionType = ExceptionType ( 0 ) ;
8+ pub const EXCEPT_EBC_UNDEFINED : Self = Self ( 0 ) ;
99 /// Divide-by-zero Error
10- pub const EXCEPT_EBC_DIVIDE_ERROR : ExceptionType = ExceptionType ( 1 ) ;
10+ pub const EXCEPT_EBC_DIVIDE_ERROR : Self = Self ( 1 ) ;
1111 /// Debug Exception
12- pub const EXCEPT_EBC_DEBUG : ExceptionType = ExceptionType ( 2 ) ;
12+ pub const EXCEPT_EBC_DEBUG : Self = Self ( 2 ) ;
1313 /// Breakpoint
14- pub const EXCEPT_EBC_BREAKPOINT : ExceptionType = ExceptionType ( 3 ) ;
14+ pub const EXCEPT_EBC_BREAKPOINT : Self = Self ( 3 ) ;
1515 /// Overflow
16- pub const EXCEPT_EBC_OVERFLOW : ExceptionType = ExceptionType ( 4 ) ;
16+ pub const EXCEPT_EBC_OVERFLOW : Self = Self ( 4 ) ;
1717 /// Invalid Opcode
18- pub const EXCEPT_EBC_INVALID_OPCODE : ExceptionType = ExceptionType ( 5 ) ;
18+ pub const EXCEPT_EBC_INVALID_OPCODE : Self = Self ( 5 ) ;
1919 /// Stack-Segment Fault
20- pub const EXCEPT_EBC_STACK_FAULT : ExceptionType = ExceptionType ( 6 ) ;
20+ pub const EXCEPT_EBC_STACK_FAULT : Self = Self ( 6 ) ;
2121 /// Alignment Check
22- pub const EXCEPT_EBC_ALIGNMENT_CHECK : ExceptionType = ExceptionType ( 7 ) ;
22+ pub const EXCEPT_EBC_ALIGNMENT_CHECK : Self = Self ( 7 ) ;
2323 /// Instruction Encoding Exception
24- pub const EXCEPT_EBC_INSTRUCTION_ENCODING : ExceptionType = ExceptionType ( 8 ) ;
24+ pub const EXCEPT_EBC_INSTRUCTION_ENCODING : Self = Self ( 8 ) ;
2525 /// Bad Breakpoint Exception
26- pub const EXCEPT_EBC_BAD_BREAK : ExceptionType = ExceptionType ( 9 ) ;
26+ pub const EXCEPT_EBC_BAD_BREAK : Self = Self ( 9 ) ;
2727 /// Single Step Exception
28- pub const EXCEPT_EBC_SINGLE_STEP : ExceptionType = ExceptionType ( 10 ) ;
28+ pub const EXCEPT_EBC_SINGLE_STEP : Self = Self ( 10 ) ;
2929}
3030
3131#[ cfg( target_arch = "x86" ) ]
@@ -69,39 +69,39 @@ impl ExceptionType {
6969#[ cfg( target_arch = "x86_64" ) ]
7070impl ExceptionType {
7171 /// Divide-by-zero Error
72- pub const EXCEPT_X64_DIVIDE_ERROR : ExceptionType = ExceptionType ( 0 ) ;
72+ pub const EXCEPT_X64_DIVIDE_ERROR : Self = Self ( 0 ) ;
7373 /// Debug Exception
74- pub const EXCEPT_X64_DEBUG : ExceptionType = ExceptionType ( 1 ) ;
74+ pub const EXCEPT_X64_DEBUG : Self = Self ( 1 ) ;
7575 /// Non-maskable Interrupt
76- pub const EXCEPT_X64_NMI : ExceptionType = ExceptionType ( 2 ) ;
76+ pub const EXCEPT_X64_NMI : Self = Self ( 2 ) ;
7777 /// Breakpoint
78- pub const EXCEPT_X64_BREAKPOINT : ExceptionType = ExceptionType ( 3 ) ;
78+ pub const EXCEPT_X64_BREAKPOINT : Self = Self ( 3 ) ;
7979 /// Overflow
80- pub const EXCEPT_X64_OVERFLOW : ExceptionType = ExceptionType ( 4 ) ;
80+ pub const EXCEPT_X64_OVERFLOW : Self = Self ( 4 ) ;
8181 /// Bound Range Exceeded
82- pub const EXCEPT_X64_BOUND : ExceptionType = ExceptionType ( 5 ) ;
82+ pub const EXCEPT_X64_BOUND : Self = Self ( 5 ) ;
8383 /// Invalid Opcode
84- pub const EXCEPT_X64_INVALID_OPCODE : ExceptionType = ExceptionType ( 6 ) ;
84+ pub const EXCEPT_X64_INVALID_OPCODE : Self = Self ( 6 ) ;
8585 /// Double Fault
86- pub const EXCEPT_X64_DOUBLE_FAULT : ExceptionType = ExceptionType ( 8 ) ;
86+ pub const EXCEPT_X64_DOUBLE_FAULT : Self = Self ( 8 ) ;
8787 /// Invalid TSS
88- pub const EXCEPT_X64_INVALID_TSS : ExceptionType = ExceptionType ( 10 ) ;
88+ pub const EXCEPT_X64_INVALID_TSS : Self = Self ( 10 ) ;
8989 /// Segment Not Present
90- pub const EXCEPT_X64_SEG_NOT_PRESENT : ExceptionType = ExceptionType ( 11 ) ;
90+ pub const EXCEPT_X64_SEG_NOT_PRESENT : Self = Self ( 11 ) ;
9191 /// Stack-Segment Fault
92- pub const EXCEPT_X64_STACK_FAULT : ExceptionType = ExceptionType ( 12 ) ;
92+ pub const EXCEPT_X64_STACK_FAULT : Self = Self ( 12 ) ;
9393 /// General Protection Fault
94- pub const EXCEPT_X64_GP_FAULT : ExceptionType = ExceptionType ( 13 ) ;
94+ pub const EXCEPT_X64_GP_FAULT : Self = Self ( 13 ) ;
9595 /// Page Fault
96- pub const EXCEPT_X64_PAGE_FAULT : ExceptionType = ExceptionType ( 14 ) ;
96+ pub const EXCEPT_X64_PAGE_FAULT : Self = Self ( 14 ) ;
9797 /// x87 Floating-Point Exception
98- pub const EXCEPT_X64_FP_ERROR : ExceptionType = ExceptionType ( 16 ) ;
98+ pub const EXCEPT_X64_FP_ERROR : Self = Self ( 16 ) ;
9999 /// Alignment Check
100- pub const EXCEPT_X64_ALIGNMENT_CHECK : ExceptionType = ExceptionType ( 17 ) ;
100+ pub const EXCEPT_X64_ALIGNMENT_CHECK : Self = Self ( 17 ) ;
101101 /// Machine Check
102- pub const EXCEPT_X64_MACHINE_CHECK : ExceptionType = ExceptionType ( 18 ) ;
102+ pub const EXCEPT_X64_MACHINE_CHECK : Self = Self ( 18 ) ;
103103 /// SIMD Floating-Point Exception
104- pub const EXCEPT_X64_SIMD : ExceptionType = ExceptionType ( 19 ) ;
104+ pub const EXCEPT_X64_SIMD : Self = Self ( 19 ) ;
105105}
106106
107107#[ cfg( target_arch = "arm" ) ]
0 commit comments