1
Fork 0

windows: Allow snake_case errors for now.

This commit is contained in:
Kevin Butler 2014-05-30 17:07:16 +01:00
parent 09fc34066b
commit 030b3a2499
15 changed files with 22 additions and 6 deletions

View file

@ -476,6 +476,7 @@ extern crate libc;
#[cfg(target_os = "win32", target_arch = "x86")] #[cfg(target_os = "win32", target_arch = "x86")]
#[link(name = "kernel32")] #[link(name = "kernel32")]
#[allow(non_snake_case_functions)]
extern "stdcall" { extern "stdcall" {
fn SetEnvironmentVariableA(n: *u8, v: *u8) -> libc::c_int; fn SetEnvironmentVariableA(n: *u8, v: *u8) -> libc::c_int;
} }

View file

@ -1,4 +1,4 @@
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT // Copyright 2012-2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at // file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT. // http://rust-lang.org/COPYRIGHT.
// //
@ -71,6 +71,7 @@
*/ */
#![allow(non_camel_case_types)] #![allow(non_camel_case_types)]
#![allow(non_snake_case_functions)]
#![allow(non_uppercase_statics)] #![allow(non_uppercase_statics)]
#![allow(missing_doc)] #![allow(missing_doc)]
#![allow(uppercase_variables)] #![allow(uppercase_variables)]

View file

@ -1,4 +1,4 @@
// Copyright 2013 The Rust Project Developers. See the COPYRIGHT // Copyright 2013-2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at // file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT. // http://rust-lang.org/COPYRIGHT.
// //
@ -21,6 +21,8 @@
//! play. The only dependencies of these modules are the normal system libraries //! play. The only dependencies of these modules are the normal system libraries
//! that you would find on the respective platform. //! that you would find on the respective platform.
#![allow(non_snake_case_functions)]
use libc::c_int; use libc::c_int;
use libc; use libc;
use std::c_str::CString; use std::c_str::CString;

View file

@ -141,6 +141,7 @@ mod imp {
static LOCKFILE_EXCLUSIVE_LOCK: libc::DWORD = 0x00000002; static LOCKFILE_EXCLUSIVE_LOCK: libc::DWORD = 0x00000002;
#[allow(non_snake_case_functions)]
extern "system" { extern "system" {
fn LockFileEx(hFile: libc::HANDLE, fn LockFileEx(hFile: libc::HANDLE,
dwFlags: libc::DWORD, dwFlags: libc::DWORD,

View file

@ -1,4 +1,4 @@
// Copyright 2012-2013 The Rust Project Developers. See the COPYRIGHT // Copyright 2012-2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at // file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT. // http://rust-lang.org/COPYRIGHT.
// //
@ -27,6 +27,7 @@
*/ */
#![allow(missing_doc)] #![allow(missing_doc)]
#![allow(non_snake_case_functions)]
use clone::Clone; use clone::Clone;
use container::Container; use container::Container;

View file

@ -1,4 +1,4 @@
// Copyright 2013 The Rust Project Developers. See the COPYRIGHT // Copyright 2013-2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at // file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT. // http://rust-lang.org/COPYRIGHT.
// //
@ -93,6 +93,7 @@ mod imp {
static CRYPT_VERIFYCONTEXT: DWORD = 0xF0000000; static CRYPT_VERIFYCONTEXT: DWORD = 0xF0000000;
static NTE_BAD_SIGNATURE: DWORD = 0x80090006; static NTE_BAD_SIGNATURE: DWORD = 0x80090006;
#[allow(non_snake_case_functions)]
extern "system" { extern "system" {
fn CryptAcquireContextA(phProv: *mut HCRYPTPROV, fn CryptAcquireContextA(phProv: *mut HCRYPTPROV,
pszContainer: LPCSTR, pszContainer: LPCSTR,

View file

@ -518,6 +518,7 @@ mod imp {
use unstable::mutex::{StaticNativeMutex, NATIVE_MUTEX_INIT}; use unstable::mutex::{StaticNativeMutex, NATIVE_MUTEX_INIT};
use slice::ImmutableVector; use slice::ImmutableVector;
#[allow(non_snake_case_functions)]
extern "system" { extern "system" {
fn GetCurrentProcess() -> libc::HANDLE; fn GetCurrentProcess() -> libc::HANDLE;
fn GetCurrentThread() -> libc::HANDLE; fn GetCurrentThread() -> libc::HANDLE;

View file

@ -11,6 +11,7 @@
//! Unwind library interface //! Unwind library interface
#![allow(non_camel_case_types)] #![allow(non_camel_case_types)]
#![allow(non_snake_case_functions)]
#![allow(dead_code)] // these are just bindings #![allow(dead_code)] // these are just bindings
use libc; use libc;

View file

@ -199,6 +199,7 @@ mod imp {
SwitchToThread(); SwitchToThread();
} }
#[allow(non_snake_case_functions)]
extern "system" { extern "system" {
fn CreateThread(lpThreadAttributes: LPSECURITY_ATTRIBUTES, fn CreateThread(lpThreadAttributes: LPSECURITY_ATTRIBUTES,
dwStackSize: SIZE_T, dwStackSize: SIZE_T,

View file

@ -1,4 +1,4 @@
// Copyright 2013 The Rust Project Developers. See the COPYRIGHT // Copyright 2013-2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at // file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT. // http://rust-lang.org/COPYRIGHT.
// //
@ -86,6 +86,7 @@ pub unsafe fn destroy(key: Key) {
} }
#[cfg(windows)] #[cfg(windows)]
#[allow(non_snake_case_functions)]
extern "system" { extern "system" {
fn TlsAlloc() -> DWORD; fn TlsAlloc() -> DWORD;
fn TlsFree(dwTlsIndex: DWORD) -> BOOL; fn TlsFree(dwTlsIndex: DWORD) -> BOOL;

View file

@ -1,4 +1,4 @@
// Copyright 2013 The Rust Project Developers. See the COPYRIGHT // Copyright 2013-2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at // file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT. // http://rust-lang.org/COPYRIGHT.
// //
@ -317,6 +317,7 @@ pub mod dl {
FreeLibrary(handle as *libc::c_void); () FreeLibrary(handle as *libc::c_void); ()
} }
#[allow(non_snake_case_functions)]
extern "system" { extern "system" {
fn SetLastError(error: libc::size_t); fn SetLastError(error: libc::size_t);
fn LoadLibraryW(name: *libc::c_void) -> *libc::c_void; fn LoadLibraryW(name: *libc::c_void) -> *libc::c_void;

View file

@ -543,6 +543,7 @@ mod imp {
libc::CloseHandle(block); libc::CloseHandle(block);
} }
#[allow(non_snake_case_functions)]
extern "system" { extern "system" {
fn CreateEventA(lpSecurityAttributes: LPSECURITY_ATTRIBUTES, fn CreateEventA(lpSecurityAttributes: LPSECURITY_ATTRIBUTES,
bManualReset: BOOL, bManualReset: BOOL,

View file

@ -27,6 +27,7 @@ pub struct WinConsole<T> {
background: color::Color, background: color::Color,
} }
#[allow(non_snake_case_functions)]
#[link(name = "kernel32")] #[link(name = "kernel32")]
extern "system" { extern "system" {
fn SetConsoleTextAttribute(handle: libc::HANDLE, attr: libc::WORD) -> libc::BOOL; fn SetConsoleTextAttribute(handle: libc::HANDLE, attr: libc::WORD) -> libc::BOOL;

View file

@ -9,6 +9,7 @@
// except according to those terms. // except according to those terms.
#![feature(phase)] #![feature(phase)]
#![allow(non_snake_case_functions)]
#[phase(syntax)] extern crate green; #[phase(syntax)] extern crate green;
extern crate sync; extern crate sync;

View file

@ -11,6 +11,7 @@
// ignore-pretty very bad with line comments // ignore-pretty very bad with line comments
#![feature(managed_boxes)] #![feature(managed_boxes)]
#![allow(non_snake_case_functions)]
use std::io; use std::io;
use std::io::stdio::StdReader; use std::io::stdio::StdReader;