[Bug c++/108323] New: combine does not change the locale name

2023-01-06 Thread liweifriends at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108323

Bug ID: 108323
   Summary: combine does not change the locale name
   Product: gcc
   Version: 12.2.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: liweifriends at gmail dot com
  Target Milestone: ---

for the following code
```
#include 
#include 

int main()
{
std::locale loc = std::locale()
.combine>(std::locale("en_US.UTF-8"));
std::cout << loc.name() << '\n';

std::cout << (std::locale() == loc);

}
```

gcc outputs 'C' and '1' (https://godbolt.org/z/q8fT4oqj3), which seems a bug?
Because locale::combine should return a new and nameless locale.

[Bug c/108134] New: A description bug for Extended Asm document

2022-12-15 Thread liweifriends at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108134

Bug ID: 108134
   Summary: A description bug for Extended Asm document
   Product: gcc
   Version: unknown
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c
  Assignee: unassigned at gcc dot gnu.org
  Reporter: liweifriends at gmail dot com
  Target Milestone: ---

In document
(https://github.com/gcc-mirror/gcc/blob/master/gcc/doc/extend.texi), there are
the following description:

The rest of this discussion uses the following code for illustrative purposes.

```
int main()
{
   int iInt = 1;

top:

   asm volatile goto ("some assembler instructions here"
   : /* No outputs. */
   : "q" (iInt), "X" (sizeof(unsigned char) + 1), "i" (42)
   : /* No clobbers. */
   : top);
}

With no modifiers, this is what the output from the operands would be for the
‘att’ and ‘intel’ dialects of assembler:
Operand ‘att’   ‘intel’
%0  %eaxeax
%1  $2  2
%3  $.L3OFFSET FLAT:.L3
%4  $8  8
%5  %xmm0   xmm0
%7  $0  0
```

However, for the inline asm code, there is no %4, %5, and %7 at all. And in the
following table, it also shows something like "%y6", but there is no %6 at all.
So the reader cannot understand the meaning of them.