Return-Path: <kfoury@cs.bu.edu> Received: from cs.bu.edu (cs [128.197.12.2]) by cs3.bu.edu (8.12.11/8.12.11) with ESMTP id i8ONZ6tG005950; Fri, 24 Sep 2004 19:35:06 -0400 Received: from cs.bu.edu (h000c41248e2b.ne.client2.attbi.com [24.34.20.189]) (authenticated bits=0) by cs.bu.edu (8.12.2/8.12.2) with ESMTP id i8ONZ68p004076; Fri, 24 Sep 2004 19:35:06 -0400 (EDT) Message-ID: <4154AF31.2080301@cs.bu.edu> Date: Fri, 24 Sep 2004 19:35:13 -0400 From: Assaf Kfoury <kfoury@cs.bu.edu> Organization: Boston University User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040413 Debian/1.6-5 X-Accept-Language: en To: Quan <Yuan@cs.bu.edu>, cs520@cs.bu.edu Subject: Re: question about Exercise 5.3.7 References: <200409240503.i8O53F8p025799@cs.bu.edu> In-Reply-To: <200409240503.i8O53F8p025799@cs.bu.edu> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Spam-HitLevel: xx X-Spam-DCC: neonova: cs3.bu.edu 1127; Body=19 Fuz1=19 Fuz2=19 X-Spam-Checker-Version: SpamAssassin 2.64 (2004-01-11) on cs3.bu.edu X-Spam-Level: ** X-Spam-Status: No, hits=2.4 required=10.0 tests=AWL,RCVD_IN_DSBL, RCVD_IN_NJABL_PROXY autolearn=no version=2.64 X-Spam-Pyzor: Reported 0 times. Status: RO X-Mozilla-Status: 8011 X-Mozilla-Status2: 00000000 X-UIDL: 411f69ec00000bf6
You are referring to a syntactic error, not an evaluation error. A
expression of the form "if true then" is not a legal term, and neither
are expressions of the form "if true", or "then false", or "else true",
etc., all of which should be caught by a syntactic analysis, before they
are evaluated.
The special value "wrong" is introduced to handle differently semantic
(or evaluation) errors.
Assaf
Quan wrote:
>Prof. Kfoury,
> In the Exercise 3.5.16, I am not clear how it handles error like "if true then". When the "if_then_else" statement is not complete, it seems no rules can apply.
> Thanks,
>
>Quan
>
>
>
This archive was generated by hypermail 2b29 : Fri Nov 19 2004 - 17:00:43 EST