knit icon indicating copy to clipboard operation
knit copied to clipboard

Feature request: +=

Open vicencb opened this issue 2 years ago • 0 comments

Like :=, this is just syntactic sugar to make makefile writers more comfortable

-- declare string
local flags = '-Wall'
-- declare table
local src = {}
-- when the LHS of += is a string, append one space and RHS
flags += -Os
-- when the LHS of += is a table, append RHS converted to string
src += main.c

vicencb avatar Oct 01 '23 17:10 vicencb