summaryrefslogtreecommitdiffstats
path: root/share/man/man3/queue.3
Commit message (Collapse)AuthorAgeFilesLines
* MFC r284915:hselasky2015-10-081-23/+64
| | | | | | | | | | | | | | | | | Make the system queue header file fully usable within C++ programs by adding macros to define class lists. This change is backwards compatible for all use within C and C++ programs. Only C++ programs will have added support to use the queue macros within classes. Previously the queue macros could only be used within structures. The queue.3 manual page has been updated to describe the new functionality and some alphabetic sorting has been done while at it. Differential Revision: https://reviews.freebsd.org/D2745 PR: 200827 (exp-run)
* MFC r281605,281768:brooks2015-04-211-2/+2
| | | | | | | | r281605: Fix a minor function definition inconsistancy. r281768: Bump doc date missed in r281605.
* Add new FOREACH_FROM variants of the queue(3) FOREACH macros which canlstewart2013-06-181-1/+151
| | | | | | | | | | | optionally start the traversal from a previously found element by passing the element in as "var". Passing a NULL "var" retains the same semantics as the regular FOREACH macros. Kudos to phk for suggesting the "FROM" suffix instead of my original proposal. Reviewed by: jhb (previous version), rpaulo MFC after: 1 week
* Start sentences on new lines.eadler2013-05-091-2/+4
|
* Implement LIST_PREV().ed2012-09-121-3/+23
| | | | | | | | | | | | | | | | | | | | | | | Regular LISTs have been implemented in such a way that the prev-pointer does not point to the previous element, but to the next-pointer stored in the previous element. This is done to simplify LIST_REMOVE(). This macro can be implemented without knowing the address of the list head. Unfortunately this makes it harder to implement LIST_PREV(), which is why this macro was never here. Still, it is possible to implement this macro. If the prev-pointer points to the list head, we return NULL. Otherwise we simply subtract the offset of the prev-pointer within the structure. It's not as efficient as traversing forward of course, but in practice it shouldn't be that bad. In almost all use cases, people will want to compare the value returned by LIST_PREV() against NULL, so an optimizing compiler will not emit code that does more branching than TAILQs. While there, make the code a bit more readable by introducing __member2struct(). This makes STAILQ_LAST() far more readable. MFC after: 1 month
* Fix a little typo and get rid of a cryptic description by aligning therse2011-09-021-2/+2
| | | | | | text to the remaining description. Approved by: re
* Note that the _SWAP operation is supported for all list/queue types.mdf2011-05-131-2/+40
| | | | | | | | Also place STAILQ_REMOVE_HEAD in alphabetical order. Lastly, document the _SWAP macros. PR: kern/143033 MFC after: 1 week
* Remove a bullet point that appears to have been accidentally inserted twice.gavin2011-01-111-1/+0
| | | | | | | It has also been included within the feature lists to which it is relevant. Submitted by: tobez MFC after: 1 week
* Cross reference tree(3) and queue(3).simon2010-07-181-0/+2
| | | | MFC after: 1 week
* Fix typo.brueffer2009-11-171-1/+1
| | | | | | PR: 140615 Submitted by: Andrius Morkunas <hinokind@gmail.com> MFC after: 3 days
* Rename the queue macros I introduced last year.ed2009-05-271-20/+20
| | | | | | | | | | | | | | | | Last year I added SLIST_REMOVE_NEXT and STAILQ_REMOVE_NEXT, to remove entries behind an element in the list, using O(1) time. I recently discovered NetBSD also has a similar macro, called SLIST_REMOVE_AFTER. In my opinion this approach is a lot better: - It doesn't have the unused first argument of the list pointer. I added this, mainly because OpenBSD also had it. - The _AFTER suffix makes a lot more sense, because it is related to SLIST_INSERT_AFTER. _NEXT is only used to iterate through the list. The reason why I want to rename this now, is to make sure we don't release a major version with the badly named macros.
* Introduce REMOVE_NEXT() macro's for SLIST and STAILQ.ed2008-05-221-0/+20
| | | | | | | | | | | | | | | Even though single linked lists allow items to be removed at constant time (when the previous element is known), the queue macro's don't allow this. Implement new REMOVE_NEXT() macro's. Because the REMOVE() macro's also contain the same code, make it call REMOVE_NEXT(). The OpenBSD version of SLIST_REMOVE_NEXT() needs a reference to the list head, even though it is unused. We'd better mimic this. The STAILQ version also needs a reference to the list. This means the prototypes of both macro's are the same. Approved by: philip (mentor) PR: kern/121117
* Don't imply O(n) removal for the doubly linked data structures.obrien2007-11-021-2/+8
|
* Markup fixes.ru2006-09-181-1/+1
|
* The removal of CIRCLEQ left four queue macros. One sentence was missedemaste2006-03-251-1/+1
| | | | | | | | in the man page update. PR: docs/94938 Submitted by: Ed Schouten <ed@fxq.nl> MFC After: 3 days
* Typesetting fix for -r1.137.mckusick2006-03-241-2/+4
| | | | | | | If a tail queue is empty the return value of TAILQ_LAST is not undefined, it is NULL. Submitted by: Ruslan Ermilov <ru@FreeBSD.org>
* If a tail queue is empty the return value is notmckusick2006-03-221-2/+2
| | | | undefined, it is NULL.
* Remove a spurious newline. The TAILQ_INIT() is part of the 'faster tailqjhb2005-10-171-1/+0
| | | | | | deletion' example. MFC after: 1 week
* Some grammar, spelling, and mdoc(7) fixes. No content changes.trhodes2004-12-291-1/+1
| | | | | PR: 75581 Submitted by: Nobuyuki Koganemaru n-kogane@syd.odn.ne.jp (original version)
* mdoc(7) fixes.ru2004-07-071-1/+1
|
* Spelling fixes.mpp2004-06-211-1/+1
|
* Add safe _FOREACH iterators to the rest of the queue.h types.kan2003-08-141-0/+76
|
* Document LIST_FOREACH_SAFE in queue(3).bmilekic2003-08-131-1/+24
| | | | | Asked with "please" by Ruslan Ermilov. I've always had a weakness for "please".
* Document STAILQ_CONCAT and TAILQ_CONCAT.tmm2002-04-171-0/+24
| | | | | | | PR: 20024 Submitted by: Tony Finch <dot@dotat.at> (TAILQ_CONCAT, slightly changed by me) Reviewed by: ru (earlier version)
* mdoc(7) police: tidy up previous delta.ru2002-01-091-2/+4
|
* Document some behaviour I'm depending on.julian2001-12-281-0/+2
| | | | (TAILQ_FOREACH leaves the variable NULL if there were no more to do)
* mdoc(7) police: Use the new .In macro for #include statements.ru2001-10-011-1/+1
|
* STAILQ_LAST() macro takes 3 arguments, not 1.sobomax2001-08-211-1/+1
|
* Removed whitespace at end-of-line; no content changes. I simply didschweikh2001-07-141-2/+2
| | | | | | | | | | cd src/share; find man[1-9] -type f|xargs perl -pi -e 's/[ \t]+$//' BTW, what editors are the culprits? I'm using vim and it shows me whitespace at EOL in troff files with a thick blue block... Reviewed by: Silence from cvs diff -b MFC after: 7 days
* mdoc(7) police: removed HISTORY info from the .Os call.ru2001-07-101-1/+1
|
* Remove the last remnants of circle queues.dd2001-03-151-6/+5
| | | | | | PR: 25184 Submitted by: Alex Kapranoff <alex@kapran.bitmcnit.bryansk.su> Approved by: nik
* Remove comma after final .Nm entry before .Ndben2000-12-301-1/+1
|
* CIRCLEQs are a disgrace to everything Knuth taught us in Volume 1 Chapter 2.phk2000-12-291-220/+3
| | | | | | Retire them before anybody starts to use them again. Use TAILQ instead, it provides the same functionality.
* Manpage incorrectly states that STAILQ_REMOVE_HEAD takes an argalfred2000-11-091-3/+1
| | | | | called 'elm'. It doesn't take an arg 'elm', it simply removes the element at the head of the list.
* Fix minor typo.markm2000-07-271-1/+1
|
* (1) document *_HEAD_INITIALIZERjake2000-06-101-21/+54
| | | | | | | (2) fix a STAILQ_HEAD that should have been STAILQ_FIRST Requested by: (1) bde (2) W Gerald Hicks <jhix@mindspring.com>
* Document TAILQ_FOREACH_REVERSE() and CIRCLEQ_FOREACH_REVERSE() macros.archie2000-05-011-1/+24
| | | | Submitted by: Jake Burkholder <jburkhol@home.com>
* Update STAILQ example to use STAILQ_REMOVE_HEAD instead ofjhb2000-03-271-1/+1
| | | | | | | TAILQ_REMOVE_HEAD. PR: docs/17590 Submitted by: Benno Rice <benno@netizen.com.au>
* Sync with reality.phantom1999-12-191-26/+167
| | | | | PR: docs/15036 Submitted by: Jake Burkholder <jburkhol@home.com>
* $Id$ -> $FreeBSD$peter1999-08-281-1/+1
|
* Spelling corrections.jkoshy1998-06-061-2/+2
| | | | | PR: 6868 Submitted by: Josh Gilliam <josh@quick.net>
* Fixed wrong number of args in STAILQ_REMOVE_HEAD() in synopsis.bde1997-03-191-2/+2
|
* The CIRCLEQ_ENTRY example was wrong. Part of PR# 2917.mpp1997-03-091-2/+2
|
* add missing cvs Id lines.jmg1997-03-071-0/+1
|
* Minor mdoc cleanup.mpp1997-01-311-15/+15
|
* Add SLIST_EMPTY, SLIST_FIRST, SLIST_NEXT.phk1996-12-291-0/+6
| | | | | Is it time to split this into one "intro" type and a number of detailed pages ?
* Use the .Bx macro where appropriate.mpp1996-08-221-1/+2
|
* Another man page with a messed up .Dd line.mpp1996-07-111-1/+1
|
* Document 5 new macros in TAILQ family.phk1996-04-081-5/+32
|
* Update the queue man page for the new SLIST and STAILQ macros.gibbs1996-03-311-14/+331
|
OpenPOWER on IntegriCloud