Re: trap works funny
Paolo <[email protected]>
| Newsgroups | gmane.mail.spam.crm114 |
|---|---|
| Message-ID | <20090312112653.GA6796@localhost> |
On Thu, Mar 12, 2009 at 10:41:26AM +0100, Thomas Michael Hagen wrote:
> {
> input (:ffile:) [:*:name:]
> trap /unable to read-open the file/
> output /Couldn't read file! Trying next file.\n/
> return
>
> trap /program has overflowed/ #the file is too big for the machine's memory
> output /File too big!\n/
> return
> }
funny ... I get
$ crm '-{window
{ isolate (:x:) //
#input (:x:) [T.log]
#fault /1/
trap /1/
output /f:1\n/
output /x:1\n/
trap /./
output /f:2\n/
output /x:2\n/
}
eval (:x:) /:#:x:/
output /x=:*:x:\n/
}'
with FAULT unabled:
f:1
x:1
x=0
with INPUT enabled, on f.size < limit:
x=512106
with INPUT enabled, on f.size > limit (-w 20000):
f:2
x:2
x=15622
which seems to WFM - pls try the above sample code on your side.
--
paolo
GPG/PGP id:0x3A47DE45 - B5F9 AAA0 44BD 2B63 81E0 971F C6C0 0B87 3A47 DE45
------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com