aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Alexandre Passos <apassos@google.com>2018-06-26 15:29:11 -0700
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2018-06-26 15:32:35 -0700
commit80417ef07b5d44e3ee03f9b97f87e98a516470f7 (patch)
treefe17fc85477ee206ce26b426dad58043f39c204d
parentc435dfa414b50b03ea34e9ed22e33816c33383eb (diff)
Make the comparator call operator const.
PiperOrigin-RevId: 202205879
-rw-r--r--tensorflow/python/eager/pywrap_tfe_src.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/tensorflow/python/eager/pywrap_tfe_src.cc b/tensorflow/python/eager/pywrap_tfe_src.cc
index b797a3f82d..57b4dab51c 100644
--- a/tensorflow/python/eager/pywrap_tfe_src.cc
+++ b/tensorflow/python/eager/pywrap_tfe_src.cc
@@ -948,7 +948,7 @@ class GradientTape
: id(id), variable(variable) {}
};
struct CompareById {
- bool operator()(const IdAndVariable& lhs, const IdAndVariable& rhs) {
+ bool operator()(const IdAndVariable& lhs, const IdAndVariable& rhs) const {
return lhs.id < rhs.id;
}
};