FTR the issue is _quote_readline_by_ref expanding an empty var to '', see:
$ _quote_readline_by_ref '' foo $ echo $foo ''
Above MP adds a special case to avoid quoting if empty.
FTR the issue is _quote_ readline_ by_ref expanding an empty var to '', see:
$ _quote_ readline_ by_ref '' foo
$ echo $foo
''
Above MP adds a special case to avoid quoting if empty.