diff options
author | erg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-04 21:03:47 +0000 |
---|---|---|
committer | erg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-04 21:03:47 +0000 |
commit | 6775e40aeb887f15dc9182b250cdc4100aa79ce0 (patch) | |
tree | 858e3064689861a9ad85975154ce653418aaf3d8 /courgette | |
parent | 5bd8d1716b3f27664348c7fcb2c33f2e3a4573a7 (diff) | |
download | chromium_src-6775e40aeb887f15dc9182b250cdc4100aa79ce0.zip chromium_src-6775e40aeb887f15dc9182b250cdc4100aa79ce0.tar.gz chromium_src-6775e40aeb887f15dc9182b250cdc4100aa79ce0.tar.bz2 |
Change other usages of .size() to .empty() when applicable.
BUG=carnitas
TEST=compiles
Review URL: http://codereview.chromium.org/6609008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76962 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'courgette')
-rw-r--r-- | courgette/adjustment_method.cc | 2 | ||||
-rw-r--r-- | courgette/encoded_program.cc | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/courgette/adjustment_method.cc b/courgette/adjustment_method.cc index 5e9e6d2..7913f8c 100644 --- a/courgette/adjustment_method.cc +++ b/courgette/adjustment_method.cc @@ -149,7 +149,7 @@ struct Node { std::list<Node*> edges_in_frequency_order; bool in_queue_; - bool Extended() const { return edges_.size() > 0; } + bool Extended() const { return !edges_.empty(); } uint32 Weight() const { return edges_in_frequency_order.front()->count_; diff --git a/courgette/encoded_program.cc b/courgette/encoded_program.cc index 8439d31..5169c16 100644 --- a/courgette/encoded_program.cc +++ b/courgette/encoded_program.cc @@ -195,7 +195,7 @@ void EncodedProgram::AddCopy(uint32 count, const void* bytes) { // For compression of files with large differences this makes a small (4%) // improvement in size. For files with small differences this degrades the // compressed size by 1.3% - if (ops_.size() > 0) { + if (!ops_.empty()) { if (ops_.back() == COPY1) { ops_.back() = COPY; copy_counts_.push_back(1); |