Displaying 2 results from an estimated 2 matches for "literal1".
Did you mean:
literal+
2015 Jun 18
1
Improving string concatenation
...to eliminate the
possibility.
And of course, as someone else mentioned, it may instead be desirable
for attempts to add strings to signal an error, as at present, which
one also gives up by making "+" do concatenation.
> Yes, even Fortran has one, and in C, I can simply write "literal1"
> "literal2" and they'll be concatenated. It is only for literals, but
> still very useful.
Concatenation of literal strings could easily be added to the R parser
without changing anything else. (Getting them to deparse as the same
two pieces would be tricky, but is mayb...
2015 Jun 17
1
Improving string concatenation
Just to clarify, primitive (C-level) generics do not support dispatch
on basic classes (like character). This is for performance (no need to
consider dispatch on non-objects) and for sanity (in general,
redefining fundamental behaviors is dangerous). It is of course
possible to define a "+" method with a signature containing a class
not in the set of basic classes.
On Tue, Jun 16, 2015