about summary refs log tree commit diff
path: root/src/libstd/sys/windows/stack_overflow.rs
diff options
context:
space:
mode:
authorEli Friedman <eli.friedman@gmail.com>2015-06-25 14:48:36 -0700
committerEli Friedman <eli.friedman@gmail.com>2015-07-23 17:03:04 -0700
commit6fa17b43d351ed4f9093cf80f4044d1208044241 (patch)
tree7b83ba2d846643e167815d8990a458764adebc48 /src/libstd/sys/windows/stack_overflow.rs
parentd4d4206e5604b86fc4a9b28a8b51d99121cc3a5d (diff)
downloadrust-6fa17b43d351ed4f9093cf80f4044d1208044241.tar.gz
rust-6fa17b43d351ed4f9093cf80f4044d1208044241.zip
Rewrite the improper_ctypes lint.
Makes the lint a bit more accurate, and improves the quality of the diagnostic
messages by explicitly returning an error message.

The new lint is also a little more aggressive: specifically, it now
rejects tuples, and it recurses into function pointers.
Diffstat (limited to 'src/libstd/sys/windows/stack_overflow.rs')
-rw-r--r--src/libstd/sys/windows/stack_overflow.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libstd/sys/windows/stack_overflow.rs b/src/libstd/sys/windows/stack_overflow.rs
index cf827848db5..491b53c4ed9 100644
--- a/src/libstd/sys/windows/stack_overflow.rs
+++ b/src/libstd/sys/windows/stack_overflow.rs
@@ -82,6 +82,7 @@ pub unsafe fn make_handler() -> Handler {
     Handler { _data: 0 as *mut libc::c_void }
 }
 
+#[repr(C)]
 pub struct EXCEPTION_RECORD {
     pub ExceptionCode: DWORD,
     pub ExceptionFlags: DWORD,
@@ -91,6 +92,7 @@ pub struct EXCEPTION_RECORD {
     pub ExceptionInformation: [LPVOID; EXCEPTION_MAXIMUM_PARAMETERS]
 }
 
+#[repr(C)]
 pub struct EXCEPTION_POINTERS {
     pub ExceptionRecord: *mut EXCEPTION_RECORD,
     pub ContextRecord: LPVOID