Based on token
, find the rows in pd
that need to be indented.
compute_indent_indices(pd, token = "'('", indent_last = FALSE)
pd | A parse table. |
---|---|
token | A character vector with tokens. |
indent_last | Flag to indicate whether the last token in |
For example when token
is a parenthesis, the closing parenthesis does not
need indention, but if token is something else, for example a plus (+), the
last token in pd
needs indention.