mostly comments; decided to leave layer-stack as is
parent
49f3d4bdd5
commit
ff2e90997d
|
@ -37,6 +37,9 @@ CURDIRS := $(CURDIR) $(CURDIRS)
|
|||
CURDIR := $(ROOTDIR)/lib/twi
|
||||
include $(CURDIR)/options.mk
|
||||
# -------
|
||||
CURDIR := $(ROOTDIR)/lib/data-types/list
|
||||
include $(CURDIR)/options.mk
|
||||
# -------
|
||||
CURDIR := $(ROOTDIR)/lib/layout/eeprom-macro
|
||||
include $(CURDIR)/options.mk
|
||||
# -------
|
||||
|
@ -46,9 +49,6 @@ include $(CURDIR)/options.mk
|
|||
CURDIR := $(ROOTDIR)/lib/layout/layer-stack
|
||||
include $(CURDIR)/options.mk
|
||||
# -------
|
||||
CURDIR := $(ROOTDIR)/lib/data-types/list
|
||||
include $(CURDIR)/options.mk
|
||||
# -------
|
||||
CURDIR := $(firstword $(CURDIRS))
|
||||
CURDIRS := $(wordlist 2,$(words $(CURDIRS)),$(CURDIRS))
|
||||
|
||||
|
|
|
@ -10,13 +10,11 @@
|
|||
*
|
||||
* Prefix: `list__`
|
||||
*
|
||||
*
|
||||
* Implementation notes:
|
||||
*
|
||||
* - All functions that accept an `index` should set `index %= list->length`
|
||||
* before using it. This will make all passed indices valid. It will also
|
||||
* provide a convenient way to reference the last element of a list, by
|
||||
* passing `-1` as the index (as in Python).
|
||||
* - All functions that accept an `index` set `index %= list->length` before
|
||||
* using it. This will make all passed indices valid. It will also provide
|
||||
* a convenient way to reference the last element of a list, by passing `-1`
|
||||
* as the index (as in Python).
|
||||
*/
|
||||
|
||||
|
||||
|
|
|
@ -6,6 +6,15 @@
|
|||
|
||||
/** description
|
||||
* Implements the layer-stack defined in "../layer-stack.h"
|
||||
*
|
||||
* Notes:
|
||||
* - This would be relatively trivial to implement using
|
||||
* ".../lib/data-types/list.h"; but it was written before bringing linked
|
||||
* lists back into the code base, and while I'm sure it takes more PROGMEM to
|
||||
* keep doing it this way, it uses less SRAM, and is also probably faster on
|
||||
* average. I also think it's a nice example of how to resize arrays in C
|
||||
* based on demand. So, those things considered, it seems better not to
|
||||
* rewrite it.
|
||||
*/
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue