mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 23:38:50 +03:00
pyrevisionstore: suppress warning of unused parameter
Summary: The `known` parameter can't be renamed to `_known`, as the Python bindings expect it to have the name `known`, however we can suppress the warning by assigning it to a local variable named `_known`. The compiler will optimize this away. Reviewed By: quark-zju Differential Revision: D13239755 fbshipit-source-id: cc83be0441415dc3dd5959632dcab2af54d11513
This commit is contained in:
parent
bc9e47bfb6
commit
ac25a0f173
@ -156,6 +156,7 @@ py_class!(class historypack |py| {
|
||||
}
|
||||
|
||||
def getancestors(&self, name: &PyBytes, node: &PyBytes, known: Option<&PyObject>) -> PyResult<PyDict> {
|
||||
let _known = known;
|
||||
<HistoryStorePyExt>::get_ancestors(self.store(py).as_ref(), py, name, node)
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user