Get 1989 entries to compile

There were some which cannot be compiled under clang. One entry we used
a patch from Yusuke Endoh to get the entry to compile; thank you Yusuke
for your assistance! Another one we used a patch from Yusuke (thank
you!) but I further fixed it so that it would work with clang. It had to
be done: IOCCC Tetris has to work! This was done by changing the
environment arg to main() to be a char * in main() itself rather than a
char **. Using a char ** in main() third arg got it to compile but only
one key worked with clang so I changed it to be not the third argument
but a regular char * in main(). **a (third arg) evaluated correctly but
*a[1] and onward was actually part of the environment. Again IOCCC
Tetris has to work!

I also fixed fubar to work which took a few tweaks.

README.md files were also updated.
This commit is contained in:
Cody Boone Ferguson committed 2023-03-06 09:04:46 -08:00
1 parent b6be01bdc6
commit 9d63c37f49
23 files changed
+353 -280

No files matched your search

+36 -25
View File
@@ -1,4 +1,4 @@
Best minimal use of C:
## Best minimal use of C:
Arch D. Robison
University of Illinois
@@ -7,42 +7,53 @@ Best minimal use of C:
61801
USA
Judges notes:
## To build:
Sites with punch card facilities will be happy to note that
the source deck can be re-collated with an ASCII sort.
make all
Note that this program uses only a small subset of the
constructs that the C language supports.
Selected notes from the author:
NOTE: we were able to get this to compile under modern systems with a patch from
Yusuke Endoh. Thank you for your assistance Yusuke!
This program is a handy picoAPL interpreter written in C--. It
outputs the evaluation of an APL expression from standard
input. Functions are limited to dyadic +,-,x, and unary -;
numerals must be binary. Parentheses may be used for
grouping. For example:
## Judges' comments:
Sites with punch card facilities will be happy to note that
the source deck can be re-collated with an ASCII sort.
Note that this program uses only a small subset of the
constructs that the C language supports.
NOTE: this entry will likely dump core with invalid input.
## Selected notes from the author:
This program is a handy picoAPL interpreter written in C--. It
outputs the evaluation of an APL expression from standard
input. Functions are limited to dyadic +,-,x, and unary -;
numerals must be binary. Parentheses may be used for
grouping. For example:
101x111-100
prints:
prints:
1111
That is 5x(7-4) is 15. (APL groups from right to left.)
Extending it to the full APL language should be trivial.
That is 5x(7-4) is 15. (APL groups from right to left.)
Extending it to the full APL language should be trivial.
The C-- language improves the C language by removing superfluous
and confusing features: arithmetic, logical operations, shifts,
relationals, address-of, and flow control. In fact, the only
expressions retained are function calls, indirection, array
assignments, the ',' operator, and sizeof. Despite these
restrictions, the C-- program does arithmetic on arbitrarily
large binary numbers.
The C-- language improves the C language by removing superfluous
and confusing features: arithmetic, logical operations, shifts,
relationals, address-of, and flow control. In fact, the only
expressions retained are function calls, indirection, array
assignments, the ',' operator, and sizeof. Despite these
restrictions, the C-- program does arithmetic on arbitrarily
large binary numbers.
To obtain a C-- reference, simply rip out the irrelevant pages
from your K&R C manual. To obtain a C-- compiler, simply rip
out the irrelevant bytes from your cc compiler.
To obtain a C-- reference, simply rip out the irrelevant pages
from your K&R C manual. To obtain a C-- compiler, simply rip
out the irrelevant bytes from your cc compiler.
Copyright (c) 1989, Landon Curt Noll & Larry Bassel.
All Rights Reserved. Permission for personal, educational or non-profit use is