Closed albertZhangTJ closed 10 months ago
@mrigger Hi prof, above is a description of the idea mentioned today. I'll try to implement this within today (should be easy).
I started to wonder if this is a good idea since we are blurring the boundary between quantifier nodes and we need to access the same thing at in different ways (passing rp_id
as part of parameter list when calling schema node VS. referencing IP_ID()
function in ANTLR Action within quantifier nodes), which might be confusing to the user.
Since it will be even messier to adapt both methods within the same program, probably I shall open a new branch for this new implementation.
Implemented in DSQLancer-schema-list branch, but decided to be probably a bad idea. Will close for now.
Instead of the current "get-what-you-described" way for defining a list of identifiers, or more concretely something like this
We can instead define a list of identifiers as a single grammar rule, in something like this
And we can reuse the current slot for
iid
(iid
is the ID for used identifiers list) forrp_id
to pass the number of repetitions to the node at runtime to control the number of columns generated.Since in this case the schema node also does some work of the quantifier node, it needs access to repetition ID (same stuff as
RP_ID
defined in quantifier node, repetition lower and upper limit.This shall eliminate the need for Used Identifiers List since all the identifiers in this list are now generated in the same node in the AST.