Last change
on this file since 218 was 2, checked in by Rick van der Zwet, 15 years ago |
Initial import of data of old repository ('data') worth keeping (e.g. tracking
means of URL access statistics)
|
File size:
282 bytes
|
Rev | Line | |
---|
[2] | 1 | { This program is correct wrt the context-free grammar;
|
---|
| 2 | however, it should reject the function name 'readreal'.
|
---|
| 3 | }
|
---|
| 4 |
|
---|
| 5 | program builtins;
|
---|
| 6 |
|
---|
| 7 | var
|
---|
| 8 | r,i : integer;
|
---|
| 9 |
|
---|
| 10 | function readreal: real;
|
---|
| 11 | var d : real;
|
---|
| 12 | begin
|
---|
| 13 | readreal := 42.0
|
---|
| 14 | end;
|
---|
| 15 |
|
---|
| 16 | begin
|
---|
| 17 | r := 42;
|
---|
| 18 | i := 21;
|
---|
| 19 | r := readreal
|
---|
| 20 | end
|
---|
| 21 |
|
---|
| 22 |
|
---|
| 23 | .
|
---|
Note:
See
TracBrowser
for help on using the repository browser.