diff rust/hg-core/src/revlog/filelog.rs @ 47963:001d747c2baf

rust: Return HgError instead of RevlogError in revlog constructors This leaves fewer cases for callers to handle, as RevlogError is more general Differential Revision: https://phab.mercurial-scm.org/D11410
author Simon Sapin <simon.sapin@octobus.net>
date Mon, 13 Sep 2021 18:02:45 +0200
parents 4d2a5ca060e3
children 6f579618ea7b
line wrap: on
line diff
--- a/rust/hg-core/src/revlog/filelog.rs	Mon Sep 13 17:23:42 2021 +0200
+++ b/rust/hg-core/src/revlog/filelog.rs	Mon Sep 13 18:02:45 2021 +0200
@@ -17,7 +17,7 @@
 }
 
 impl Filelog {
-    pub fn open(repo: &Repo, file_path: &HgPath) -> Result<Self, RevlogError> {
+    pub fn open(repo: &Repo, file_path: &HgPath) -> Result<Self, HgError> {
         let index_path = store_path(file_path, b".i");
         let data_path = store_path(file_path, b".d");
         let revlog = Revlog::open(repo, index_path, Some(&data_path))?;