diff options
| author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-09-11 12:56:29 (GMT) |
|---|---|---|
| committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-09-11 12:56:29 (GMT) |
| commit | 524b1d9fb207987cf66ca92d5198e30e27e0931e (patch) | |
| tree | 03481b58a31f0fcf82158c6c66891c88725e957f /generic/tclInt.h | |
| parent | f796d623675cfb8a59b1c190470f785c61b90a8e (diff) | |
| parent | 7f62b768876fc8b0779d10ae3fcba1fc7aeaba04 (diff) | |
| download | tcl-524b1d9fb207987cf66ca92d5198e30e27e0931e.zip tcl-524b1d9fb207987cf66ca92d5198e30e27e0931e.tar.gz tcl-524b1d9fb207987cf66ca92d5198e30e27e0931e.tar.bz2 | |
Merge 8.6. Remove tests/safe-stock86.test for win builds too (GIT, what are you doing ...!)
Diffstat (limited to 'generic/tclInt.h')
| -rw-r--r-- | generic/tclInt.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/generic/tclInt.h b/generic/tclInt.h index b983b81..d79937f 100644 --- a/generic/tclInt.h +++ b/generic/tclInt.h @@ -925,6 +925,12 @@ typedef struct VarInHash { *---------------------------------------------------------------- */ +#if defined(__GNUC__) && (__GNUC__ > 2) +# define TCLFLEXARRAY 0 +#else +# define TCLFLEXARRAY 1 +#endif + /* * Forward declaration to prevent an error when the forward reference to * Command is encountered in the Proc and ImportRef types declared below. @@ -968,7 +974,7 @@ typedef struct CompiledLocal { * is marked by a unique tag during * compilation, and that same tag is used to * find the variable at runtime. */ - char name[1]; /* Name of the local variable starts here. If + char name[TCLFLEXARRAY]; /* Name of the local variable starts here. If * the name is NULL, this will just be '\0'. * The actual size of this field will be large * enough to hold the name. MUST BE THE LAST @@ -1306,7 +1312,7 @@ typedef struct CFWordBC { typedef struct ContLineLoc { int num; /* Number of entries in loc, not counting the * final -1 marker entry. */ - int loc[1]; /* Table of locations, as character offsets. + int loc[TCLFLEXARRAY];/* Table of locations, as character offsets. * The table is allocated as part of the * structure, extending behind the nominal end * of the structure. An entry containing the |
