This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/81042] Too many constexpr interations on unreachable loop.
- From: "maxmati4 at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 19 Aug 2017 20:33:59 +0000
- Subject: [Bug c++/81042] Too many constexpr interations on unreachable loop.
- Auto-submitted: auto-generated
- References: <bug-81042-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81042
Mateusz Nowotynski <maxmati4 at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |maxmati4 at gmail dot com
--- Comment #2 from Mateusz Nowotynski <maxmati4 at gmail dot com> ---
I also experienced this bug on gcc (Gentoo 6.4.0 p1.0) 6.4.0 and gcc (GCC)
8.0.0 20170819 (experimental). On version 6.4 it results in never ending
compilation and on 8.0 it trigers same error as @KevinCox.
Whats more for me it looks like regrsion since my code compiles fine on gcc
(Ubuntu 6.2.0-5ubuntu12) 6.2.0 20161005 haven't tried @KevinCox version.
My program triggering this error:
struct Table
{
constexpr Table() : primes()
{
for(int i = 1; i < 100; ++i){
if(!primes[i]) continue;
for(int j = 1; j < 100; ++j);
}
}
bool primes[100];
};
int main(){
constexpr auto primes = Table();
}