witty-crayon-22786
07/22/2020, 6:41 PMclass SS:
@memoized
@classmethod
def scoped_to(cls, name: str) -> Type["SS"]:
class AnonymousSub(SS):
pass
return AnonymousSub
witty-crayon-22786
07/22/2020, 6:42 PMwitty-crayon-22786
07/22/2020, 6:43 PMTarget.Fields
, and for the usecase on #9760.witty-crayon-22786
07/22/2020, 6:43 PMOptions
(afaik) because we wanted to preserve the subtype to be able to call methods on it and/or see which options were validwitty-crayon-22786
07/22/2020, 6:44 PMhundreds-father-404
07/22/2020, 6:44 PMTarget.Fields
? Like union fields?witty-crayon-22786
07/22/2020, 6:44 PMhundreds-father-404
07/22/2020, 6:45 PM.PluginField
, which John found is the same for every target typewitty-crayon-22786
07/22/2020, 6:46 PMwitty-crayon-22786
07/22/2020, 6:46 PMhundreds-father-404
07/22/2020, 6:47 PMAnonymousSub
subclasses the superclass. Is that necessary?witty-crayon-22786
07/22/2020, 6:51 PMwitty-crayon-22786
07/22/2020, 6:51 PMwitty-crayon-22786
07/22/2020, 6:51 PMSS
witty-crayon-22786
07/27/2020, 5:00 PMenough-analyst-54434
07/27/2020, 5:05 PM