Re: [R-pkg-devel] match.arg With S4 Methods and Missing Inputs

2021-11-08 Thread Georgi Boshnakov
ny default expressions. -Original Message- From: Martin Maechler Sent: 08 November 2021 15:44 To: Georgi Boshnakov Cc: Andrew Simmons ; Dario Strbenac ; r-package-devel@r-project.org Subject: Re: [R-pkg-devel] match.arg With S4 Methods and Missing Inputs >>>

Re: [R-pkg-devel] match.arg With S4 Methods and Missing Inputs

2021-11-08 Thread Martin Maechler
(I don't have time for checking just now), I think it's something we really *should* add to one or more of the related help pages. Martin Maechler > > Sent: Monday, November 8, 2021 5:37:18 AM > To: Dario Strbenac > Cc: r-package-deve

Re: [R-pkg-devel] match.arg With S4 Methods and Missing Inputs

2021-11-08 Thread Georgi Boshnakov
ysg> From: R-package-devel on behalf of Andrew Simmons Sent: Monday, November 8, 2021 5:37:18 AM To: Dario Strbenac Cc: r-package-devel@r-project.org Subject: Re: [R-pkg-devel] match.arg With S4 Methods and Missing Inputs >From the line `function(A, B) standardGeneric("SetOfPara

Re: [R-pkg-devel] match.arg With S4 Methods and Missing Inputs

2021-11-07 Thread Andrew Simmons
>From the line `function(A, B) standardGeneric("SetOfParams")`, A and B will always have default values of R_MissingArg Providing default values within the methods does nothing since A and B have already been initialized before arriving at the method. You could do something like: if (missing(A))