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
0e9980f7
Kaydet (Commit)
0e9980f7
authored
Eyl 12, 2004
tarafından
Tim Peters
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Whitespace normalization.
üst
2ee8099b
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
26 additions
and
26 deletions
+26
-26
ast.py
Lib/compiler/ast.py
+4
-4
transformer.py
Lib/compiler/transformer.py
+6
-6
bdist_rpm.py
Lib/distutils/command/bdist_rpm.py
+8
-8
test_compiler.py
Lib/test/test_compiler.py
+4
-4
test_re.py
Lib/test/test_re.py
+1
-1
astgen.py
Tools/compiler/astgen.py
+1
-1
msi.py
Tools/msi/msi.py
+2
-2
No files found.
Lib/compiler/ast.py
Dosyayı görüntüle @
0e9980f7
...
...
@@ -553,7 +553,7 @@ class Function(Node):
self
.
varargs
=
1
if
flags
&
CO_VARKEYWORDS
:
self
.
kwargs
=
1
def
getChildren
(
self
):
...
...
@@ -584,7 +584,7 @@ class GenExpr(Node):
self
.
lineno
=
lineno
self
.
argnames
=
[
'[outmost-iterable]'
]
self
.
varargs
=
self
.
kwargs
=
None
def
getChildren
(
self
):
...
...
@@ -763,7 +763,7 @@ class Lambda(Node):
self
.
varargs
=
1
if
flags
&
CO_VARKEYWORDS
:
self
.
kwargs
=
1
def
getChildren
(
self
):
...
...
@@ -1313,4 +1313,4 @@ class Yield(Node):
for
name
,
obj
in
globals
()
.
items
():
if
isinstance
(
obj
,
type
)
and
issubclass
(
obj
,
Node
):
nodes
[
name
.
lower
()]
=
obj
nodes
[
name
.
lower
()]
=
obj
Lib/compiler/transformer.py
Dosyayı görüntüle @
0e9980f7
...
...
@@ -79,7 +79,7 @@ def extractLineNo(ast):
lineno
=
extractLineNo
(
child
)
if
lineno
is
not
None
:
return
lineno
def
Node
(
*
args
):
kind
=
args
[
0
]
if
nodes
.
has_key
(
kind
):
...
...
@@ -127,7 +127,7 @@ class Transformer:
def
parsesuite
(
self
,
text
):
"""Return a modified parse tree for the given suite text."""
return
self
.
transform
(
parser
.
suite
(
text
))
def
parseexpr
(
self
,
text
):
"""Return a modified parse tree for the given expression text."""
return
self
.
transform
(
parser
.
expr
(
text
))
...
...
@@ -426,7 +426,7 @@ class Transformer:
def
import_name
(
self
,
nodelist
):
# import_name: 'import' dotted_as_names
return
Import
(
self
.
com_dotted_as_names
(
nodelist
[
1
]),
return
Import
(
self
.
com_dotted_as_names
(
nodelist
[
1
]),
lineno
=
nodelist
[
0
][
2
])
def
import_from
(
self
,
nodelist
):
...
...
@@ -514,7 +514,7 @@ class Transformer:
else
:
elseNode
=
None
return
For
(
assignNode
,
listNode
,
bodyNode
,
elseNode
,
return
For
(
assignNode
,
listNode
,
bodyNode
,
elseNode
,
lineno
=
nodelist
[
0
][
2
])
def
try_stmt
(
self
,
nodelist
):
...
...
@@ -887,7 +887,7 @@ class Transformer:
def
com_try_finally
(
self
,
nodelist
):
# try_fin_stmt: "try" ":" suite "finally" ":" suite
return
TryFinally
(
self
.
com_node
(
nodelist
[
2
]),
self
.
com_node
(
nodelist
[
5
]),
self
.
com_node
(
nodelist
[
5
]),
lineno
=
nodelist
[
0
][
2
])
def
com_try_except
(
self
,
nodelist
):
...
...
@@ -1226,7 +1226,7 @@ class Transformer:
subscripts
=
[]
for
i
in
range
(
1
,
len
(
nodelist
),
2
):
subscripts
.
append
(
self
.
com_subscript
(
nodelist
[
i
]))
return
Subscript
(
primary
,
assigning
,
subscripts
,
return
Subscript
(
primary
,
assigning
,
subscripts
,
lineno
=
extractLineNo
(
nodelist
))
def
com_subscript
(
self
,
node
):
...
...
Lib/distutils/command/bdist_rpm.py
Dosyayı görüntüle @
0e9980f7
...
...
@@ -97,24 +97,24 @@ class bdist_rpm (Command):
"RPM 2 compatibility mode"
),
# Add the hooks necessary for specifying custom scripts
(
'prep-script='
,
None
,
(
'prep-script='
,
None
,
"Specify a script for the PREP phase of RPM building"
),
(
'build-script='
,
None
,
(
'build-script='
,
None
,
"Specify a script for the BUILD phase of RPM building"
),
(
'pre-install='
,
None
,
(
'pre-install='
,
None
,
"Specify a script for the pre-INSTALL phase of RPM building"
),
(
'install-script='
,
None
,
(
'install-script='
,
None
,
"Specify a script for the INSTALL phase of RPM building"
),
(
'post-install='
,
None
,
(
'post-install='
,
None
,
"Specify a script for the post-INSTALL phase of RPM building"
),
(
'pre-uninstall='
,
None
,
(
'pre-uninstall='
,
None
,
"Specify a script for the pre-UNINSTALL phase of RPM building"
),
(
'post-uninstall='
,
None
,
(
'post-uninstall='
,
None
,
"Specify a script for the post-UNINSTALL phase of RPM building"
),
(
'clean-script='
,
None
,
(
'clean-script='
,
None
,
"Specify a script for the CLEAN phase of RPM building"
),
(
'verify-script='
,
None
,
...
...
Lib/test/test_compiler.py
Dosyayı görüntüle @
0e9980f7
...
...
@@ -50,9 +50,9 @@ class CompilerTest(unittest.TestCase):
def
_check_lineno
(
self
,
node
):
if
not
node
.
__class__
in
NOLINENO
:
self
.
assert_
(
isinstance
(
node
.
lineno
,
int
),
self
.
assert_
(
isinstance
(
node
.
lineno
,
int
),
"lineno=
%
s on
%
s"
%
(
node
.
lineno
,
node
.
__class__
))
self
.
assert_
(
node
.
lineno
>
0
,
self
.
assert_
(
node
.
lineno
>
0
,
"lineno=
%
s on
%
s"
%
(
node
.
lineno
,
node
.
__class__
))
for
child
in
node
.
getChildNodes
():
self
.
check_lineno
(
child
)
...
...
@@ -84,12 +84,12 @@ except:
yo
=
3
else
:
yo
+=
3
try
:
a
+=
b
finally
:
b
=
0
###############################################################################
def
test_main
():
...
...
Lib/test/test_re.py
Dosyayı görüntüle @
0e9980f7
...
...
@@ -104,7 +104,7 @@ class ReTests(unittest.TestCase):
self
.
assertEqual
(
re
.
sub
(
'x'
,
r'\400'
,
'x'
),
'
\0
'
)
self
.
assertEqual
(
re
.
sub
(
'x'
,
r'\777'
,
'x'
),
'
\377
'
)
self
.
assertRaises
(
re
.
error
,
re
.
sub
,
'x'
,
r'\1'
,
'x'
)
self
.
assertRaises
(
re
.
error
,
re
.
sub
,
'x'
,
r'\8'
,
'x'
)
self
.
assertRaises
(
re
.
error
,
re
.
sub
,
'x'
,
r'\9'
,
'x'
)
...
...
Tools/compiler/astgen.py
Dosyayı görüntüle @
0e9980f7
...
...
@@ -283,4 +283,4 @@ class Expression(Node):
### EPILOGUE
for
name
,
obj
in
globals
()
.
items
():
if
isinstance
(
obj
,
type
)
and
issubclass
(
obj
,
Node
):
nodes
[
name
.
lower
()]
=
obj
nodes
[
name
.
lower
()]
=
obj
Tools/msi/msi.py
Dosyayı görüntüle @
0e9980f7
...
...
@@ -320,7 +320,7 @@ def add_ui(db):
end if
if (ext_new=2 or tcl_new=2) and regtcl_old<>2 then
Session.ComponentRequestState("REGISTRY.tcl")=2
end if
end if
End Function
"""
)
# To add debug messages into scripts, the following fragment can be used
...
...
@@ -329,7 +329,7 @@ def add_ui(db):
# Session.message &H04000000, objRec
add_data
(
db
,
"Binary"
,
[(
"Script"
,
msilib
.
Binary
(
"inst.vbs"
))])
# See "Custom Action Type 6"
add_data
(
db
,
"CustomAction"
,
add_data
(
db
,
"CustomAction"
,
[(
"CheckDir"
,
6
,
"Script"
,
"CheckDir"
),
(
"UpdateEditIDLE"
,
6
,
"Script"
,
"UpdateEditIDLE"
)])
os
.
unlink
(
"inst.vbs"
)
...
...
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