Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
d22bb658
Kaydet (Commit)
d22bb658
authored
Eki 22, 2003
tarafından
Fred Drake
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Avoid confusing name for the 3rd argument to str.replace().
This closes SF bug #827260.
üst
f12f3242
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
libstdtypes.tex
Doc/lib/libstdtypes.tex
+3
-3
stringobject.c
Objects/stringobject.c
+3
-3
No files found.
Doc/lib/libstdtypes.tex
Dosyayı görüntüle @
d22bb658
...
...
@@ -563,7 +563,7 @@ Decodes the string using the codec registered for \var{encoding}.
may be given to set a different error handling scheme. The default is
\code
{
'strict'
}
, meaning that encoding errors raise
\exception
{
ValueError
}
. Other possible values are
\code
{
'ignore'
}
and
\code
{
replace'
}
.
\code
{
'
replace'
}
.
\versionadded
{
2.2
}
\end{methoddesc}
...
...
@@ -664,10 +664,10 @@ the string this method is called on.
\versionchanged
[Support for the \var{chars} argument]
{
2.2.2
}
\end{methoddesc}
\begin{methoddesc}
[string]
{
replace
}{
old, new
\optional
{
,
maxspli
t
}}
\begin{methoddesc}
[string]
{
replace
}{
old, new
\optional
{
,
coun
t
}}
Return a copy of the string with all occurrences of substring
\var
{
old
}
replaced by
\var
{
new
}
. If the optional argument
\var
{
maxsplit
}
is given, only the first
\var
{
maxspli
t
}
occurrences are
\var
{
count
}
is given, only the first
\var
{
coun
t
}
occurrences are
replaced.
\end{methoddesc}
...
...
Objects/stringobject.c
Dosyayı görüntüle @
d22bb658
...
...
@@ -2308,11 +2308,11 @@ mymemreplace(const char *str, int len, /* input string */
PyDoc_STRVAR
(
replace__doc__
,
"S.replace (old, new[,
maxspli
t]) -> string
\n
\
"S.replace (old, new[,
coun
t]) -> string
\n
\
\n
\
Return a copy of string S with all occurrences of substring
\n
\
old replaced by new. If the optional argument
maxspli
t is
\n
\
given, only the first
maxspli
t occurrences are replaced."
);
old replaced by new. If the optional argument
coun
t is
\n
\
given, only the first
coun
t occurrences are replaced."
);
static
PyObject
*
string_replace
(
PyStringObject
*
self
,
PyObject
*
args
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment