[haiku-bugs] Re: [Haiku] #15534: HaikuDepot: Lists in the Model use Custom List Class

  • From: "Haiku" <trac@xxxxxxxxxxxx>
  • To: undisclosed-recipients: ;
  • Date: Thu, 16 Jul 2020 12:13:07 -0000

#15534: HaikuDepot: Lists in the Model use Custom List Class
--------------------------------------+------------------------------
  Reporter:  apl-haiku                |      Owner:  stippi
      Type:  task                     |     Status:  new
  Priority:  high                     |  Milestone:  Unscheduled
 Component:  Applications/HaikuDepot  |    Version:  R1/Development
Resolution:                           |   Keywords:  List BObjectList
Blocked By:                           |   Blocking:
  Platform:  All                      |
--------------------------------------+------------------------------
Comment (by apl-haiku):

 Trying this out...


 {{{
 ...
 class List {
 static_assert(std::is_trivially_move_constructible<ItemType>::value,
                 "the list class is only able to be used with trivially
 move "
                 "constructible types");
 }}}

 ...yields...

 {{{
 ../haiku/src/apps/haikudepot/model/PackageInfo.h:394:17:   required from
 here
 ../haiku/src/apps/haikudepot/List.h:23:16: error: static assertion failed:
 the list class is only able to be used with trivially move constructible
 types
 }}}

 ...so I guess those {{{memmove}}} and {{{memcpy}}} operations might not be
 entirely safe.
-- 
Ticket URL: <https://dev.haiku-os.org/ticket/15534#comment:2>
Haiku <https://dev.haiku-os.org>
The Haiku operating system.

Other related posts: