Details
Details
- Reviewers
pulkit - Group Reviewers
hg-reviewers - Commits
- rHGbeb0d944a99b: remotefilelog: implement __bool__ as well as __nonzero__ for py3
Diff Detail
Diff Detail
- Repository
- rHG Mercurial
- Lint
Lint Skipped - Unit
Unit Tests Skipped
pulkit |
hg-reviewers |
Lint Skipped |
Unit Tests Skipped |
Path | Packages | |||
---|---|---|---|---|
M | hgext/remotefilelog/remotefilelog.py (2 lines) |
Commit | Parents | Author | Summary | Date |
---|---|---|---|---|
Augie Fackler | Jan 16 2019, 10:58 AM |
return True | return True | ||||
nodetext = self.read(node) | nodetext = self.read(node) | ||||
return nodetext != text | return nodetext != text | ||||
def __nonzero__(self): | def __nonzero__(self): | ||||
return True | return True | ||||
__bool__ = __nonzero__ | |||||
def __len__(self): | def __len__(self): | ||||
if self.filename == '.hgtags': | if self.filename == '.hgtags': | ||||
# The length of .hgtags is used to fast path tag checking. | # The length of .hgtags is used to fast path tag checking. | ||||
# remotefilelog doesn't support .hgtags since the entire .hgtags | # remotefilelog doesn't support .hgtags since the entire .hgtags | ||||
# history is needed. Use the excludepattern setting to make | # history is needed. Use the excludepattern setting to make | ||||
# .hgtags a normal filelog. | # .hgtags a normal filelog. | ||||
return 0 | return 0 | ||||