From: Ezra Zygmuntowicz Date: 2005-08-12T06:46:19+09:00 Subject: Re: How do I use heredocs --Apple-Mail-3--539458889 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed I opened you attachment and it bombed on me as well. But when I selected the line afetr the terminating EOS I saw that you definitely did have about 12 spaces after the EOS. I am attching your file back and now it works. HTH -Ezra Zygmuntowicz Yakima Herald-Republic WebMaster 509-577-7732 ezra@yakima-herald.com --Apple-Mail-3--539458889 Content-Transfer-Encoding: quoted-printable Content-Type: text/x-ruby-script; x-unix-mode=0644; x-mac-hide-extension=yes; name="QuickTest.rb" Content-Disposition: attachment; filename=QuickTest.rb class QuickTest=0D =0D def testMe=0D str =3D< Hello David, > > The message messed up but I am sure that the EOS is on its own line > by itself and I even checked with a HEX editor. Here is the file > atached. > > The editor I use is Mondrain. > > Thanks > > > > >> Hi -- >> >> On Fri, 12 Aug 2005, hsun wrote: >> >> >>> Hi, >>> >>> I have a simple test program. >>> >>> ==================== >>> class QuickTest >>> def testMe >>> str = <>> Some Application data >>> EOS puts str >>> end end >>> if $0 == __FILE__ then >>> >>> $test = QuickTest.new >>> $test.testMe >>> end =========================== >>> I got this error and could not figure out what's wrong? >>> >>> ============================================== >>> QuickTest.rb:21: can't find string "EOS" anywhere before EOF >>> >> You need to put EOS on a line by itself. >> >> David >> >> >> > --Apple-Mail-3--539458889--