Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
e81f5ef1
Commit
e81f5ef1
authored
May 27, 2008
by
Georg Brandl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove __metaclass__ remains.
parent
76262356
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
11 additions
and
13 deletions
+11
-13
Demo/newmetaclasses/Eiffel.py
Demo/newmetaclasses/Eiffel.py
+2
-2
Demo/newmetaclasses/Enum.py
Demo/newmetaclasses/Enum.py
+4
-4
Lib/test/test_descr.py
Lib/test/test_descr.py
+1
-1
Parser/asdl.py
Parser/asdl.py
+0
-2
Tools/framer/framer/bases.py
Tools/framer/framer/bases.py
+4
-4
No files found.
Demo/newmetaclasses/Eiffel.py
View file @
e81f5ef1
...
...
@@ -85,8 +85,8 @@ class EiffelMetaClass2(EiffelBaseMetaClass):
make_eiffel_method
=
EiffelDescriptor
def
_test
(
metaclass
):
class
Eiffel
:
__metaclass__
=
metacl
ass
class
Eiffel
(
metaclass
=
metaclass
)
:
p
ass
class
Test
(
Eiffel
):
...
...
Demo/newmetaclasses/Enum.py
View file @
e81f5ef1
...
...
@@ -82,11 +82,11 @@ class EnumInstance(int):
def
__str__
(
self
):
return
"%s.%s"
%
(
self
.
__classname
,
self
.
__enumname
)
class
Enum
:
__metaclass__
=
EnumMetacl
ass
class
Enum
(
metaclass
=
EnumMetaclass
)
:
p
ass
class
FullEnum
:
__metaclass__
=
FullEnumMetacl
ass
class
FullEnum
(
metaclass
=
FullEnumMetaclass
)
:
p
ass
def
_test
():
...
...
Lib/test/test_descr.py
View file @
e81f5ef1
...
...
@@ -440,7 +440,7 @@ class ClassPropertiesAndMethods(unittest.TestCase):
self
.
assertEqual
(
a
[
100
:
200
],
(
100
,
200
))
def
test_metaclass
(
self
):
# Testing
__metaclass__
...
# Testing
metaclasses
...
class
C
(
metaclass
=
type
):
def
__init__
(
self
):
self
.
__state
=
0
...
...
Parser/asdl.py
View file @
e81f5ef1
...
...
@@ -10,8 +10,6 @@ browser.
Changes for Python: Add support for module versions
"""
#__metaclass__ = type
import
os
import
sys
import
traceback
...
...
Tools/framer/framer/bases.py
View file @
e81f5ef1
...
...
@@ -96,8 +96,8 @@ class ModuleMetaclass(BaseMetaclass):
p
(
"}"
)
class
Module
:
__metaclass__
=
ModuleMetacl
ass
class
Module
(
metaclass
=
ModuleMetaclass
)
:
p
ass
class
TypeMetaclass
(
BaseMetaclass
):
...
...
@@ -211,5 +211,5 @@ class TypeMetaclass(BaseMetaclass):
p
(
template
.
type_init_type
)
p
(
template
.
module_add_type
)
class
Type
:
__metaclass__
=
TypeMetacl
ass
class
Type
(
metaclass
=
TypeMetaclass
)
:
p
ass
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