svn commit: r329587 - head/stand/lua
Kyle Evans
kevans at freebsd.org
Mon Feb 19 22:13:53 UTC 2018
On Mon, Feb 19, 2018 at 4:00 PM, Alexander Nasonov <alnsn at yandex.ru> wrote:
> Kyle Evans wrote:
>> + -- Swap the first two menu items on single user boot
>> + if (core.isSingleUserBoot()) then
>> + local multiuser = menu_entries[1];
>> + local singleuser = menu_entries[2];
>> +
>> + menu_entries[2] = multiuser;
>> + menu_entries[1] = singleuser;
>> + end
>
> -- Swap the first two menu items on single user boot
> if core.isSingleUserBoot() then
> menu_entries[1], menu_entries[2] =
> menu_entries[2], menu_entries[1]
> end
>
Noted. I ended up expanding this section a little bit later (see:
r329593) and I'm not sure how I feel about the look of this one:
-- Shallow copy the table
menu_entries = core.shallowCopyTable(menu_entries);
menu_entries[1], menu_entries[2] = menu_entries[2],
menu_entries[1];
menu_entries[1].name, menu_entries[2].name =
menu_entries[1].alternate_name,
menu_entries[2].alternate_name;
I'll need to sit on that one for a little bit. =)
More information about the svn-src-all
mailing list