Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit aa9a205

Browse files
github-actions[bot]mattwang44
authored andcommitted
sync with cpython d2a8d571
1 parent 050a372 commit aa9a205

File tree

4 files changed

+263
-146
lines changed

4 files changed

+263
-146
lines changed

library/fnmatch.po

Lines changed: 25 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ msgid ""
77
msgstr ""
88
"Project-Id-Version: Python 3.13\n"
99
"Report-Msgid-Bugs-To: \n"
10-
"POT-Creation-Date: 2024-09-03 11:11+0800\n"
10+
"POT-Creation-Date: 2025-01-15 00:13+0000\n"
1111
"PO-Revision-Date: 2018-05-23 16:02+0000\n"
1212
"Last-Translator: Adrian Liaw <[email protected]>\n"
1313
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
@@ -90,12 +90,20 @@ msgstr ""
9090

9191
#: ../../library/fnmatch.rst:49
9292
msgid ""
93-
"Also note that :func:`functools.lru_cache` with the *maxsize* of 32768 is "
94-
"used to cache the compiled regex patterns in the following functions: :func:"
95-
"`fnmatch`, :func:`fnmatchcase`, :func:`.filter`."
93+
"Unless stated otherwise, \"filename string\" and \"pattern string\" either "
94+
"refer to :class:`str` or ``ISO-8859-1`` encoded :class:`bytes` objects. Note "
95+
"that the functions documented below do not allow to mix a :class:`!bytes` "
96+
"pattern with a :class:`!str` filename, and vice-versa."
9697
msgstr ""
9798

98-
#: ../../library/fnmatch.rst:55
99+
#: ../../library/fnmatch.rst:54
100+
msgid ""
101+
"Finally, note that :func:`functools.lru_cache` with a *maxsize* of 32768 is "
102+
"used to cache the (typed) compiled regex patterns in the following "
103+
"functions: :func:`fnmatch`, :func:`fnmatchcase`, :func:`.filter`."
104+
msgstr ""
105+
106+
#: ../../library/fnmatch.rst:61
99107
msgid ""
100108
"Test whether the filename string *name* matches the pattern string *pat*, "
101109
"returning ``True`` or ``False``. Both parameters are case-normalized using :"
@@ -104,13 +112,13 @@ msgid ""
104112
"operating system."
105113
msgstr ""
106114

107-
#: ../../library/fnmatch.rst:61
115+
#: ../../library/fnmatch.rst:67
108116
msgid ""
109117
"This example will print all file names in the current directory with the "
110118
"extension ``.txt``::"
111119
msgstr ""
112120

113-
#: ../../library/fnmatch.rst:64
121+
#: ../../library/fnmatch.rst:70
114122
msgid ""
115123
"import fnmatch\n"
116124
"import os\n"
@@ -126,35 +134,35 @@ msgstr ""
126134
" if fnmatch.fnmatch(file, '*.txt'):\n"
127135
" print(file)"
128136

129-
#: ../../library/fnmatch.rst:74
137+
#: ../../library/fnmatch.rst:80
130138
msgid ""
131139
"Test whether the filename string *name* matches the pattern string *pat*, "
132140
"returning ``True`` or ``False``; the comparison is case-sensitive and does "
133141
"not apply :func:`os.path.normcase`."
134142
msgstr ""
135143

136-
#: ../../library/fnmatch.rst:81
144+
#: ../../library/fnmatch.rst:87
137145
msgid ""
138-
"Construct a list from those elements of the :term:`iterable` *names* that "
139-
"match pattern *pat*. It is the same as ``[n for n in names if fnmatch(n, "
140-
"pat)]``, but implemented more efficiently."
146+
"Construct a list from those elements of the :term:`iterable` of filename "
147+
"strings *names* that match the pattern string *pat*. It is the same as ``[n "
148+
"for n in names if fnmatch(n, pat)]``, but implemented more efficiently."
141149
msgstr ""
142150

143-
#: ../../library/fnmatch.rst:89
151+
#: ../../library/fnmatch.rst:95
144152
msgid ""
145153
"Return the shell-style pattern *pat* converted to a regular expression for "
146-
"using with :func:`re.match`."
154+
"using with :func:`re.match`. The pattern is expected to be a :class:`str`."
147155
msgstr ""
148156

149-
#: ../../library/fnmatch.rst:92
157+
#: ../../library/fnmatch.rst:98
150158
msgid "Example:"
151159
msgstr "範例:"
152160

153-
#: ../../library/fnmatch.rst:106
161+
#: ../../library/fnmatch.rst:112
154162
msgid "Module :mod:`glob`"
155163
msgstr ":mod:`glob` 模組"
156164

157-
#: ../../library/fnmatch.rst:107
165+
#: ../../library/fnmatch.rst:113
158166
msgid "Unix shell-style path expansion."
159167
msgstr ""
160168

0 commit comments

Comments
 (0)