public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/95948] New: memmove error
@ 2020-06-28 15:01 Khram at mail dot ru
  2020-06-28 15:41 ` [Bug c++/95948] " schwab@linux-m68k.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Khram at mail dot ru @ 2020-06-28 15:01 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 95948
           Summary: memmove error
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: Khram at mail dot ru
  Target Milestone: ---

Memmove has a mistake. Need like this:

char* memmove( char *A, char *B, int L )    //! странности из GCC-10.1
{ char *res=A; if( A>B )while( L-->0 )*A++=*B++; else
                 { A+=L; B+=L; while( L-->0 )*--A=*--B; } return res;
}

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-07-20  8:13 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-28 15:01 [Bug c++/95948] New: memmove error Khram at mail dot ru
2020-06-28 15:41 ` [Bug c++/95948] " schwab@linux-m68k.org
2021-07-18 22:18 ` pinskia at gcc dot gnu.org
2021-07-20  8:13 ` Khram at mail dot ru

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).