From: Daniel Berger Date: 2006-11-03T04:30:14+09:00 Subject: Re: file size revisit Oliver wrote: > Dan - > > First of all, thanks for fixing this. > > A general comment on this issue is: why in Ruby, the basic operation on > files needs special treatment, and short of being cross-platform? If I > am invoking a exotic feature that is windows only, import a win32 > module would make more sense to me. > > In Python, the operation is uniform cross the platform > import os.path > os.path.getsize("filename") > > maybe many folks probably won't agree this, but I tend to regard the > core File.size() won't work with larger file on windows a bug, though a > minor one. Actually, we all agree. It's a bug in Ruby. It has been brought up, more than once. The problem is the use of stat instead of stat64 in the win32.c file. If I'm feeling up to it this weekend, I'll submit a patch that fixes File.size and a few of the other methods. Regards, Dan