commit | 707771a033e3e99edb0e2cb35f860761968b9dc2 | [log] [tgz] |
---|---|---|
author | Raphael Kubo da Costa <raphael.kubo.da.costa@intel.com> | Wed Nov 28 12:21:23 2018 |
committer | Commit Bot <commit-bot@chromium.org> | Wed Nov 28 12:21:23 2018 |
tree | 88ae36c1d3f743d3fc8ab1536ed94804672b7e13 | |
parent | d005f15952bb6b8fd91c233b90a533f3017185a0 [diff] |
CallSetupStateTrackerTest: Fix template handling in member functions This fixes the build with GCC, which was complaining with error messages such as: ../../third_party/blink/renderer/modules/peerconnection/call_setup_state_tracker_unittest.cc:60:13: error: explicit specialization in non-namespace scope ‘class blink::CallSetupStateTrackerTest’ template <> ^ ../../third_party/blink/renderer/modules/peerconnection/call_setup_state_tracker_unittest.cc:65:13: error: explicit specialization in non-namespace scope ‘class blink::CallSetupStateTrackerTest’ template <> ^ ../../third_party/blink/renderer/modules/peerconnection/call_setup_state_tracker_unittest.cc:66:17: error: ‘blink::AnswererState blink::CallSetupStateTrackerTest::current_state() const’ cannot be overloaded with ‘blink::OffererState blink::CallSetupStateTrackerTest::current_state() const’ AnswererState current_state() const { ^~~~~~~~~~~~~ ../../third_party/blink/renderer/modules/peerconnection/call_setup_state_tracker_unittest.cc:61:16: note: previous declaration ‘blink::OffererState blink::CallSetupStateTrackerTest::current_state() const’ OffererState current_state() const { ^~~~~~~~~~~~~ For current_state(), move the template specializations outside of CallSetupStateTrackerTest. Having them in CallSetupStateTrackerTest officially requires C++17 (specifically, C++ DR727). While clang has implemented DR727 for other -std= options, GCC is stricter and only builds that code in C++17 mode. For NoteStateEvent, drop the template bits altogether: the two NoteStateEvent() functions work as regular overloads and do not need any templates. Bug: 819294 Change-Id: I3f839d9a70670de1f52db14efcbd10b3a199b84e Reviewed-on: https://chromium-review.googlesource.com/c/1352256 Commit-Queue: Raphael Kubo da Costa <raphael.kubo.da.costa@intel.com> Reviewed-by: Kentaro Hara <haraken@chromium.org> Cr-Commit-Position: refs/heads/master@{#611666}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .