https://gcc.gnu.org/bugzilla/show_bug.cgi?id=128492

            Bug ID: 128492
           Summary: internal compiler error: tree check: expected
                    function_decl, have error_mark in
                    maybe_mark_function_versioned, at cp/decl.cc
           Product: gcc
           Version: 17.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: 0599jiangyc at gmail dot com
  Target Milestone: ---

The following code:
```cpp
void foo ()
{
  int foo (void) __attribute__ ((target ("sse")));
  int foo (void) __attribute__ ((target ("default")));
}
```

Resulted in this output:
```
<source>:3:7: error: ambiguating new declaration of 'int foo()'
<source>:4:53: internal compiler error: tree check: expected function_decl,
have error_mark in maybe_mark_function_versioned, at cp/decl.cc:1401
```

Trunk reproducer: https://godbolt.org/z/djbaTnrd5
  • [Bug c++/128492] New: internal c... 0599jiangyc at gmail dot com via Gcc-bugs

Reply via email to