This is an automated email from the git hooks/post-receive script. guillem pushed a commit to branch main in repository dpkg.
View the commit online: https://git.dpkg.org/cgit/dpkg/dpkg.git/commit/?id=c6f4a2a7a10358da180fa73689f805a3e23d5e9b commit c6f4a2a7a10358da180fa73689f805a3e23d5e9b Author: Guillem Jover <[email protected]> AuthorDate: Sun Oct 16 23:47:10 2022 +0200 libdpkg, dselect: Reformat enum declarations Place each enum value into its own line, and end the last item with a comma to ease extending them. Changelog: internal --- dselect/dselect.h | 12 ++++++++++-- dselect/pkglist.h | 33 +++++++++++++++++++++++++-------- lib/dpkg/dpkg-db.h | 6 +++++- 3 files changed, 40 insertions(+), 11 deletions(-) diff --git a/dselect/dselect.h b/dselect/dselect.h index e3ec37603..10b7fdbc0 100644 --- a/dselect/dselect.h +++ b/dselect/dselect.h @@ -186,8 +186,16 @@ extern colordata color[]; /* Evil recommends flag variable. */ extern bool manual_install; -enum urqresult { urqr_normal, urqr_fail, urqr_quitmenu }; -enum quitaction { qa_noquit, qa_quitchecksave, qa_quitnochecksave }; +enum urqresult { + urqr_normal, + urqr_fail, + urqr_quitmenu, +}; +enum quitaction { + qa_noquit, + qa_quitchecksave, + qa_quitnochecksave, +}; typedef urqresult urqfunction(void); urqfunction urq_list, urq_quit, urq_menu; diff --git a/dselect/pkglist.h b/dselect/pkglist.h index 3d46dcfd8..0816d4ba9 100644 --- a/dselect/pkglist.h +++ b/dselect/pkglist.h @@ -29,7 +29,7 @@ enum showpriority { dp_none, // has not been involved in any unsatisfied things dp_may, // has been involved in an unsatisfied Suggests dp_should, // has been involved in an unsatisfied Recommends - dp_must // has been involved in an unsatisfied Depends/Conflicts + dp_must, // has been involved in an unsatisfied Depends/Conflicts }; enum selpriority { @@ -39,7 +39,7 @@ enum selpriority { sp_inherit, // inherited from our parent list sp_selecting, // propagating a selection sp_deselecting, // propagating a deselection - sp_fixed // it came from the ‘status’ file and we're not a recursive list + sp_fixed, // it came from the ‘status’ file and we're not a recursive list // high }; @@ -51,7 +51,7 @@ enum ssavailval { // Availability sorting order, first to last: ssa_installed_sameold, // Same or older version available as installed ssa_notinst_seen, // Available but not installed ssa_notinst_gone, // Not available, and only config files left - ssa_none=-1 + ssa_none = -1, }; enum ssstateval { // State sorting order, first to last: @@ -59,7 +59,7 @@ enum ssstateval { // State sorting order, first to last: sss_installed, // Installed sss_configfiles, // Config files only sss_notinstalled, // Not installed - sss_none=-1 + sss_none = -1, }; struct perpackagestate { @@ -111,10 +111,27 @@ protected: // Misc. int nallocated; bool recursive, verbose; - enum { so_unsorted, so_section, so_priority, so_alpha } sortorder; - enum { sso_unsorted, sso_avail, sso_state } statsortorder; - enum { ado_none, ado_available, ado_both } archdisplayopt; - enum { vdo_none, vdo_available, vdo_both } versiondisplayopt; + enum { + so_unsorted, + so_section, + so_priority, + so_alpha, + } sortorder; + enum { + sso_unsorted, + sso_avail, + sso_state, + } statsortorder; + enum { + ado_none, + ado_available, + ado_both, + } archdisplayopt; + enum { + vdo_none, + vdo_available, + vdo_both, + } versiondisplayopt; bool calcssadone, calcsssdone; struct perpackagestate *headings; diff --git a/lib/dpkg/dpkg-db.h b/lib/dpkg/dpkg-db.h index cf127c1b0..a43d9d124 100644 --- a/lib/dpkg/dpkg-db.h +++ b/lib/dpkg/dpkg-db.h @@ -393,7 +393,11 @@ extern const struct namevalue wantinfos[]; #include <dpkg/error.h> -enum versiondisplayepochwhen { vdew_never, vdew_nonambig, vdew_always }; +enum versiondisplayepochwhen { + vdew_never, + vdew_nonambig, + vdew_always, +}; void varbufversion(struct varbuf *, const struct dpkg_version *, enum versiondisplayepochwhen); int parseversion(struct dpkg_version *version, const char *, -- Dpkg.Org's dpkg

