Ticket #14822 (closed defect: invalid)

Opened 6 months ago

Last modified 6 months ago

wxHtmlLinkEvent and wxHtmlCellEvent: copy constructor missing

Reported by: tvb377 Owned by:
Priority: normal Milestone:
Component: wxHtml Version: 2.9.4
Keywords: wxHtmlLinkEvent wxHtmlCellEvent Cc:
Blocked By: Patch: yes
Blocking:

Description

AFAICS these classes should be given wxDECLARE_DYNAMIC_CLASS_NO_COPY
instead of NO_ASSIGN.

Given their member variables it seems to me an error to attempt to copy an instance of these classes.

I noticed this during LTO-linking with core,base static libs.
gcc then somehow (actually, I don't understand why, given the wx-#includes I'm using) emits an auto generated copy constructor for these classes.

After applying the attached changes wxWidgets (wxhtml) still compiles ok.

Attachments

htmlwin.h.patch download (0.5 KB) - added by tvb377 6 months ago.

Change History

Changed 6 months ago by tvb377

Changed 6 months ago by vadz

  • status changed from new to closed
  • resolution set to invalid

No, sorry, this can't be right. The copy ctor shouldn't be disabled (why?) and is actually used by Clone() so removing it should break the compilation, not fix it. Perhaps you've hit a bug in gcc but the code looks 100% correct to me and the change 100% wrong.

Note: See TracTickets for help on using tickets.