search for: mkxxx

Displaying 2 results from an estimated 2 matches for "mkxxx".

Did you mean: mixxx
2016 May 25
3
Suggestion: mkString(NULL) should be NA
...don't do that" (pass a null pointer), which was perfectly fine. The real issue was not the behavior but that it was not documented or consistent. I've lived by the mantra since that you can never trust a pointer in R code. User must always check for NULL. I just wrote my own functions mkXXX_safe that wrap the internals and check the pointer. THK http://www.keittlab.org/ [[alternative HTML version deleted]]
2016 May 25
0
Suggestion: mkString(NULL) should be NA
...never > trust a pointer in R code. User must always check for NULL. In _C_ code. This is true whether you are calling into the R C API or any other C library: you as the C programmer need to make sure either that passing NULL is OK or make sure you don't do that. I wouldn't object to mkXXX checking for NULL and signaling an error instead of segfaulting, but good C code calling mkXXX should still typically do its own check and handle the situation in an appropriate way. Best, luke > > I just wrote my own functions mkXXX_safe that wrap the internals and check > the pointer...