From 5b89877dda5b8267f1ec35dfc9bb6ddc4472f006 Mon Sep 17 00:00:00 2001 From: Mazdak Farrokhzad Date: Tue, 23 Oct 2018 02:04:14 +0200 Subject: constify parts of libcore. --- src/libcore/unicode/bool_trie.rs | 2 +- src/libcore/unicode/tables.rs | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) (limited to 'src/libcore/unicode') diff --git a/src/libcore/unicode/bool_trie.rs b/src/libcore/unicode/bool_trie.rs index 0e6437fded5..995795839b7 100644 --- a/src/libcore/unicode/bool_trie.rs +++ b/src/libcore/unicode/bool_trie.rs @@ -71,6 +71,6 @@ impl SmallBoolTrie { } } -fn trie_range_leaf(c: u32, bitmap_chunk: u64) -> bool { +const fn trie_range_leaf(c: u32, bitmap_chunk: u64) -> bool { ((bitmap_chunk >> (c & 63)) & 1) != 0 } diff --git a/src/libcore/unicode/tables.rs b/src/libcore/unicode/tables.rs index 3de855ac943..e525c057400 100644 --- a/src/libcore/unicode/tables.rs +++ b/src/libcore/unicode/tables.rs @@ -2598,4 +2598,3 @@ pub mod conversions { ]; } - -- cgit 1.4.1-3-g733a5