How do I use theme('links') with nested arrays?
You need to add the sub items to a 'children' key of the array. Here is an example:

$list = array(
  'item1' =&gt; t('Item 1'),
  'item2' =&gt; array(
    'data' =&gt; t('Item 2'),
    'children' =&gt; array(
      t('Item 3'),
    ),
  ),
  'item4' =&gt; t('Item 4'),
);

return theme('item_list', array('items' =&gt;  $list));