On Thu, 28 Sep 2006, Prof Brian Ripley wrote:
> I don't understand why \` is regarded as intentional. It crops up in
> packages date and survival (the same code) in
>
> stop(paste("\`", .Generic, "' not meaningful for dates",
> sep = ""))
>
> which clearly should use s
On Thu, 28 Sep 2006, Peter Dalgaard wrote:
> "Gabor Grothendieck" <[EMAIL PROTECTED]> writes:
>
>> That's a good idea for the case I mentioned although there is still
>> the case where one requires a single quoted string (maybe for
>> generating code for some other language) and that is
>> not han
"Gabor Grothendieck" <[EMAIL PROTECTED]> writes:
> That's a good idea for the case I mentioned although there is still
> the case where one requires a single quoted string (maybe for
> generating code for some other language) and that is
> not handled by deparse.
Yes, but there be devils lurking
On 28 Sep 2006 16:33:17 +0200, Peter Dalgaard <[EMAIL PROTECTED]> wrote:
> "Gabor Grothendieck" <[EMAIL PROTECTED]> writes:
>
> > One area where a problem might appear is if one is
> > generating R code, e.g.
> >
> > paste("a <-", dQuote("xyz")) # wrong!
> >
> > since in UTF-8 dQuote (and sQuot
"Gabor Grothendieck" <[EMAIL PROTECTED]> writes:
> One area where a problem might appear is if one is
> generating R code, e.g.
>
> paste("a <-", dQuote("xyz")) # wrong!
>
> since in UTF-8 dQuote (and sQuote) do not necessarily
> generate double quotes (and single quotes) so one winds
> up u
One area where a problem might appear is if one is
generating R code, e.g.
paste("a <-", dQuote("xyz")) # wrong!
since in UTF-8 dQuote (and sQuote) do not necessarily
generate double quotes (and single quotes) so one winds
up using double quotes within single quotes or else
backslash-protecte
Thanks, Bill, that is helpful.
I've been running a prototype across R itself and CRAN. It is clear that
we do have lots of strings with escaped newlines (the escape is generated
in the parser if there is an embedded newline) so they need to be an
exception. On my first version 99 CRAN package
> > Splus's parser emits a warning when it sees a backslash
> > outside of the recognized backslash sequence. E.g.,
> >
> > > nchar("\Backslashed?")
> > [1] 12
> > Warning messages:
> >The initial backslash is ignored in \B -- not a recognized escape
> > sequence.
> > Use \\ to ma
On Tue, 26 Sep 2006, Bill Dunlap wrote:
> On Mon, 25 Sep 2006 [EMAIL PROTECTED] wrote:
>
>> On Mon, 25 Sep 2006, [EMAIL PROTECTED] wrote:
>> ...
>>> sprintf("\p") doesn't show the backslash, this occurs with all strings that
>>> start with certain letters. There is however no explanation to this