test: Remove 00-test.i indirection.
* include/00-test.i: Remove. * scaffold/tests/01-return-0.c: Remove 00-test.i indirection. * scaffold/tests/02-return-1.c: Likewise. * scaffold/tests/03-call.c: Likewise. * scaffold/tests/04-call-0.c: Likewise. * scaffold/tests/05-call-1.c: Likewise. * scaffold/tests/06-call-!1.c: Likewise. * scaffold/tests/10-if-0.c: Likewise. * scaffold/tests/11-if-1.c: Likewise. * scaffold/tests/12-if-==.c: Likewise. * scaffold/tests/13-if-!=.c: Likewise. * scaffold/tests/14-if-goto.c: Likewise. * scaffold/tests/15-if-!f.c: Likewise. * scaffold/tests/16-if-t.c: Likewise. * scaffold/tests/20-while.c: Likewise. * scaffold/tests/21-char[].c: Likewise. * scaffold/tests/22-while-char[].c: Likewise. * scaffold/tests/23-pointer.c: Likewise.
This commit is contained in:
parent
6633331876
commit
03e479e30a
|
@ -1,44 +0,0 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
|
||||||
*
|
|
||||||
* This file is part of GNU Mes.
|
|
||||||
*
|
|
||||||
* GNU Mes is free software; you can redistribute it and/or modify it
|
|
||||||
* under the terms of the GNU General Public License as published by
|
|
||||||
* the Free Software Foundation; either version 3 of the License, or (at
|
|
||||||
* your option) any later version.
|
|
||||||
*
|
|
||||||
* GNU Mes is distributed in the hope that it will be useful, but
|
|
||||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
* GNU General Public License for more details.
|
|
||||||
*
|
|
||||||
* You should have received a copy of the GNU General Public License
|
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
|
||||||
*/
|
|
||||||
|
|
||||||
int test ();
|
|
||||||
|
|
||||||
int
|
|
||||||
main ()
|
|
||||||
{
|
|
||||||
int r = test ();
|
|
||||||
#if __MESC__
|
|
||||||
asm ("mov____%eax,%ebx");
|
|
||||||
asm ("mov____$i32,%eax SYS_exit");
|
|
||||||
asm ("int____$0x80");
|
|
||||||
#elif __GNUC__
|
|
||||||
asm ("mov %0,%%ebx"
|
|
||||||
: // no outputs
|
|
||||||
: "" (r));
|
|
||||||
asm ("mov $1,%eax");
|
|
||||||
asm ("int $0x80");
|
|
||||||
#elif __TINYC__
|
|
||||||
asm ("mov %0,%%ebx"
|
|
||||||
: // no outputs
|
|
||||||
: "Ir" (r));
|
|
||||||
asm ("mov $1,%eax");
|
|
||||||
asm ("int $128");
|
|
||||||
#endif // __GNUC__
|
|
||||||
}
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,10 +18,8 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,10 +18,8 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,8 +18,6 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test0 ()
|
test0 ()
|
||||||
{
|
{
|
||||||
|
@ -27,7 +25,7 @@ test0 ()
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
return test0 ();
|
return test0 ();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,8 +18,6 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
testi (int t)
|
testi (int t)
|
||||||
{
|
{
|
||||||
|
@ -27,7 +25,7 @@ testi (int t)
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
return testi (0);
|
return testi (0);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,8 +18,6 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
testi (int t)
|
testi (int t)
|
||||||
{
|
{
|
||||||
|
@ -27,7 +25,7 @@ testi (int t)
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
return testi (1);
|
return testi (1);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,8 +18,6 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
testi (int t)
|
testi (int t)
|
||||||
{
|
{
|
||||||
|
@ -27,7 +25,7 @@ testi (int t)
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
return testi (1);
|
return testi (1);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,11 +18,10 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
if (0) return 1;
|
if (0)
|
||||||
|
return 1;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,10 +18,8 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
if (1) return 0;
|
if (1) return 0;
|
||||||
return 1;
|
return 1;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,11 +18,10 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
if (0 == 0) return 0;
|
if (0 == 0)
|
||||||
|
return 0;
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,11 +18,10 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
if (0 != 1) return 0;
|
if (0 != 1)
|
||||||
|
return 0;
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,15 +18,15 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
if (0 == 0) goto ok;
|
if (0 == 0)
|
||||||
|
goto ok;
|
||||||
return 1;
|
return 1;
|
||||||
ok:
|
ok:
|
||||||
if (0 != 1) goto ok1;
|
if (0 != 1)
|
||||||
|
goto ok1;
|
||||||
return 1;
|
return 1;
|
||||||
ok1:
|
ok1:
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,12 +18,11 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
int t = 1;
|
int t = 1;
|
||||||
if (t) return 0;
|
if (t)
|
||||||
|
return 0;
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,10 +18,8 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
int t = 1;
|
int t = 1;
|
||||||
if (t) return 0;
|
if (t) return 0;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,12 +18,11 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
int v = 3;
|
int v = 3;
|
||||||
while (v) v--;
|
while (v)
|
||||||
|
v--;
|
||||||
return v;
|
return v;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,17 +18,19 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
char *s = "mes";
|
char *s = "mes";
|
||||||
if (!s[0]) return 1;
|
if (!s[0])
|
||||||
|
return 1;
|
||||||
int f;
|
int f;
|
||||||
int v = 3;
|
int v = 3;
|
||||||
if (!s[f]) return 1;
|
if (!s[f])
|
||||||
if (s[3]) return 1;
|
return 1;
|
||||||
if (s[v]) return 1;
|
if (s[3])
|
||||||
|
return 1;
|
||||||
|
if (s[v])
|
||||||
|
return 1;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,14 +18,14 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
char *s = "mes";
|
char *s = "mes";
|
||||||
int i = 0;
|
int i = 0;
|
||||||
while (s[i]) i++;
|
while (s[i])
|
||||||
if (i != 3) return 1;
|
i++;
|
||||||
|
if (i != 3)
|
||||||
|
return 1;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2017 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2017,2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,8 +18,6 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "00-test.i"
|
|
||||||
|
|
||||||
char *g_hello = "hello";
|
char *g_hello = "hello";
|
||||||
char g_arena[4] = "XXX";
|
char g_arena[4] = "XXX";
|
||||||
char *g_chars = g_arena;
|
char *g_chars = g_arena;
|
||||||
|
@ -31,7 +29,7 @@ struct foo {
|
||||||
struct foo *file;
|
struct foo *file;
|
||||||
|
|
||||||
int
|
int
|
||||||
test ()
|
main ()
|
||||||
{
|
{
|
||||||
if (*g_hello != 'h') return 1;
|
if (*g_hello != 'h') return 1;
|
||||||
if (g_hello[0] != 'h') return 2;
|
if (g_hello[0] != 'h') return 2;
|
||||||
|
|
Loading…
Reference in a new issue