Author: Stan Eisenstat
Subject: Re: [Cs323] NAME begins with digit
Date: Thursday, 24 Sep 2020, 16:13:46
> Message Posted By: Unknown
>
> On the parsley staff solution, if a line is inputted where the first
> character of the NAME of a NAME=VALUE local is a digit, no error is
> reported. However, in the spec, the NAME cannot start with a number. Is
> this an error in parsley for not reporting this?
I assume you tried something like
% ./parsley
(1)$ 1=2 a b
CMD (Depth = 0): SIMPLE, argv[0] = 1=2, argv[1] = a, argv[2] = b
The first TEXT token 1=2 is not of the form NAME=VALUE
where NAME begins with an alphabetic or underscore and
thus cannot be a local variable definition. Thus it
must be the 0th argument, which is how it is displayed
above. There is no error.
--Stan-
PREV
INDEX
NEXT