# HG changeset patch # User Anton Shestakov # Date 1535627636 -28800 # Node ID 1914a53fe79257fee8625e536cea16703ca19130 # Parent 90783c9c86097cabd1b3bb949ecdb8978b618264 topic: handle string argument to topic() revset earlier diff -r 90783c9c8609 -r 1914a53fe792 hgext3rd/topic/revset.py --- a/hgext3rd/topic/revset.py Thu Aug 30 18:02:41 2018 +0800 +++ b/hgext3rd/topic/revset.py Thu Aug 30 19:13:56 2018 +0800 @@ -50,6 +50,15 @@ topic = repo['.'].extra().get('topic', '') _kind, _pattern, matcher = mkmatcher(topic) + def matches(r): + topic = repo[r].topic() + if not topic: + return False + return matcher(topic) + + if True: + return (subset & mutable).filter(matches) + rawchange = repo.changelog.changelogrevision key = constants.extrakey