--- Comment #5 from bartoschek at gmx dot de 2008-12-10 16:17 ---
Created an attachment (id=16874)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16874&action=view)
Proposed implementation of std::swap
Here is a proposal on how std::swap could be improved for st
--- Comment #4 from bartoschek at gmx dot de 2008-12-10 16:04 ---
Ok. But what is the reason for not using a __swap_impl within the current
standard?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38466
--- Comment #2 from bartoschek at gmx dot de 2008-12-10 00:03 ---
Could you point me to the part in the standard that forbids this?
If this is really forbidden an additional level of indirection should help.
Just call an swap_impl(a, b) from std::swap and define swap_impl for
std
of a
std::pair
Product: gcc
Version: 4.3.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: bartoschek at gmx dot de
GCC build triplet: i586-suse-linux
GCC host triplet: i586-suse-linux
GCC target triplet: i586-suse-linux
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38466
/crtend.o
/usr/lib/../lib64/crtn.o
-bash-3.00$ ./a.out
Speicherzugriffsfehler
-bash-3.00$
--
Summary: gcc reads 8 bytes for a struct of size 6 which leads to
sigsegv
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Severity: norm