@@ -2334,10 +2334,9 @@ extern "C" {
23342334 pub fn git_libgit2_shutdown ( ) -> c_int ;
23352335
23362336 // repository
2337- #[ cfg( not( feature = "unstable-sha256" ) ) ]
23382337 pub fn git_repository_new ( out : * mut * mut git_repository ) -> c_int ;
23392338 #[ cfg( feature = "unstable-sha256" ) ]
2340- pub fn git_repository_new (
2339+ pub fn git_repository_new_ext (
23412340 out : * mut * mut git_repository ,
23422341 opts : * mut git_repository_new_options ,
23432342 ) -> c_int ;
@@ -2509,28 +2508,25 @@ extern "C" {
25092508 pub fn git_object_typeisloose ( kind : git_object_t ) -> c_int ;
25102509
25112510 // oid
2512- # [ cfg ( not ( feature = "unstable-sha256" ) ) ]
2511+ // These always parse as SHA1
25132512 pub fn git_oid_fromraw ( out : * mut git_oid , raw : * const c_uchar ) -> c_int ;
2514- #[ cfg( not( feature = "unstable-sha256" ) ) ]
25152513 pub fn git_oid_fromstrn ( out : * mut git_oid , str : * const c_char , len : size_t ) -> c_int ;
2516- #[ cfg( not( feature = "unstable-sha256" ) ) ]
25172514 pub fn git_oid_fromstr ( out : * mut git_oid , str : * const c_char ) -> c_int ;
2518- #[ cfg( not( feature = "unstable-sha256" ) ) ]
25192515 pub fn git_oid_fromstrp ( out : * mut git_oid , str : * const c_char ) -> c_int ;
25202516
2517+ // These take an explicit OID type (SHA1 or SHA256)
25212518 #[ cfg( feature = "unstable-sha256" ) ]
2522- pub fn git_oid_fromraw ( out : * mut git_oid , raw : * const c_uchar , oid_type : git_oid_t ) -> c_int ;
2519+ pub fn git_oid_from_raw ( out : * mut git_oid , raw : * const c_uchar , oid_type : git_oid_t ) -> c_int ;
25232520 #[ cfg( feature = "unstable-sha256" ) ]
2524- pub fn git_oid_fromstrn (
2521+ pub fn git_oid_from_prefix (
25252522 out : * mut git_oid ,
25262523 str : * const c_char ,
25272524 len : size_t ,
25282525 oid_type : git_oid_t ,
25292526 ) -> c_int ;
25302527 #[ cfg( feature = "unstable-sha256" ) ]
2531- pub fn git_oid_fromstr ( out : * mut git_oid , str : * const c_char , oid_type : git_oid_t ) -> c_int ;
2532- #[ cfg( feature = "unstable-sha256" ) ]
2533- pub fn git_oid_fromstrp ( out : * mut git_oid , str : * const c_char , oid_type : git_oid_t ) -> c_int ;
2528+ pub fn git_oid_from_string ( out : * mut git_oid , str : * const c_char , oid_type : git_oid_t )
2529+ -> c_int ;
25342530
25352531 pub fn git_oid_tostr ( out : * mut c_char , n : size_t , id : * const git_oid ) -> * mut c_char ;
25362532 pub fn git_oid_cmp ( a : * const git_oid , b : * const git_oid ) -> c_int ;
@@ -3358,14 +3354,12 @@ extern "C" {
33583354 stage : c_int ,
33593355 ) -> * const git_index_entry ;
33603356 pub fn git_index_has_conflicts ( index : * const git_index ) -> c_int ;
3361- #[ cfg( not( feature = "unstable-sha256" ) ) ]
33623357 pub fn git_index_new ( index : * mut * mut git_index ) -> c_int ;
33633358 #[ cfg( feature = "unstable-sha256" ) ]
3364- pub fn git_index_new ( index : * mut * mut git_index , opts : * const git_index_options ) -> c_int ;
3365- #[ cfg( not( feature = "unstable-sha256" ) ) ]
3359+ pub fn git_index_new_ext ( index : * mut * mut git_index , opts : * const git_index_options ) -> c_int ;
33663360 pub fn git_index_open ( index : * mut * mut git_index , index_path : * const c_char ) -> c_int ;
33673361 #[ cfg( feature = "unstable-sha256" ) ]
3368- pub fn git_index_open (
3362+ pub fn git_index_open_ext (
33693363 index : * mut * mut git_index ,
33703364 index_path : * const c_char ,
33713365 opts : * const git_index_options ,
@@ -3937,14 +3931,13 @@ extern "C" {
39373931 line_cb : git_diff_line_cb ,
39383932 payload : * mut c_void ,
39393933 ) -> c_int ;
3940- #[ cfg( not( feature = "unstable-sha256" ) ) ]
39413934 pub fn git_diff_from_buffer (
39423935 diff : * mut * mut git_diff ,
39433936 content : * const c_char ,
39443937 content_len : size_t ,
39453938 ) -> c_int ;
39463939 #[ cfg( feature = "unstable-sha256" ) ]
3947- pub fn git_diff_from_buffer (
3940+ pub fn git_diff_from_buffer_ext (
39483941 diff : * mut * mut git_diff ,
39493942 content : * const c_char ,
39503943 content_len : size_t ,
@@ -4280,14 +4273,12 @@ extern "C" {
42804273
42814274 // odb
42824275 pub fn git_repository_odb ( out : * mut * mut git_odb , repo : * mut git_repository ) -> c_int ;
4283- #[ cfg( not( feature = "unstable-sha256" ) ) ]
42844276 pub fn git_odb_new ( db : * mut * mut git_odb ) -> c_int ;
42854277 #[ cfg( feature = "unstable-sha256" ) ]
4286- pub fn git_odb_new ( db : * mut * mut git_odb , opts : * const git_odb_options ) -> c_int ;
4287- #[ cfg( not( feature = "unstable-sha256" ) ) ]
4278+ pub fn git_odb_new_ext ( db : * mut * mut git_odb , opts : * const git_odb_options ) -> c_int ;
42884279 pub fn git_odb_open ( out : * mut * mut git_odb , objects_dir : * const c_char ) -> c_int ;
42894280 #[ cfg( feature = "unstable-sha256" ) ]
4290- pub fn git_odb_open (
4281+ pub fn git_odb_open_ext (
42914282 out : * mut * mut git_odb ,
42924283 objects_dir : * const c_char ,
42934284 opts : * const git_odb_options ,
0 commit comments