Update vendored windows libs

This commit is contained in:
Labrys of Knossos 2022-11-28 05:59:32 -05:00
parent f61c211655
commit b1cefa94e5
226 changed files with 33472 additions and 11882 deletions

27
libs/win/path/classes.py Normal file
View file

@ -0,0 +1,27 @@
import functools
class ClassProperty(property):
def __get__(self, cls, owner):
return self.fget.__get__(None, owner)()
class multimethod:
"""
Acts like a classmethod when invoked from the class and like an
instancemethod when invoked from the instance.
"""
def __init__(self, func):
self.func = func
def __get__(self, instance, owner):
"""
If called on an instance, pass the instance as the first
argument.
"""
return (
functools.partial(self.func, owner)
if instance is None
else functools.partial(self.func, owner, instance)
)