Skip to content

Commit 76128c3

Browse files
committed
Update unicode scripts for the current coding style
1 parent 71f9384 commit 76128c3

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/libcore/unicode/printable.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -111,17 +111,17 @@ def compress_normal(normal):
111111
return compressed
112112

113113
def print_singletons(uppers, lowers, uppersname, lowersname):
114-
print("const {}: &'static [(u8, u8)] = &[".format(uppersname))
114+
print("const {}: &[(u8, u8)] = &[".format(uppersname))
115115
for u, c in uppers:
116116
print(" ({:#04x}, {}),".format(u, c))
117117
print("];")
118-
print("const {}: &'static [u8] = &[".format(lowersname))
118+
print("const {}: &[u8] = &[".format(lowersname))
119119
for i in range(0, len(lowers), 8):
120120
print(" {}".format(" ".join("{:#04x},".format(l) for l in lowers[i:i+8])))
121121
print("];")
122122

123123
def print_normal(normal, normalname):
124-
print("const {}: &'static [u8] = &[".format(normalname))
124+
print("const {}: &[u8] = &[".format(normalname))
125125
for v in normal:
126126
print(" {}".format(" ".join("{:#04x},".format(i) for i in v)))
127127
print("];")

src/libcore/unicode/unicode.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,8 @@ class UnicodeFiles(object):
8181
8282
#![allow(missing_docs, non_upper_case_globals, non_snake_case)]
8383
84-
use unicode::version::UnicodeVersion;
85-
use unicode::bool_trie::{{BoolTrie, SmallBoolTrie}};
84+
use crate::unicode::version::UnicodeVersion;
85+
use crate::unicode::bool_trie::{{BoolTrie, SmallBoolTrie}};
8686
""".format(year=datetime.datetime.now().year)
8787

8888
# Mapping taken from Table 12 from:

0 commit comments

Comments
 (0)