Re: dollar quoting
От | Andrew Dunstan |
---|---|
Тема | Re: dollar quoting |
Дата | |
Msg-id | 4025378F.9010307@dunslane.net обсуждение исходный текст |
Ответ на | Re: dollar quoting (Andrew Dunstan <andrew@dunslane.net>) |
Ответы |
Re: dollar quoting
|
Список | pgsql-hackers |
Andrew Dunstan wrote: > > > Tom Lane wrote: > >> >> I kinda thought you had volunteered to work on the psql part... >> >> >> > > > I don't recall being that specific, but you could be right. In any > case, I didn't want to trip over anyone else, which is why I asked. > > I will try to coordinate with Jon. > After staring at the code for a long time, I think I see how to do this. It's complicated a bit by the fact that $ is a valid identifier character. So my current thinking is to say that if we see $ not in a quote and not preceded by a valid identifier char then it is the start of a $foo$ sequence. Or have I missed something? Can we validly see $ in any other context? BTW, Tom's proof of concept patch worked just fine for me. I changed the allowed pattern to what I think was agreed: dolqdelim \$([A-Za-z\200-\377][A-Za-z\200-\377_0-9]*)?\$ and changed some names and comments to remove misleading references to "here docs". cheers andrew
В списке pgsql-hackers по дате отправления: