diff options
| author | Manish Goregaokar <manishsmail@gmail.com> | 2015-03-03 14:12:53 +0530 |
|---|---|---|
| committer | Manish Goregaokar <manishsmail@gmail.com> | 2015-03-03 17:02:20 +0530 |
| commit | 393ce1820e3f639b43d6058d2681b9757123ac1b (patch) | |
| tree | e11d524210057e8829cf69ecd199b6e7166a6e56 /src/libstd/sys | |
| parent | d0fcb1f53c9f81fbcae5379dd1c0577a8605172c (diff) | |
| parent | f35f973cb700c444d8c029ee13b37dc16d560225 (diff) | |
Rollup merge of #22876 - Florob:const, r=nikomatsakis
This changes the type of some public constants/statics in libunicode. Notably some `&'static &'static [(char, char)]` have changed to `&'static [(char, char)]`. The regexp crate seems to be the sole user of these, yet this is technically a [breaking-change]
Diffstat (limited to 'src/libstd/sys')
| -rw-r--r-- | src/libstd/sys/common/wtf8.rs | 2 | ||||
| -rw-r--r-- | src/libstd/sys/windows/os.rs | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/libstd/sys/common/wtf8.rs b/src/libstd/sys/common/wtf8.rs index bea2b6c6b40..31bdaee1e34 100644 --- a/src/libstd/sys/common/wtf8.rs +++ b/src/libstd/sys/common/wtf8.rs @@ -43,7 +43,7 @@ use sys_common::AsInner; use unicode::str::{Utf16Item, utf16_items}; use vec::Vec; -static UTF8_REPLACEMENT_CHARACTER: &'static [u8] = b"\xEF\xBF\xBD"; +const UTF8_REPLACEMENT_CHARACTER: &'static [u8] = b"\xEF\xBF\xBD"; /// A Unicode code point: from U+0000 to U+10FFFF. /// diff --git a/src/libstd/sys/windows/os.rs b/src/libstd/sys/windows/os.rs index 587ab7924fd..89cf8a08a68 100644 --- a/src/libstd/sys/windows/os.rs +++ b/src/libstd/sys/windows/os.rs @@ -59,8 +59,8 @@ pub fn error_string(errnum: i32) -> String { -> DWORD; } - static FORMAT_MESSAGE_FROM_SYSTEM: DWORD = 0x00001000; - static FORMAT_MESSAGE_IGNORE_INSERTS: DWORD = 0x00000200; + const FORMAT_MESSAGE_FROM_SYSTEM: DWORD = 0x00001000; + const FORMAT_MESSAGE_IGNORE_INSERTS: DWORD = 0x00000200; // This value is calculated from the macro // MAKELANGID(LANG_SYSTEM_DEFAULT, SUBLANG_SYS_DEFAULT) |
