On Fri, Jul 28, 2023 at 07:55:54PM +0200, Ulrike Fischer wrote: > Am Fri, 28 Jul 2023 19:25:54 +0200 schrieb LARONDE Thierry: > > >> Note that in order to do file testing by expansion (which we want for > >> various expl3 functions), we *have* to avoid \openin and that realistically > >> means \(pdf)filesize is the best option. > > > > Why in this case not having requested a \filefind primitive, > > Adding new primitives to all engines LaTeX supports is not easily > done, it can take a year or more and even if they are finally > implemented we would have to provide fallbacks for older engines. > So why should we do this work if a suitable primitive is already > present in all engines engines we test? > > Imho the question is more the other way round: why did you > implemented the primitive differently to the other engines? As you > explicitly document "but no extension is implicit" you must have > been aware that one must consider this case and that you are > deviating here. No: I didn't know what others were doing. I refused to read others code. All I wanted was a description of the API (and this was mainly lacking). I simply thought about the feature: when wanting the size, it can be for whatever file. Adding automatically an extension was preventing from obtaining the size of a file without an extension and this was not giving the size of the file as specified (being partly specified, not absolute was not a problem; changing the filename was). This was stupid to not be able to obtain the size of a filename without extension or to alter the filename. So I didn't implement it this way but, contrary to the others, I tried to described precisely what the implementation was doing so that somebody reading the description would have an accurate description of the behavior. I have explained the corner cases of the date primitives to. This does not come either from others implementation or description. But this comes from _my_ implementation. -- Thierry Laronde <tlaronde +AT+ polynum +dot+ com> http://www.kergis.com/ http://kertex.kergis.com/ Key fingerprint = 0FF7 E906 FBAF FE95 FD89 250D 52B1 AE95 6006 F40C