Skip to content

Instantly share code, notes, and snippets.

@vonglasow
Created November 4, 2014 10:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vonglasow/d8bafb4f4ce7749747c4 to your computer and use it in GitHub Desktop.
Save vonglasow/d8bafb4f4ce7749747c4 to your computer and use it in GitHub Desktop.
compiler
$sampler = new \Hoa\Compiler\Llk\Sampler\Coverage(
\Hoa\Compiler\Llk\Llk::load(
new \Hoa\File\Read($file->getPathName())
),
new \Hoa\Regex\Visitor\Isotropic(
new \Hoa\Math\Sampler\Random()
)
);
$json = array();
foreach ($sampler as $value) {
$json[] = json_decode($value, true);
}
file_put_contents($jsonDir . $jsonFile, json_encode($json));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment