Fix the fix on type combining (e0012c2)
commit9d44b02a492ddbe3f68ec950cda8b3ca3871f163
authorPetr Skocik <pskocik@gmail.com>
Thu, 29 Nov 2018 09:15:25 +0000 (29 10:15 +0100)
committerPetr Skocik <pskocik@gmail.com>
Thu, 29 Nov 2018 09:26:35 +0000 (29 10:26 +0100)
tree4a02fff937ba6402058bddade62e77d3b62e78aa
parente0012c27678848a534aae2776378a199af831a52
Fix the fix on type combining (e0012c2)

    char **argv;
    _Generic(argv, char**: (void)0);
    _Generic(0?(char const*)0:argv[0], char const*: (void)0);
    _Generic(argv, char**: (void)0);

    would fail because the type of argv would get modified by the
    ternary. Now allocate a separate type on the value stack to
    prevent this error.
tccgen.c
tests/tests2/94_generic.c