Added comma for index + step in slice#102
Conversation
|
@elrandira Sorry for the very long delay. If you're still interested in having this merged and you're able to update the PR, let me know! |
|
sure, I'll try in the next days. I am going to need to setup the environment again for this. |
|
This will conflict with a documented JSONPath syntax for selecting multiple indexes simultaneously: https://goessner.net/articles/JsonPath/index.html#e3 This PR should be closed to avoid introducing conflicting syntax. |
|
I think I misread this; my interpretation was that this was offering commas as an alternative to colons in slice syntax, but now that I've read the code that doesn't appear to be what's happening here. I recommend merging #145 first, which heavily parametrizes the test suite. It will make it easier to integrate the tests introduced here. |

This is my proposition to add comma in index such as in$..books[1,2] and step in slice such as in $ ..books[::-1] or $..books[0:3:2]
for the comma in index, the code is similar to handling of comma in fields. #28
For step in slice, all the code was already there, just needed to implement the rule... ¯_(ツ)_/¯
All tests passed + new ones