From: Bill Atkins Date: 2005-03-31T23:11:39+09:00 Subject: Re: Poor efficency of Ruby... You are indeed correct. My mistake. I have never actually written any libraries in python, but had never seen Python do this when compiling scripts (that is, files that didn't get imported). Bill Atkins On Thu, 31 Mar 2005 21:44:50 +0900, JZ wrote: > Dnia Thu, 31 Mar 2005 18:34:17 +0900, Bill Atkins napisa�(a): > > >> No. Python *automatically compiles* every imported module. It is the > >> feature of the language. > > > > Er. Not true. When you load a file in Python, it is interpreted and > > becomes part of the current program. It isn't compiled to bytecode so > > that the bytecode can be used next time for faster load. > > This is *not true*. Did you check it? I bet you don't. > > > dir > 2005-03-31 14:37 . > 2005-03-31 14:37 .. > 2005-03-31 14:36 16 file1.py > 2005-03-31 14:37 27 file2.py > > > type file1.py > x = "I'm file 1" > > >type file2.py > import file1 > print file1.x > > > file2.py > > I'm file 1 > > dir > 2005-03-31 14:37 . > 2005-03-31 14:37 .. > 2005-03-31 14:36 16 file1.py > 2005-03-31 14:37 163 file1.pyc > 2005-03-31 14:37 27 file2.py > > As you can see, file1.pyc is created automatically. Check it. You are wrong > for sure. > > -- > JZ > > -- $stdout.sync = true "Just another Ruby hacker.".each_byte do |b| ('a'..'z').step do|c|print c+"\b";sleep 0.007 end;print b.chr end; print "\n"