Branch: Tag:

2020-07-06

2020-07-06 11:10:45 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Compiler: Don't attempt to constant-fold automap markers.

Attempting to get a constant from an expression like

({ "abc", "cde" })[*]

is not possible and generates the compilation error
"[*] not supported here", so don't attempt to.

Fixes #10039.

2114:   int is_const(node *n)   {    if(!n) return 1; +  if(n->token == F_AUTO_MAP_MARKER) return 0;    return !(n->tree_info & (OPT_SIDE_EFFECT |    OPT_NOT_CONST |    OPT_ASSIGNMENT |