@@ -25,16 +25,8 @@ cdef extern from "pkgcraft.h":
2525 cdef struct Config:
2626 pass
2727
28- # Opaque wrapper for DepSetAtom objects.
29- cdef struct DepSetAtom:
30- pass
31-
32- # Opaque wrapper for DepSetString objects.
33- cdef struct DepSetString:
34- pass
35-
36- # Opaque wrapper for DepSetUri objects.
37- cdef struct DepSetUri:
28+ # Opaque wrapper for DepSet objects.
29+ cdef struct DepSet:
3830 pass
3931
4032 # EAPI object.
@@ -261,23 +253,17 @@ cdef extern from "pkgcraft.h":
261253 # The argument should be a UTF-8 string.
262254 Atom * pkgcraft_cpv(const char * s);
263255
264- # Return the formatted string for a DepSetAtom object.
265- #
266- # # Safety
267- # The argument must be a non-null DepSetAtom pointer.
268- char * pkgcraft_depset_atom_str(const DepSetAtom * dep);
269-
270- # Return the formatted string for a DepSetString object.
256+ # Free a DepSet.
271257 #
272258 # # Safety
273- # The argument must be a non-null DepSetString pointer.
274- char * pkgcraft_depset_string_str(const DepSetString * dep );
259+ # The argument must be a DepSet pointer or NULL .
260+ void pkgcraft_depset_free(DepSet * d );
275261
276- # Return the formatted string for a DepSetUri object.
262+ # Return the formatted string for a DepSet object.
277263 #
278264 # # Safety
279- # The argument must be a non-null DepSetUri pointer.
280- char * pkgcraft_depset_uri_str(const DepSetUri * dep);
265+ # The argument must be a non-null DepSet pointer.
266+ char * pkgcraft_depset_str(DepSet * dep);
281267
282268 # Return an EAPI's identifier.
283269 #
@@ -345,15 +331,15 @@ cdef extern from "pkgcraft.h":
345331 #
346332 # # Safety
347333 # The argument must be a non-null EbuildPkg pointer.
348- const DepSetAtom * pkgcraft_ebuild_pkg_bdepend(EbuildPkg * p);
334+ DepSet * pkgcraft_ebuild_pkg_bdepend(EbuildPkg * p);
349335
350336 # Return a package's DEPEND.
351337 #
352338 # Returns NULL on nonexistence.
353339 #
354340 # # Safety
355341 # The argument must be a non-null EbuildPkg pointer.
356- const DepSetAtom * pkgcraft_ebuild_pkg_depend(EbuildPkg * p);
342+ DepSet * pkgcraft_ebuild_pkg_depend(EbuildPkg * p);
357343
358344 # Return a package's description.
359345 #
@@ -381,7 +367,7 @@ cdef extern from "pkgcraft.h":
381367 #
382368 # # Safety
383369 # The argument must be a non-null EbuildPkg pointer.
384- const DepSetAtom * pkgcraft_ebuild_pkg_idepend(EbuildPkg * p);
370+ DepSet * pkgcraft_ebuild_pkg_idepend(EbuildPkg * p);
385371
386372 # Return a package's directly inherited eclasses.
387373 #
@@ -413,7 +399,7 @@ cdef extern from "pkgcraft.h":
413399 #
414400 # # Safety
415401 # The argument must be a non-null EbuildPkg pointer.
416- const DepSetString * pkgcraft_ebuild_pkg_license(EbuildPkg * p);
402+ DepSet * pkgcraft_ebuild_pkg_license(EbuildPkg * p);
417403
418404 # Return a package's long description.
419405 #
@@ -448,23 +434,23 @@ cdef extern from "pkgcraft.h":
448434 #
449435 # # Safety
450436 # The argument must be a non-null EbuildPkg pointer.
451- const DepSetAtom * pkgcraft_ebuild_pkg_pdepend(EbuildPkg * p);
437+ DepSet * pkgcraft_ebuild_pkg_pdepend(EbuildPkg * p);
452438
453439 # Return a package's RDEPEND.
454440 #
455441 # Returns NULL on nonexistence.
456442 #
457443 # # Safety
458444 # The argument must be a non-null EbuildPkg pointer.
459- const DepSetAtom * pkgcraft_ebuild_pkg_rdepend(EbuildPkg * p);
445+ DepSet * pkgcraft_ebuild_pkg_rdepend(EbuildPkg * p);
460446
461447 # Return a package's REQUIRED_USE.
462448 #
463449 # Returns NULL on nonexistence.
464450 #
465451 # # Safety
466452 # The argument must be a non-null EbuildPkg pointer.
467- const DepSetString * pkgcraft_ebuild_pkg_required_use(EbuildPkg * p);
453+ DepSet * pkgcraft_ebuild_pkg_required_use(EbuildPkg * p);
468454
469455 # Return a package's slot.
470456 #
@@ -478,7 +464,7 @@ cdef extern from "pkgcraft.h":
478464 #
479465 # # Safety
480466 # The argument must be a non-null EbuildPkg pointer.
481- const DepSetUri * pkgcraft_ebuild_pkg_src_uri(EbuildPkg * p);
467+ DepSet * pkgcraft_ebuild_pkg_src_uri(EbuildPkg * p);
482468
483469 # Return a package's subslot.
484470 #
0 commit comments