Ivan Krylov
2024-May-14 05:08 UTC
[R] Description of error is untranslated when R_XLEN_T_MAX is exceeded by only 1 element.
Dear Ricardo Villalba, Thank you for spotting this corner case! ? Mon, 13 May 2024 11:37:57 -0300 Ricardo Villalba <rikivillalba at gmail.com> ?????:> I track the messages to be coded here: > https://github.com/r-devel/r-svn/blob/abe625945c4402cd2bb97b5a64e7469db3e904f0/src/main/altclasses.c#L580 > and here > https://github.com/r-devel/r-svn/blob/abe625945c4402cd2bb97b5a64e7469db3e904f0/src/main/seq.c#L102You may have noticed that one of these places lacks the underscore that R uses as the translation keyword: it's _(string) that looks up the translation of the string. Would you like to suggest a patch on R-devel at r-project.org or https://bugs.r-project.org ? -- Best regards, Ivan
Martin Maechler
2024-May-14 07:45 UTC
[R] Altrep and translations (was " Description of error is untranslated when ....")
>>>>> Ivan Krylov via R-help >>>>> on Tue, 14 May 2024 08:08:58 +0300 writes:> Dear Ricardo Villalba, Thank you for spotting this corner > case! > ? Mon, 13 May 2024 11:37:57 -0300 Ricardo Villalba > <rikivillalba at gmail.com> ?????: >> I track the messages to be coded here: >> https://github.com/r-devel/r-svn/blob/abe625945c4402cd2bb97b5a64e7469db3e904f0/src/main/altclasses.c#L580 >> and here >> https://github.com/r-devel/r-svn/blob/abe625945c4402cd2bb97b5a64e7469db3e904f0/src/main/seq.c#L102 > You may have noticed that one of these places lacks the > underscore that R uses as the translation keyword: it's > _(string) that looks up the translation of the string. > Would you like to suggest a patch on R-devel at r-project.org > or https://bugs.r-project.org ? > -- > Best regards, Ivan Thank you, but, well... for such small changes -- that would be quite a bit of (human, i.e. R-core) overhead, but of course is generally a good possibility (but here, wait! .. and read on : ) Actually -- this now gets more "R-devel" - appropriate -- I notice that there are quite a few error("..." .. ) and also warning("..." ..) calls in src/main/altclasses.c *and* in src/main/altrep.c and *none* of them asks for translation; While this could be for historical reasons (code originally much by Gabe Becker from outside R-core *and* at first just in a separate branch before being merged in to the main (r-devel) branch. OTOH: There may be good reasons for translations lookup being brittle in case of altrep error messages .. and hence left off purposely? Martin -- Martin Maechler ETH Zurich and R Core Team
Maybe Matching Threads
- Altrep and translations (was " Description of error is untranslated when ....")
- Description of error is untranslated when R_XLEN_T_MAX is exceeded by only 1 element.
- Description of error is untranslated when R_XLEN_T_MAX is exceeded by only 1 element.
- Description of error is untranslated when R_XLEN_T_MAX is exceeded by only 1 element.
- [External] Re: Operations with long altrep vectors cause segfaults on Windows