-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Shared: Add a qlpack with a parameterized module defining type-trackers. #11521
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
bb87931
to
d38b226
Compare
d38b226
to
27755d1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor comments, otherwise LGTM.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One final question.
@@ -753,7 +770,7 @@ module TypeTracking<TypeTrackingInput I> { | |||
* A node on a path that is reachable from a source. This is a pair of a | |||
* `Node` and a `TypeTracker`. | |||
*/ | |||
class PathNode extends TPathNode { | |||
class PathNodeFwd extends TPathNode { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we want to expose this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Otherwise I'll have to duplicate all its members. I thought a bit about coming up with a design that left this private, but this seemed the simplest.
There's still some followup work to be done here to allow a proper join-order in the call-graph-recursive case, but this should support the regular linear-recursive use-cases. (The interface has been prepared for this case mirroring the Ruby/Python setup.)
Note that for
TypeBackTracker.step
I've switched the meaning ofthis
andresult
to match the qldoc (keeping the existing order was simply too confusing). Since most use-cases are wrapped in the language-specificbacktrack
predicates then the switch should be easily adapted.