Re: [R-pkg-devel] Function Overloading of S4 Methods

2019-05-18 Thread Georgi Boshnakov
Georgi Boshnakov -Original Message- From: R-package-devel [mailto:r-package-devel-boun...@r-project.org] On Behalf Of Linus Chen Sent: 18 May 2019 10:28 To: Dario Strbenac Cc: r-package-devel@r-project.org Subject: Re: [R-pkg-devel] Function Overloading of S4 Methods Dear Dario, I think

Re: [R-pkg-devel] Function Overloading of S4 Methods

2019-05-18 Thread Linus Chen
Dear Dario, I think differently, I think my examples show the resemblance between the way of "dispatching" for S4 generic and that for C++ overloaded function. Both are dispatched ONLY through the type of arguments. Again following your original example: int larger(int x, int y); char larger(char

Re: [R-pkg-devel] Function Overloading of S4 Methods

2019-05-18 Thread Dario Strbenac
Good day, Your conclusion seems to be different to the details you discussed. Don't you intend to conclude that it's not possible with an S4 generic to define methods with different argument names which is different to a language such as C++? -- Dario Strbena