3 Commits

Author SHA1 Message Date
noneofyourbusiness
47106ce103 tccgen.c: silence logical op warning
behavior is unchanged
2025-09-18 11:42:58 +02:00
noneofyourbusiness
8f23997ca7 tests/tcctest.c: include stdint.h
despite being defined in tcc's own stddef.h, intended to be included by
libtcc.h, libtcc.h actually included the libc's standard include

tested on musl
2025-09-18 11:17:55 +02:00
noneofyourbusiness
e73529865d tcc.c: add information about reporting bugs to the mailing list 2025-09-18 09:58:21 +02:00
4 changed files with 7 additions and 5 deletions

View File

@@ -1,5 +1,6 @@
#ifndef _STDDEF_H
#define _STDDEF_H
#define _TINYC_STDDEF
typedef __SIZE_TYPE__ size_t;
typedef __PTRDIFF_TYPE__ ssize_t;

1
tcc.c
View File

@@ -87,6 +87,7 @@ static const char help[] =
#ifdef TCC_TARGET_PE
" create def file : tcc -impdef lib.dll [-v] [-o lib.def]\n"
#endif
" report bugs to the mailing list http://lists.nongnu.org/mailman/listinfo/tinycc-devel\n"
;
static const char help2[] =

View File

@@ -1330,7 +1330,7 @@ static void move_ref_to_global(Sym *s)
if (!(bt == VT_PTR
|| bt == VT_FUNC
|| bt == VT_STRUCT
|| (IS_ENUM(s->type.t)) && (bt = VT_ENUM,1)))
|| ((IS_ENUM(s->type.t)) && (bt = VT_ENUM,1))))
return;
for (s = s->type.ref, n = 0; s; s = s->next) {

View File

@@ -17,10 +17,6 @@
/* __VA_ARGS__ and __func__ support */
#define C99_MACROS
#ifndef __TINYC__
typedef __SIZE_TYPE__ uintptr_t;
#endif
#if defined(_WIN32) \
|| (defined(__arm__) \
&& (defined(__FreeBSD__) \
@@ -66,6 +62,10 @@ typedef __SIZE_TYPE__ uintptr_t;
#include "tcctest.h"
#ifndef _TINYC_STDDEF
#include <stdint.h>
#endif
/* Test two more ways to include a file named like a pp-number */
#define INC(name) <tests/name.h>
#define funnyname 42test.h