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

Issue 1461623006: Use simplify operator< implementations in tools/ (Closed)

Created:
5 years, 1 month ago by jsbell
Modified:
5 years ago
Reviewers:
brettw
CC:
chromium-reviews, tfarina
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Use simplify operator< implementations in tools/ Simplify the code for operator< when comparing multiple members using a common std::tie idiom. And resolve a TODO when comparing strings. BUG=555171 R=brettw@chromium.org Committed: https://crrev.com/850020357f5d66ac342fd387e36dd1fb5c298803 Cr-Commit-Position: refs/heads/master@{#362254}

Patch Set 1 #

Total comments: 3

Patch Set 2 : Fix SourceDir compare #

Patch Set 3 : Fix string compare checks #

Unified diffs Side-by-side diffs Delta from patch set Stats (+10 lines, -11 lines) Patch
M tools/gn/label.h View 1 2 1 chunk +6 lines, -8 lines 0 comments Download
M tools/gn/location.cc View 2 chunks +4 lines, -3 lines 0 comments Download

Messages

Total messages: 17 (6 generated)
jsbell
brettw@ - please take a look? The chained string compares could also be written: return ...
5 years, 1 month ago (2015-11-19 22:29:56 UTC) #1
brettw
https://codereview.chromium.org/1461623006/diff/1/tools/gn/label.h File tools/gn/label.h (right): https://codereview.chromium.org/1461623006/diff/1/tools/gn/label.h#newcode74 tools/gn/label.h:74: if (int c = dir_.compare(other.dir_)) You didn't use tie ...
5 years, 1 month ago (2015-11-20 21:44:31 UTC) #2
jsbell
https://codereview.chromium.org/1461623006/diff/1/tools/gn/label.h File tools/gn/label.h (right): https://codereview.chromium.org/1461623006/diff/1/tools/gn/label.h#newcode74 tools/gn/label.h:74: if (int c = dir_.compare(other.dir_)) On 2015/11/20 21:44:31, brettw ...
5 years, 1 month ago (2015-11-20 22:04:27 UTC) #3
brettw
ok, lgtm (this is used in a bunch of maps so can be called a ...
5 years, 1 month ago (2015-11-20 22:05:30 UTC) #4
jsbell
Although apparently I just assumed these were strings. :P I apparently forgot to even build ...
5 years, 1 month ago (2015-11-20 22:06:29 UTC) #5
brettw
https://codereview.chromium.org/1461623006/diff/1/tools/gn/label.h File tools/gn/label.h (right): https://codereview.chromium.org/1461623006/diff/1/tools/gn/label.h#newcode78 tools/gn/label.h:78: if (int c = toolchain_dir_.compare(other.toolchain_dir_)) You can use value() ...
5 years, 1 month ago (2015-11-20 22:17:57 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1461623006/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1461623006/20001
5 years, 1 month ago (2015-11-20 23:41:05 UTC) #9
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/144134)
5 years, 1 month ago (2015-11-21 00:00:51 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1461623006/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1461623006/40001
5 years ago (2015-11-30 21:08:45 UTC) #14
commit-bot: I haz the power
Committed patchset #3 (id:40001)
5 years ago (2015-11-30 22:57:53 UTC) #15
commit-bot: I haz the power
5 years ago (2015-11-30 22:58:37 UTC) #17
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/850020357f5d66ac342fd387e36dd1fb5c298803
Cr-Commit-Position: refs/heads/master@{#362254}

Powered by Google App Engine
This is Rietveld 408576698