File tree Expand file tree Collapse file tree 1 file changed +0
-13
lines changed Expand file tree Collapse file tree 1 file changed +0
-13
lines changed Original file line number Diff line number Diff line change @@ -211,15 +211,6 @@ def __getitem__(self, item):
211
211
_ClassDecorator = _Callable [[type ], type ]
212
212
213
213
214
- def _annotate (** kwargs ) -> _ClassDecorator :
215
- def f (cls : type ) -> type :
216
- for k , v in kwargs .items ():
217
- setattr (cls , f"_{ k } " , v )
218
- return cls
219
-
220
- return f
221
-
222
-
223
214
boolean = "boolean"
224
215
int = "int"
225
216
string = "string"
@@ -298,10 +289,6 @@ def decorator(cls: type) -> _PropertyAnnotation:
298
289
for a in dir (cls ):
299
290
if a .startswith (_schema .inheritable_pragma_prefix ):
300
291
setattr (annotated_cls , a , getattr (cls , a ))
301
- for a , v in cls .__dict__ .items ():
302
- # transfer annotations
303
- if a .startswith ("_" ) and not a .startswith ("__" ) and a != "_pragmas" :
304
- setattr (annotated_cls , a , v )
305
292
for p , a in cls .__annotations__ .items ():
306
293
if p in annotated_cls .__annotations__ :
307
294
annotated_cls .__annotations__ [p ] |= a
You can’t perform that action at this time.
0 commit comments