1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-09-19 16:58:48 +02:00

Use PhutilXHPASTBinary methods

Summary: Use `PhutilXHPASTBinary` methods instead of `xhpast_parse` functions. Depends on D11517.

Test Plan: N/A, this is a direct swap.

Reviewers: #blessed_reviewers, epriestley

Reviewed By: #blessed_reviewers, epriestley

Subscribers: Korvin, epriestley

Differential Revision: https://secure.phabricator.com/D11612
This commit is contained in:
Joshua Spence 2015-02-03 06:59:15 +11:00
parent 37e534c5f8
commit 7982b23eb4
4 changed files with 4 additions and 4 deletions

View file

@ -20,7 +20,7 @@ $futures = array();
foreach ($input as $file) {
$file = Filesystem::readablePath($file);
$data[$file] = Filesystem::readFile($file);
$futures[$file] = xhpast_get_parser_future($data[$file]);
$futures[$file] = PhutilXHPASTBinary::getParserFuture($data[$file]);
}
$futures = id(new FutureIterator($futures))

View file

@ -7,7 +7,7 @@ final class DivinerPHPAtomizer extends DivinerAtomizer {
}
protected function executeAtomize($file_name, $file_data) {
$future = xhpast_get_parser_future($file_data);
$future = PhutilXHPASTBinary::getParserFuture($file_data);
$tree = XHPASTTree::newFromDataAndResolvedExecFuture(
$file_data,
$future->resolve());

View file

@ -11,7 +11,7 @@ final class PhabricatorXHPASTViewRunController
if ($request->isFormPost()) {
$source = $request->getStr('source');
$future = xhpast_get_parser_future($source);
$future = PhutilXHPASTBinary::getParserFuture($source);
$resolved = $future->resolve();
// This is just to let it throw exceptions if stuff is broken.

View file

@ -31,7 +31,7 @@ final class PhabricatorInternationalizationManagementExtractWorkflow
foreach ($path_files as $file) {
$full_path = $root.DIRECTORY_SEPARATOR.$file;
$data = Filesystem::readFile($full_path);
$futures[$full_path] = xhpast_get_parser_future($data);
$futures[$full_path] = PhutilXHPASTBinary::getParserFuture($data);
}
}