This patch handles the overflowed var expression in the const block, so that
we error properly in the const expr code. It was missing some stuff from the
c++ implementation in how this should be handled properly.
Fixes Rust-GCC#4139
gcc/rust/ChangeLog:
* backend/rust-compile-expr.cc (CompileExpr::compile_integer_literal): cleanup
* backend/rust-constexpr.cc (struct constexpr_global_ctx): port over c++ helpers
(decl_really_constant_value): likewise
(eval_constant_expression): likewise
(non_const_var_error): likewise
gcc/testsuite/ChangeLog:
* rust/compile/issue-4139.rs: New test.
Signed-off-by: Philip Herron <herron.philip@googlemail.com>