<?php
/**
* Print an ast array for debugging purposes, to help you figure out what AST keys to use with non-debug templates
*
* @usage `@\ast(class.Tlf\Scrawl\Extension\Notes.methods.scan_file_processed.docblock, ast/debug)` - Any AST key for the first param is valid, such as `class.CLASS_NAME` only
* @output array of the AST pointed to by the given key.
*
* @param $args[0] the key pointing to the ast, must begin with `class.ClassName`
* @param $args[1] string or array ... whatever the key pointed at
* @param $args[2] is the AstVerb class instance
*/
$key = $args[0];
ob_start();
var_dump($args[2], true);
$output = ob_get_clean();
// echo "---DEBUG_SCRAWL_AST_VERB---"
//"\nKey:$key"
//."\nAST Value: \n".print_r($args[1],true);
//."\nAST Verb class instances: \n".$output;
echo
"\nKey:$key"
."\nAST Value: \n".print_r($args[1],true);