Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(198)

Issue 775943005: UniversalMachExcServer: eliminate multiple implementation inheritance (Closed)

Created:
6 years ago by Mark Mentovai
Modified:
6 years ago
Reviewers:
Robert Sesek
CC:
crashpad-dev_chromium.org
Base URL:
https://chromium.googlesource.com/crashpad/crashpad@master
Project:
crashpad
Visibility:
Public.

Description

UniversalMachExcServer: eliminate multiple implementation inheritance. UniversalMachExcServer provided both an interface and an implementation, contrary to the other classes in the exc_server_variants family. This was mostly done for reasons of economy in an already-large class family. Unfortunately, this decision meant that it was impossible for other code to use UniversalMachExcServer, which required that CatchMachException() be implemented, and also extend another class without violating the style guide’s prohibition of multiple implementation inheritance. This became a problem in a lot of test code, which extended MachMultiprocess and UniversalMachExcServer. UniversalMachExcServer is now given its own nested Interface class, which is a pure interface. All users of UniversalMachExcServer are changed from “is-a” UniversalMachExcServer to “has-a” UniversalMachExcServer and “is-a” UniversalMachExcServer::Interface. TEST=client_test, snapshot_test, util_test R=rsesek@chromium.org Committed: https://chromium.googlesource.com/crashpad/crashpad/+/821ed8fe0fda1c024b08243a71b4676ebce00e9e

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+218 lines, -91 lines) Patch
M client/simulate_crash_mac_test.cc View 6 chunks +9 lines, -5 lines 0 comments Download
M snapshot/mac/mach_o_image_annotations_reader_test.cc View 3 chunks +8 lines, -5 lines 0 comments Download
M tools/catch_exception_tool.cc View 3 chunks +5 lines, -3 lines 0 comments Download
M util/mach/exc_client_variants_test.cc View 3 chunks +8 lines, -6 lines 0 comments Download
M util/mach/exc_server_variants.h View 4 chunks +64 lines, -8 lines 0 comments Download
M util/mach/exc_server_variants.cc View 8 chunks +63 lines, -30 lines 0 comments Download
M util/mach/exc_server_variants_test.cc View 18 chunks +53 lines, -28 lines 0 comments Download
M util/mach/exception_ports_test.cc View 4 chunks +8 lines, -6 lines 0 comments Download

Messages

Total messages: 4 (1 generated)
Mark Mentovai
6 years ago (2014-12-03 21:36:09 UTC) #2
Robert Sesek
LGTM. I'm glad there's tests for this, because it'd be otherwise annoying to check that ...
6 years ago (2014-12-04 15:16:55 UTC) #3
Mark Mentovai
6 years ago (2014-12-04 15:18:29 UTC) #4
Message was sent while issue was closed.
Committed patchset #1 (id:1) manually as
821ed8fe0fda1c024b08243a71b4676ebce00e9e (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698