mirror of
https://github.com/python/cpython
synced 2026-09-29 12:10:30 +03:00
Revert "bpo-38659: [Enum] add _simple_enum decorator (GH-25285)" (GH-25476)
This reverts commit dbac8f40e8.
This commit is contained in:
parent
dbac8f40e8
commit
503cdc7c12
20 changed files with 34 additions and 871 deletions
|
|
@ -26,15 +26,14 @@ import time
|
|||
import marshal
|
||||
import re
|
||||
|
||||
from enum import StrEnum, _simple_enum
|
||||
from enum import Enum
|
||||
from functools import cmp_to_key
|
||||
from dataclasses import dataclass
|
||||
from typing import Dict
|
||||
|
||||
__all__ = ["Stats", "SortKey", "FunctionProfile", "StatsProfile"]
|
||||
|
||||
@_simple_enum(StrEnum)
|
||||
class SortKey:
|
||||
class SortKey(str, Enum):
|
||||
CALLS = 'calls', 'ncalls'
|
||||
CUMULATIVE = 'cumulative', 'cumtime'
|
||||
FILENAME = 'filename', 'module'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue