Closed hedhyw closed 2 years ago
Now, we can pass anything to rex.Common.Class, not rex.Common.NotClass. We need a way to restrict it.
rex.Common.Class
rex.Common.NotClass
Create an abstraction:
type ClassToken interface { Token Unwrap() Token // .... }
Make Raw as a ClassToken?
Raw
ClassToken
Now, we can pass anything to
rex.Common.Class
, notrex.Common.NotClass
. We need a way to restrict it.Idea
Create an abstraction:
Make
Raw
as aClassToken
?