Return-Path: <shearer@cs.bu.edu> X-Spam-HitLevel: X-Spam-DCC: sonic.net: cs3.bu.edu 1117; Body=1 Fuz1=1 Fuz2=1 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on cs3.bu.edu X-Spam-Level: X-Spam-Status: No, score=-2.1 required=10.0 tests=AWL,BAYES_00 autolearn=ham version=3.1.0 X-Spam-Pyzor: Received: from shearershot (c-24-60-255-210.hsd1.ma.comcast.net [24.60.255.210]) by cs3.bu.edu (8.13.6/8.13.6) with ESMTP id k9TG08YW002397; Sun, 29 Oct 2006 11:00:18 -0500 From: "Rui Shi" <shearer@cs.bu.edu> To: <samepst@cs.bu.edu>, <cs520@cs.bu.edu> Subject: RE: Implementation 3 Stuck terms Date: Sun, 29 Oct 2006 11:00:15 -0500 Message-ID: <001801c6fb73$58e6cf50$6400a8c0@csnt.bu.edu> Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <3296.71.192.166.44.1162097071.squirrel@cs-squirrelmail.bu.edu> X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2962 Thread-Index: Acb7FOxbkH3CT8CGTjW8Bn4vVWyAewAXkuWQ X-Clamav-Status: No Status: RO X-Status: A Content-Length: 1150 X-UID: 38 X-Keywords:
It is correct according to the rules. Then in substitution, you don't need
to consider substitution for raise for simplicity.
Rui
-----Original Message-----
From: samepst@cs.bu.edu [mailto:samepst@cs.bu.edu]
Sent: Sunday, October 29, 2006 12:45 AM
To: cs520@cs.bu.edu
Subject: Re: Implementation 3 Stuck terms
This is unexpected. My typechecker types (lam (Exit:int)=> raise Exit) to
TpFun (TpBase "int", TpBase "any")
based on the typing rules ty-lam, ty-exn, and ty-raise. What is the reason
for its failure to typecheck?
Thank You,
-Sam Epstein
> Before you consider substitution -- I assume you are referring to
> substitution of the argument "5" for the formal parameter "Exit" in
> the body of the lambda-abstraction -- you should verify that the
> lambda-abstraction in question "(lam (Exit:int)=> raise Exit)"
> type-checks. It does not.
>
> Assaf
>
> samepst@cs.bu.edu wrote:
>
>>Is it correct to assume that substituion does not recurse into raise
>>terms?
>>For example, the following terms evaluates to true:
>>
>>try (lam (Exit:int)=> raise Exit) 5 with Exit => true | 5 => false
>>
>>Thank you,
>>Sam Epstein
>>
>>
>>
>
This archive was generated by hypermail 2b29 : Thu Dec 14 2006 - 16:31:59 EST