Hmm. OTOH that "argument shift" is exactly what happens with shell too:

```
[pmatilai@sopuli ~]$ cat argtest.sh 
function foo()
{
    echo 1:$1 2:$2
}

foo $none bar
[pmatilai@sopuli ~]$ sh argtest.sh 
1:bar 2:
```

Difference of course being that shell has a quoting mechanism. So maybe the 
saner thing is reverting expand-after-split afterall and supporting quotes 
around arguments instead, to permit empty arguments where necessary. Should be 
easy to arrange by using poptParseArgvString() instead of argvSplit(). And sure 
it's going to break something else in turn, but *something* is going to break 
no matter what, and behaving similar to shell seems like the path of least 
surprises.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/217#issuecomment-303306045
_______________________________________________
Rpm-maint mailing list
Rpm-maint@lists.rpm.org
http://lists.rpm.org/mailman/listinfo/rpm-maint

Reply via email to