------- Comment #3 from rguenth at gcc dot gnu dot org  2008-01-13 19:24 -------
Reduced testcase that is accepted by 3.3 and 3.4 w/o diagnostic but ICEs
starting with 4.0.

typedef unsigned int op_type_u_t;
typedef op_type_u_t op_type_t;
template<int shifts, op_type_u_t sig>
struct shift {
  enum {
    num_bits = op_type_u_t(sizeof(op_type_t) * 8),
    max_shift = num_bits - 1u,
    is_left = shifts < 0 ? true : false,
    n0 = is_left ? op_type_u_t(-shifts) : op_type_u_t(shifts),
    n = n0 > max_shift ? max_shift : n0,
    n_comp = max_shift - n
  } x;
};


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34774

Reply via email to