8000 fix cspell warnings · RustPython/RustPython@42bb6ab · GitHub
[go: up one dir, main page]

Skip to content

Commit 42bb6ab

Browse files
committed
fix cspell warnings
1 parent 2c94b80 commit 42bb6ab

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+452
-280
lines changed

.cspell.dict/cpython.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,19 @@ cellarg
1010
cellvar
1111
cellvars
1212
cmpop
13+
weakreflist
14+
XXPRIME
1315
dictoffset
1416
elts
17+
xstat
1518
excepthandler
19+
fileutils
1620
finalbody
1721
freevar
1822
freevars
1923
fromlist
2024
heaptype
25+
HIGHRES
2126
IMMUTABLETYPE
2227
kwonlyarg
2328
kwonlyargs

.cspell.dict/python-more.txt

Lines changed: 103 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,79 +1,151 @@
1+
abiflags
12
abstractmethods
3+
aenter
4+
aexit
25
aiter
36
anext
7+
appendleft
8+
argcount
49
arrayiterator
510
arraytype
611
asend
12+
asyncgen
713
athrow
14+
backslashreplace
815
basicsize
16+
bdfl
17+
bigcharset
18+
breakpointhook
919
cformat
20+
chunksize
1021
classcell
22+
closefd
1123
closesocket
1224
codepoint
1325
codepoints
26+
contextvar
1427
cpython
28+
cratio
29+
dealloc
30+
debugbuild
1531
decompressor
1632
defaultaction
1733
descr
1834
dictcomp
1935
dictitems
2036
dictkeys
2137
dictview
38+
digestmod
39+
dllhandle
2240
docstring
2341
docstrings
2442
dunder
43+
endianness
44+
endpos
2545
eventmask
46+
excepthook
47+
exceptiongroup
48+
exitfuncs
49+
extendleft
50+
fastlocals
2651
fdel
52+
fedcba
2753
fget
2854
fileencoding
2955
fillchar
56+
fillvalue
3057
finallyhandler
58+
firstiter
59+
firstlineno
60+
fnctl
3161
frombytes
3262
fromhex
3363
fromunicode
3464
fset
3565
fspath
3666
fstring
3767
fstrings
68+
ftruncate
3869
genexpr
3970
getattro
71+
getcodesize
72+
getdefaultencoding
73+
getfilesystemencodeerrors
74+
getfilesystemencoding
4075
getformat
76+
getframe
4177
getnewargs
78+
getpip
79+
getrandom
80+
getrecursionlimit
81+
getrefcount
4282
getweakrefcount
4383
getweakrefs
84+
getwindowsversion
85+
gmtoff
86+
groupdict
87+
groupindex
88+
hamt
4489
hostnames
90+
idfunc
4591
idiv
4692
impls
93+
indexgroup
4794
infj
4895
instancecheck
4996
instanceof
97+
irepeat
5098
isabstractmethod
99+
isbytes
100+
iscased
101+
istext
51102
itemiterator
52103
itemsize
53104
iternext
105+
keepends
106+
keyfunc
54107
keyiterator
55108
kwarg
56109
kwargs
110+
kwdefaults
111+
kwonlyargcount
112+
lastgroup
57113
linearization
58114
linearize
59115
listcomp
116+
lvalue
60117
mappingproxy
118+
maskpri
119+
maxdigits
120+
MAXGROUPS
121+
MAXREPEAT
61122
maxsplit
123+
maxunicode
62124
memoryview
63125
memoryviewiterator
64126
metaclass
65127
metaclasses
66128
metatype
129+
mformat
67130
mro
68131
mros
132+
multiarch
133+
namereplace
69134
nanj
135+
nbytes
136+
ncallbacks
70137
ndigits
71138
ndim
139+
nlocals
72140
nonbytes
73141
origname
74142
posixsubprocess
143+
posonly
144+
posonlyargcount
145+
profilefunc
146+
pycodecs
147+
pycs
75148
pyexpat
76-
pytraverse
77149
PYTHONDEBUG
78150
PYTHONHOME
79151
PYTHONINSPECT
@@ -82,11 +154,19 @@ PYTHONPATH
82154
PYTHONPATH
83155
PYTHONVERBOSE
84156
PYTHONWARNINGS
157+
pytraverse
85158
qualname
159+
quotetabs
86160
radd
87161
rdiv
88162
rdivmod
163+
readall
164+
readbuffer
89165
reconstructor
166+
releaselevel
167+
reverseitemiterator
168+
reverseiterator
169+
reversekeyiterator
90170
reversevalueiterator
91171
rfloordiv
92172
rlshift
@@ -95,22 +175,42 @@ rpow
95175
rrshift
96176
rsub
97177
rtruediv
178+
rvalue
98179
scproxy
99180
setattro
100181
setcomp
101182
showwarnmsg
102-
warnmsg
183+
signum
184+
slotnames
103185
stacklevel
186+
stacksize
187+
startpos
104188
subclasscheck
105189
subclasshook
190+
suboffset
191+
sumprod
192+
surrogateescape
193+
surrogatepass
194+
sysconfigdata
195+
sysvars
196+
titlecased
197+
unimportable
106198
unionable
107199
unraisablehook
200+
unsliceable
201+
urandom
108202
valueiterator
109203
vararg
110204
varargs
111205
varnames
112206
warningregistry
207+
warnmsg
208+
warnoptions
113209
warnopts
114210
weakproxy
115211
winver
116-
xopts
212+
withdata
213+
xmlcharrefreplace
214+
xoptions
215+
xopts
216+
yieldfrom

.cspell.dict/rust-more.txt

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,45 +3,68 @@ bidi
33
biguint
44
bindgen
55
bitflags
6+
bitor
67
bstr
78
byteorder
9+
byteset
10+
caseless
811
chrono
912
consts
13+
cranelift
1014
cstring
15+
datelike
16+
deserializer
1117
flate2
1218
fract
19+
getres
1320
hasher
21+
hexf
22+
hexversion
1423
idents
24+
illumos
1525
indexmap
1626
insta
1727
keccak
1828
lalrpop
29+
lexopt
1930
libc
31+
libloading
2032
libz
2133
longlong
2234
Manually
2335
maplit
2436
memmap
37+
memmem
2538
metas
2639
modpow
40+
msvc
41+
muldiv
2742
nanos
2843
objclass
2944
peekable
3045
powc
3146
powf
3247
prepended
3348
punct
49+
puruspe
3450
replacen
3551
rsplitn
3652
rustc
3753
rustfmt
54+
rustyline
3855
seekfrom
56+
siphash
3957
splitn
4058
subsec
59+
thiserror
60+
timelike
4161
timsort
4262
trai
4363
ulonglong
4464
unic
4565
unistd
66+
unsync
67+
wasmbind
68+
widestring
4669
winapi
47-
winsock
70+
winsock

.cspell.json

Lines changed: 17 additions & 0 deletions
10000
Original file line numberDiff line numberDiff line change
@@ -47,16 +47,24 @@
4747
// words - list of words to be always considered correct
4848
"words": [
4949
// RustPython
50+
"aiterable",
51+
"alnum",
5052
"baseclass",
53+
"boxvec",
5154
"Bytecode",
5255
"cfgs",
5356
"codegen",
57+
"coro",
5458
"dedentations",
5559
"dedents",
5660
"deduped",
5761
"downcasted",
5862
"dumpable",
63+
"emscripten",
64+
"excs",
65+
"finalizer",
5966
"GetSet",
67+
"groupref",
6068
"internable",
6169
"makeunicodedata",
6270
"miri",
@@ -100,6 +108,15 @@
100108
"unraisable",
101109
"wasi",
102110
"zelf",
111+
// unix
112+
"CLOEXEC",
113+
"codeset",
114+
"endgrent",
115+
"getrusage",
116+
"nanosleep",
117+
"WRLCK",
118+
// win32
119+
"birthtime",
103120
],
104121
// flagWords - list of words to be always considered incorrect
105122
"flagWords": [

common/src/boxvec.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// cspell:ignore
12
//! An unresizable vector backed by a `Box<[T]>`
23
34
#![allow(clippy::needless_lifetimes)]

common/src/hash.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,14 @@ impl HashSecret {
5353
fix_sentinel(mod_int(self.hash_one(data) as _))
5454
}
5555

56-
pub fn hash_iter<'a, T: 'a, I, F, E>(&self, iter: I, hashf: F) -> Result<PyHash, E>
56+
pub fn hash_iter<'a, T: 'a, I, F, E>(&self, iter: I, hash_func: F) -> Result<PyHash, E>
5757
where
5858
I: IntoIterator<Item = &'a T>,
5959
F: Fn(&'a T) -> Result<PyHash, E>,
6060
{
6161
let mut hasher = self.build_hasher();
6262
for element in iter {
63-
let item_hash = hashf(element)?;
63+
let item_hash = hash_func(element)?;
6464
item_hash.hash(&mut hasher);
6565
}
6666
Ok(fix_sentinel(mod_int(hasher.finish() as PyHash)))

common/src/rc.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ use std::rc::Rc;
33
#[cfg(feature = "threading")]
44
use std::sync::Arc;
55

6-
// type aliases instead of newtypes because you can't do `fn method(self: PyRc<Self>)` with a
6+
// type aliases instead of new-types because you can't do `fn method(self: PyRc<Self>)` with a
77
// newtype; requires the arbitrary_self_types unstable feature
88

99
#[cfg(feature = "threading")]

common/src/static_cell.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ mod non_threading {
1313

1414
impl<T> StaticCell<T> {
1515
#[doc(hidden)]
16-
pub const fn _from_localkey(inner: &'static LocalKey<OnceCell<&'static T>>) -> Self {
16+
pub const fn _from_local_key(inner: &'static LocalKey<OnceCell<&'static T>>) -> Self {
1717
Self { inner }
1818
}
1919

@@ -58,7 +58,7 @@ mod non_threading {
5858
::std::thread_local! {
5959
$vis static $name: $crate::lock::OnceCell<&'static $t> = $crate::lock::OnceCell::new();
6060
}
61-
$crate::static_cell::StaticCell::_from_localkey(&$name)
61+
$crate::static_cell::StaticCell::_from_local_key(&$name)
6262
};)+
6363
};
6464
}

0 commit comments

Comments
 (0)
0