GOLF(2gg)
π GOLF(2gg) β delete-fifo π
okay bestie, pull up a chair, we're learning delete-fifo from the GOLF manual (that's section 2gg btw) and honestly? it's giving housekeeping. it's giving "clean up after yourself, queen". π§Ήβ¨
πΈ NAME πΈ
delete-fifo β the (FIFO) one that deletes stuff. that's it, that's the name. π
π PURPOSE π
Deleting FIFO list elements up to the last one read, including. like, the one you read is getting yeeted too. no survivors. π
β¨ SYNTAX β¨
delete-fifo <list>
that's it. one argument. we love a low-maintenance icon. π
π¦ DESCRIPTION π¦
so here's the tea: delete-fifo will delete all leading elements from the FIFO <list> up to the last one read, including. the <list> in question was created by new-fifo, iykyk. π
right after rewind-fifo, literally no element was read yet β so delete-fifo will have no effect. nothing to delete, bestie, the vibes are empty. π«Ά
but after any read-fifo? oh it's on. delete-fifo will delete all elements up to the element read, including that element. the read one is gone-gone. π
ngl the original spells it "wil" in that second sentence and honestly? relatable typo energy. but the meaning is 100% clear: everything up to and including the last-read element gets deleted. π
π EXAMPLES π
okay, demo time, watch and learn: β
new-fifo mylist
fresh list, brand new, main character energy. β¨
// Add data to the list
write-fifo mylist key "key1" value "value1"
write-fifo mylist key "some2" value "other2"
we're feeding it data, two whole entries, slay. π
// Get first data from the list
read-fifo mylist key k value v
reading the first one β this is the read that matters, remember it. π
// Delete first element from the list, so list will have only "some2" key
delete-fifo mylist
and boom β first element deleted, so the list will have only the "some2" key left. ate. π₯
π SEE ALSO π
FIFOπ¦delete-fifo(yes it references itself, iconic behavior)new-fifopurge-fiforead-fiforewind-fifowrite-fifo- See all documentation π
and that's the whole page, bestie. go forth, delete responsibly. π
this little love letter was brought to you by version $VERSION dated $DATE β from GOLF(2gg) herself. mwah. π«Άπ
β¨
π¦ where this page comes from
- ubuntu questing: golf 601.4.41-1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms