Opened 5 years ago

Closed 3 years ago

#769 closed change (fixed)

Replace auto_ptr by unique_ptr

Reported by: trev Assignee: sergz
Priority: P4 Milestone:
Module: Libadblockplus Keywords:
Cc: sergz Blocked By: #768
Blocking: Platform: Unknown
Ready: yes Confidential: no
Tester: Unknown Verified working: no
Review URL(s):

https://codereview.adblockplus.org/29361644/

Description

Background

We currently use std:auto_ptr in a few places in libadblockplus which has some shortcomings:

  • Deprecated due to bad copy semantics.
  • Cannot deal with arrays.
  • Destructor cannot be redefined.

What to change

Switch to std:unique_ptr once we switch to compatible standard libraries on all platforms.

Change History (5)

comment:1 Changed 4 years ago by Mailkov

Hi, I would like to work on this, when the issue 768 will be closed.

Last edited 4 years ago by Mailkov (previous) (diff)

comment:2 Changed 3 years ago by sergz

  • Review URL(s) modified (diff)
  • Status changed from new to reviewing
  • Tester set to Unknown

comment:3 Changed 3 years ago by sergz

  • Cc sergz added
  • Owner set to sergz

comment:4 Changed 3 years ago by abpbot

A commit referencing this issue has landed:
Issue 769 - replace auto_ptr by unique_ptr and use proper delete[ operator]

comment:5 Changed 3 years ago by sergz

  • Resolution set to fixed
  • Status changed from reviewing to closed
Note: See TracTickets for help on using tickets.