Add Requirement.clone()

This commit is contained in:
allegroai 2020-10-11 11:21:49 +03:00
parent 15f4aa613e
commit 6f078afafd

View File

@ -4,7 +4,7 @@ import operator
import os
import re
from abc import ABCMeta, abstractmethod
from copy import deepcopy
from copy import deepcopy, copy
from itertools import chain, starmap
from operator import itemgetter
from os import path
@ -81,6 +81,9 @@ class MarkerRequirement(object):
return ''.join(parts)
def clone(self):
return MarkerRequirement(copy(self.req))
__str__ = tostr
def __repr__(self):