X-Git-Url: https://git.madduck.net/etc/awesome.git/blobdiff_plain/92d17d289c64eb8416a881e4fe0113a64b534003..ee84995734048a20e920badafb305c15556c3e6c:/helpers.lua diff --git a/helpers.lua b/helpers.lua index 4d75f7b..d6f6b3c 100644 --- a/helpers.lua +++ b/helpers.lua @@ -12,7 +12,8 @@ local io = { lines = io.lines, open = io.open } local pairs = pairs local rawget = rawget -local table = { sort = table.sort } +local table = { sort = table.sort, unpack = table.unpack } +local unpack = unpack or table.unpack -- lua 5.1 retro-compatibility -- Lain helper functions for internal use -- lain.helpers @@ -186,7 +187,7 @@ function helpers.trivial_partition_set(set) return ss end --- creates the powerset of a given set +-- create the powerset of a given set function helpers.powerset(s) if not s then return {} end local t = {{}}