2
2
use std:: ops:: DerefMut ;
3
3
4
4
use gix_hash:: ObjectId ;
5
- use gix_macros:: momo;
6
5
use gix_object:: { Exists , Find , FindExt } ;
7
6
use gix_odb:: { Header , HeaderExt , Write } ;
8
7
use gix_ref:: {
@@ -24,7 +23,6 @@ impl crate::Repository {
24
23
///
25
24
/// In order to get the kind of the object, is must be fully decoded from storage if it is packed with deltas.
26
25
/// Loose object could be partially decoded, even though that's not implemented.
27
- #[ momo]
28
26
pub fn find_object ( & self , id : impl Into < ObjectId > ) -> Result < Object < ' _ > , object:: find:: existing:: Error > {
29
27
let id = id. into ( ) ;
30
28
if id == ObjectId :: empty_tree ( self . object_hash ( ) ) {
@@ -44,7 +42,6 @@ impl crate::Repository {
44
42
///
45
43
/// Note that despite being cheaper than [`Self::find_object()`], there is still some effort traversing delta-chains.
46
44
#[ doc( alias = "read_header" , alias = "git2" ) ]
47
- #[ momo]
48
45
pub fn find_header ( & self , id : impl Into < ObjectId > ) -> Result < gix_odb:: find:: Header , object:: find:: existing:: Error > {
49
46
let id = id. into ( ) ;
50
47
if id == ObjectId :: empty_tree ( self . object_hash ( ) ) {
@@ -65,7 +62,6 @@ impl crate::Repository {
65
62
/// Use [`repo.objects.refresh_never()`](gix_odb::store::Handle::refresh_never) to avoid expensive
66
63
/// IO-bound refreshes if an object wasn't found.
67
64
#[ doc( alias = "exists" , alias = "git2" ) ]
68
- #[ momo]
69
65
pub fn has_object ( & self , id : impl AsRef < gix_hash:: oid > ) -> bool {
70
66
let id = id. as_ref ( ) ;
71
67
if id == ObjectId :: empty_tree ( self . object_hash ( ) ) {
@@ -78,7 +74,6 @@ impl crate::Repository {
78
74
/// Obtain information about an object without fully decoding it, or `None` if the object doesn't exist.
79
75
///
80
76
/// Note that despite being cheaper than [`Self::try_find_object()`], there is still some effort traversing delta-chains.
81
- #[ momo]
82
77
pub fn try_find_header (
83
78
& self ,
84
79
id : impl Into < ObjectId > ,
@@ -94,7 +89,6 @@ impl crate::Repository {
94
89
}
95
90
96
91
/// Try to find the object with `id` or return `None` if it wasn't found.
97
- #[ momo]
98
92
pub fn try_find_object ( & self , id : impl Into < ObjectId > ) -> Result < Option < Object < ' _ > > , object:: find:: Error > {
99
93
let id = id. into ( ) ;
100
94
if id == ObjectId :: empty_tree ( self . object_hash ( ) ) {
@@ -155,7 +149,6 @@ impl crate::Repository {
155
149
///
156
150
/// We avoid writing duplicate objects to slow disks that will eventually have to be garbage collected by
157
151
/// pre-hashing the data, and checking if the object is already present.
158
- #[ momo]
159
152
pub fn write_blob ( & self , bytes : impl AsRef < [ u8 ] > ) -> Result < Id < ' _ > , object:: write:: Error > {
160
153
let bytes = bytes. as_ref ( ) ;
161
154
let oid = gix_object:: compute_hash ( self . object_hash ( ) , gix_object:: Kind :: Blob , bytes) ;
@@ -201,7 +194,6 @@ impl crate::Repository {
201
194
///
202
195
/// It will be created with `constraint` which is most commonly to [only create it][PreviousValue::MustNotExist]
203
196
/// or to [force overwriting a possibly existing tag](PreviousValue::Any).
204
- #[ momo]
205
197
pub fn tag (
206
198
& self ,
207
199
name : impl AsRef < str > ,
0 commit comments