On Wed, 31 Mar 2010, John M McIntosh wrote:
On 2010-03-31, at 3:59 PM, Levente Uzonyi wrote:
IMHO #copyFile:toFile: shouldn't exist, it's just a utility method, totally unrelated to FileDirectory. It also assumes that the files are in "ascii" mode which is wrong.
Levente
+1 In Sophie we replaced this with a primitive to which had the responsibility to ask the operating system to copy the files. The complexity of meta-data (security, dates/times, Access lists, stuff) on a *file* make Squeak's desire to copy just the bits rather 1970 ish... Oh wait pre that since it doesn't preserve the from file security settings either...
What's really "funny" about this method is that it doesn't really copy files, just the copies the contents of a ReadStream to WriteStream using a ByteString as a buffer. It doesn't use files at all.
Levente
--
John M. McIntosh johnmci@smalltalkconsulting.com Twitter: squeaker68882 Corporate Smalltalk Consulting Ltd. http://www.smalltalkconsulting.com ===========================================================================