Skip to content

Commit

Permalink
some small docblock updates
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremeamia committed Feb 5, 2014
1 parent 0bbf5e0 commit 841cdcc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/SuperClosure/ClosureParser/Ast/AstParser.php
Expand Up @@ -26,6 +26,7 @@ public function getDefaultOptions()

public function parse($closure)
{
// Prepare the closure and reflection objects for parsing
$closure = $this->prepareClosure($closure);
$closureReflection = $closure->getReflection();

Expand All @@ -37,6 +38,7 @@ public function parse($closure)
// @codeCoverageIgnoreEnd
}

// Do a second traversal through the closure's AST to apply additional transformations
$closureLocation = $closureLocator->getLocation();
if ($this->options[Options::HANDLE_MAGIC_CONSTANTS]) {
// Resolve additional nodes by making a second pass through just the closure's nodes
Expand All @@ -46,7 +48,7 @@ public function parse($closure)
$closureAst = $closureAst[0];
}

// Get closure context data
// Get and return closure context data
$astPrinter = new \PHPParser_PrettyPrinter_Default();
$closureCode = $astPrinter->prettyPrint(array($closureAst));
$closureVariables = $this->determineVariables($closureAst, $closureReflection);
Expand Down
1 change: 1 addition & 0 deletions src/functions.php
Expand Up @@ -2,6 +2,7 @@

namespace
{
// This alias exists to provide backwards compatibility with version 1.0 of SuperClosure.
class_alias('SuperClosure\SerializableClosure', 'Jeremeamia\SuperClosure\SerializableClosure');
}

Expand Down

0 comments on commit 841cdcc

Please sign in to comment.