search for: thingysintegermust

Displaying 1 result from an estimated 1 matches for "thingysintegermust".

2012 Sep 15
1
Question about copying arguments in C.
...), or whether I have to copy them. If it is the latter, then how may I do this. The question is phrased in the following (simplified) code. int constructThingy(int thingysInteger); SEXP constructThingy(SEXP thingysInteger) { SEXP ans, TClass, ti; if(!isInteger(thingysInteger)) error("thingysIntegermust be an integer."); if(constructThingy(INTEGER(thingysInteger)[0])) error("error in getting a thingy"); TClass = MAKE_CLASS("thingy"); PROTECT(ans = NEW_OBJECT(TClass)); // *****QUESTION STARTS HERE***** // CAN I SAY: SET_SLOT(ans, Rf_install("m...