Add original code of 1986/wall back

By original it is in alt but which works with -traditional-cpp. This is
to match other entries which also have this done.

Manifest updated.
This commit is contained in:
Cody Boone Ferguson committed 2024-06-20 07:57:54 -07:00
1 parent 6d0380a81e
commit 2f3319bf5e
11 files changed
+126 -2

No files matched your search

+8
View File
@@ -25,6 +25,14 @@
"display_via_github" : true,
"entry_text" : "entry Makefile"
},
{
"file_path" : "wall.alt.c",
"inventory_order" : 40,
"OK_to_edit" : true,
"display_as" : "c",
"display_via_github" : true,
"entry_text" : "alternate source code"
},
{
"file_path" : "wall.orig.c",
"inventory_order" : 50,
+1
View File
@@ -6,4 +6,5 @@ indent.c
indent.o
prog.orig
wall
wall.alt
wall.orig
+5 -2
View File
@@ -121,8 +121,8 @@ OBJ= ${PROG}.o
DATA=
TARGET= ${PROG}
#
ALT_OBJ=
ALT_TARGET=
ALT_OBJ= wall.alt.o
ALT_TARGET= ${PROG}.alt
#################
# build the entry
@@ -144,6 +144,9 @@ ${PROG}: ${PROG}.c
alt: ${ALT_TARGET}
@${TRUE}
${PROG}.alt: ${PROG}.alt.c
${CC} ${CFLAGS} -traditional-cpp $< -o $@ ${LDFLAGS}
# data files
#
data: ${DATA}
+20
View File
@@ -4,6 +4,9 @@
make all
```
There is an alternate version for those with a compiler that support
`-traditional-cpp`. See [Alternate code](#alternate-code) below.
## To use:
@@ -12,6 +15,23 @@
```
## Alternate code:
This version is the original but which can be used if you have a compiler that
supports the `-traditional-cpp` option.
### Alternate build:
``` <!--sh-->
make alt
```
### Alternate use:
Use `wall.alt` as you would `wall` above.
## Judges' remarks:
The original version did not have a ';' character in the first line.
+10
View File
@@ -403,8 +403,17 @@ Location: <a href="../../location.html#US">US</a> - <em>United States of America
<!-- BEFORE: 1st line of markdown file: 1986/wall/README.md -->
<h2 id="to-build">To build:</h2>
<pre><code> make all</code></pre>
<p>There is an alternate version for those with a compiler that support
<code>-traditional-cpp</code>. See <a href="#alternate-code">Alternate code</a> below.</p>
<h2 id="to-use">To use:</h2>
<pre><code> ./wall</code></pre>
<h2 id="alternate-code">Alternate code:</h2>
<p>This version is the original but which can be used if you have a compiler that
supports the <code>-traditional-cpp</code> option.</p>
<h3 id="alternate-build">Alternate build:</h3>
<pre class="&lt;!--sh--&gt;"><code> make alt</code></pre>
<h3 id="alternate-use">Alternate use:</h3>
<p>Use <code>wall.alt</code> as you would <code>wall</code> above.</p>
<h2 id="judges-remarks">Judges’ remarks:</h2>
<p>The original version did not have a ‘;’ character in the first line.
This caused a number of System V C pre-preprocessors to gripe about a
@@ -444,6 +453,7 @@ compiler documents the program.</p>
<ul>
<li><a href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1986/wall/wall.c">wall.c</a> - entry source code</li>
<li><a href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1986/wall/Makefile">Makefile</a> - entry Makefile</li>
<li><a href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1986/wall/wall.alt.c">wall.alt.c</a> - alternate source code</li>
<li><a href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1986/wall/wall.orig.c">wall.orig.c</a> - original source code</li>
</ul>
<h2 id="secondary-files">Secondary files</h2>
+78
View File
@@ -0,0 +1,78 @@
#define _c(C)_ (C)&('|'+3):c_()(C)>>('\n'-3) __; /**/
#define C char*
#define keyboard ",,B3-u;.(&*5., /(b*(1\036!a%\031m,,,,,\r\n"
#define main(o,oo)oo(o){
#define _ ;case
C
#define c_(cc)c cc=
#define C_(sand)_O(sand)witch
o=keyboard;
#define __ ;break;
C
ccc(
cc)
C
cc;
{
C
cccc=
cc;int
#ifndef lint
#define keyboard "dijs QH.soav Vdtnsaoh DmfpaksoQz;kkt oa, -dijs"
#endif
c;
main(;c_(=(*cc);*cc++)c,for);
#define _O(s)s
main(0xb+(c>>5),C_(s))
_'\v'
:__ _'\f':
main(c,C_(s));
_c(8098)_c(6055)_c(14779)_c(10682)
#define O_(O)_O(O)stem(ccc(
_c(15276)_c(11196)_c(15150)
#define _C ;return
_c(11070)_c(15663)_c(11583)
}
__
default
:c_(+)o[c&__LINE__-007];
main(c_(-)'-'-1,C_(s))_
0214
:_
0216
:c_(+)025 _
0207
:c_(-)4 _
0233
:c_(+)' '-1;
}}c_(&)'z'+5;
}_C cccc;
}main(,cc)
C
#define O write(1,
c="O";
O_(sy) keyboard));
main(;;,for);
read(0,
c,1);*
c_(&)'~'+1
;O ccc(
c),
'\0');
main(*c,
C_(s));_
4
:O_(sy)";kkt -oa, dijszdijs QQ"))_C
_
13
:O o+' ',
3
)
#undef main
__ _ 127:O"\b \b",3)__
default
:O
c,1)
__}}}main(){
cc();
}