Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upradare2-shell-parser: command substitution #15886
Open
Comments
This comment has been minimized.
This comment has been minimized.
|
I'm going to try 2. The reason I don't like 3 is because I think it makes sense for a cmd_substitution to generate more than one argument token. |
This comment has been minimized.
This comment has been minimized.
|
I think restricting them to just arguments->arguments substitution is good enough. I don't remember any case when I needed something more advanced (and if you need something more advanced - just use macroses or r2pipe). |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
A feature that still makes me think a lot is how we want to handle command substitution. I would like to have some feedback and thoughts about it, so that I can implement it in radare2-shell-parser, as the way we implement it will change a lot how the parser works.
Example:
p$(?e "d 10~xor")becomes =>pd 10~xorExample:
o $(?e "myfile 0x4000 rwx")is interpreted aso myfile 0x4000 rwx.Example:
o $(?e "myfile 0x4000 rwx")is interpreted aso "myfile 0x4000 rwx"(which would not work becauseoexpects 3 arguments.Example:
f $(?e "ciao @ 0xdeadbeef; f-") ciaois interpreted asf ciao @ 0xdeadbeef; f- ciaoOther ideas? Suggestions? What do you think is the clearest/best thing? Bash seems to use a sort of 1/2.