search for: syntactics

Displaying 20 results from an estimated 1185 matches for "syntactics".

Did you mean: syntactic
2011 Jun 30
2
Syntactically valid names
Hi all, Is there any easy way to tell if a string is a syntactically valid name? e.g. is.syntactic("X123") # TRUE is.syntactic("[[") # FALSE One implementation would be: is.syntactic <- function(x) x == make.names(x) but I wonder if there's a more elegant way. Thanks! Hadley -- Assistant Professor / Dobelman Family Junior Chair Department of Statistics / Rice
2017 Sep 03
0
[FORGED] Re: Block comment?
On 02/09/2017 6:57 PM, Rolf Turner wrote: > On 03/09/17 03:56, William Dunlap via R-help wrote: >> Is the reason you want a block comment containing code (as opposed to >> arbitrary text) that you want to be able to easily run the commented out >> code? If so the 'if()' construct has the advantage that you only need to >> change code at the start of the comment,
2017 Sep 03
2
[FORGED] Re: Block comment?
On 03/09/17 12:29, Duncan Murdoch wrote: > On 02/09/2017 6:57 PM, Rolf Turner wrote: >> On 03/09/17 03:56, William Dunlap via R-help wrote: >>> Is the reason you want a block comment containing code (as opposed to >>> arbitrary text) that you want to be able to easily run the commented out >>> code? If so the 'if()' construct has the advantage that you
2017 Mar 23
0
[Bug 1137] New: Element "flow tables" should not be syntactically unique...
https://bugzilla.netfilter.org/show_bug.cgi?id=1137 Bug ID: 1137 Summary: Element "flow tables" should not be syntactically unique... Product: nftables Version: unspecified Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 Component:
2008 Jan 19
5
"should_not ==" vs "should !="
describe "should_not == vs. should !=" it do 5.should_not == 6 end # passes it do 5.should != 6 end # fails end # I''m running the rspec 1.1.2 gem with the corresponding Textmate bundle # The second failure surprises me. # Is != not supported? # I''d like to hear what you all think. -------------- next part -------------- An HTML attachment was
2004 May 09
0
[LLVMdev] Testing LLVM on OS X
On Tue, 4 May 2004, Chris Lattner wrote: > On Tue, 4 May 2004, Chris Lattner wrote: > > I suspect that a large reason that LLVM does worst than a native C > > compiler with the CBE+GCC is that LLVM generates very low-level C code, > > and I'm not convinced that GCC is doing a very good job (ie, without > > syntactic loops). > > Yup, this is EXACTLY what is
2017 Sep 02
2
[FORGED] Re: Block comment?
On 03/09/17 03:56, William Dunlap via R-help wrote: > Is the reason you want a block comment containing code (as opposed to > arbitrary text) that you want to be able to easily run the commented out > code? If so the 'if()' construct has the advantage that you only need to > change code at the start of the comment, not at both ends. > > The if(FALSE) could be
2023 Mar 01
1
tab-complete for non-syntactic names could attempt backtick-wrapping
Consider: x <- list(`a b` = 1) x$a<tab> (i.e., press the 'tab' key after typing 'x$a') The auto-complete mechanism will fill the buffer like so: x$a b This is not particularly helpful because this is now a syntax error. It seems to me there's a simple fix -- in utils:::specialCompletions(), we can wrap the result of utils:::specialOpCompletionsHelper() with
2003 Nov 16
3
?for
I have always been intrigued by why ?for (or ?if,?while,etc) leave R wanting for more: > ?for + I know the help for these is in ?Control, but I sometimes make the mistake of typing ?for instead. What is R expecting me to say to finish the statement? Thanks, Angel [[alternative HTML version deleted]]
2010 Nov 29
0
formulas with non-syntactic names and an Error() term
## This is an example where ``-quoted non-syntactic names work in ## simple formulas, but not in formulas with an Error() term. ## Is this intentional or an oversight when ``-quoted names were added? tmp <- data.frame(y=1:6, `x^1`=factor(c(1,2,1,2,1,2)), `x^2`=factor(c(1,1,2,2,3,3)), check.names=FALSE) tmp aov(y ~ `x^1` + `x^2`, data=tmp)
2018 Oct 02
2
Reordering of load/stores using MemorySSA
Hello all, It seems that it is insufficient to rely on MemorySSA to correctly reorder load/stores. For example, we have this following code: v = load q store 10, p => store 10, p v = load q // This is incorrect if p and q may alias In the MemorySSA representation however, there's no syntactic dependency between load/store, because MemorySSA before transformation would look like this:
2005 May 07
4
string syntactic sugar in R? - long post
Currently in R, constructing a string containing values of variables is done using 'paste' and can be an error-prone and traumatic experience. For example, when constructing a db query we have to write, paste("SELECT " value " FROM table where date ='",cdate,"'") we are getting null result from it, because without (forgotten...)
2019 Mar 29
2
Bug in the "reformulate" function in stats package
I suspect that the issue is addressed (obliquely) in the examples, which shows that variables with spaces in them (or otherwise 'non-syntactic', i.e. not satisfying the constraints of legal R symbols) can be handled by protecting them with backticks (``) ## using non-syntactic names: reformulate(c("`P/E`", "`% Growth`"), response = as.name("+-")) It
2020 Aug 29
2
TableGen enhancements
It's interesting that you bring this up. I've seen a lot of TableGen error messages over the past couple of weeks and I don't recall being confused about any error or its location. I will give this a closer look. I agree that syntactic enhancements aren't particularly exciting by themselves. I was wondering whether some new features coupled with new backends would pave the way for
2013 Oct 27
1
[LLVMdev] Add support for ldr pseudo instruction in ARM integrated assembler
So, it seems there are enough people on the plus side, I just wanted to make sure we evaluate all sides before taking a decision to add syntactic sugar to LLVM assembler. My main concern is still the same as earlier this year: the integrated assembler for ARM is still not complete, and the more extensions we add to the back-end, the harder it'll be to get it into production quality. That
2023 Mar 01
1
tab-complete for non-syntactic names could attempt backtick-wrapping
Great suggestion! I've started a patch: https://bugs.r-project.org/show_bug.cgi?id=18479 On Wed, Mar 1, 2023 at 1:56 AM Ivan Krylov <krylov.r00t at gmail.com> wrote: > > ? Wed, 1 Mar 2023 01:36:02 -0800 > Michael Chirico via R-devel <r-devel at r-project.org> ?????: > > > +comps[non_syntactic] <- paste0("`", comps[non_syntactic], "`") >
2004 May 20
1
R 1.8.1 - 1.9.0 incompatability: Underscore in syntactically valid names
Dear R-gang, I have a question about handling underscores in names in R 1.8.1 and 1.9.0. I recently installed 1.9.0 on a machine and found that many codes no longer work as a result of the changed behavior in make.names. I have numerous data files that have dashes, periods and underscores in the header row. I've got numerous R codes that read those files with read.table and read.csv and
2020 Aug 29
3
TableGen enhancements
Now that I've learned my way around TableGen just a bit, I'd like to solicit suggestions for improving and enhancing it. Perhaps there are some lexical changes that could improve readability of .td files (e.g., I'm planning to enhance the lexer to allow an apostrophe as a digit group separator in integers, a la C++). Perhaps there are some syntactic enhancements that would make .td
2017 Apr 03
2
Debugging Docs and llvm.org/docs/
Hi -- I've recently added some documentation to the LLVM docs subdirectory, and was wondering about a couple of things: - How should I best debug whether the docs (in RST) are syntactically correct? Are there recommended practices for doing a sanity check on the docs? - How often do the documents get built and uploaded to the website? Cheers -- Dean
2023 Mar 02
3
tab-complete for non-syntactic names could attempt backtick-wrapping
There turn out to be a few more things to fix. One problem is easy to solve: vapply() needs a third argument specifying the type of the return value. (Can we have unit tests for tab completion?) The other problem is harder: `comps` defaults to an empty string, and you can't have a symbol consisting of an empty string, because this value is internally reserved for missing function arguments.