It's a similar problem, in your case @path should hold references of the current parent containers.
The parsed indentation level gives you the index for @path.
Either add the current element to the correct parent container or expand path.
HTH
Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery
FootballPerl is like chess, only without the dice
In reply to Re: Parsing by indentation
by LanX
in thread Parsing by indentation
by llarochelle
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |