Ppi-based unmatched-brace-finder
my $brace = PPIx::EditorTools::FindUnmatchedBrace->new->find( code => "package TestPackage;\nsub x { 1;\n" ); my $location = $brace->element->location;
Finds the location of unmatched braces in a \*(C`PPI::Document\*(C'.
Constructor. Generally shouldn't be called with any arguments. Accepts either a \*(C`PPI::Document\*(C' to process or a string containing the code (which will be converted into a \*(C`PPI::Document\*(C') to process. Finds the location of unmatched braces. Returns a \*(C`PPIx::EditorTools::ReturnObject\*(C' with the unmatched brace (a \*(C`PPI::Structure::Block\*(C') available via the \*(C`element\*(C' accessor. If there is no unmatched brace, returns undef.
This class inherits from \*(C`PPIx::EditorTools\*(C'. Also see App::EditorTools, Padre, and \s-1PPI\s0.