EC_STRVEC_SORT(3)

πŸ’– EC_STRVEC_SORT(3) πŸ’–

okay bestie, welcome to the Libecoli Programmer's Manual ✨ this one's short but it's a whole vibe, let's get into it πŸ¦‹


✨ NAME ✨

ec_strvec_sort β€” sort the string vector, no cap πŸŽ€


🌸 SYNOPSIS 🌸

#include <ecoli/strvec.h>

void ec_strvec_sort(
    struct ec_strvec                       *strvec,   /* The pointer to the first string vector. */
    int(*)(const char *s1, const char *s2)  str_cmp   /* The sort function to use. If NULL, use strcmp. */
);

so like, you hand it a struct ec_strvec * called strvec β€” that's the pointer to the first string vector, bestie, she's the main character πŸ‘‘ β€” and then you also pass str_cmp, which is the sort function to use. and if you pass NULL there? iconic, it just falls back to strcmp πŸ’… easy.


🧚 DESCRIPTION 🧚

ngl the whole lore is one line and it ate: Attributes are not compared. πŸ™ˆ

that's it. that's the tea. if your strings got attrs, they are NOT getting a vibe check during the sort. periodt πŸ’€


🌈 SEE ALSO 🌈

the whole friend group, fr fr β€” go read these too:


Copyright (C) 2010-2026 Olivier Matz, Robin Jarry.


k that's the page 🫢 go sort something, you're doing amazing sweetie πŸ’–βœ¨πŸŒΈ

this was libecoli, dated 2026-06-11, signing off bestie β€” EC_STRVEC_SORT(3) slay πŸ’…πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from