Skip to content

Instantly share code, notes, and snippets.

@nathggns
Created August 29, 2011 12:22
Show Gist options
  • Select an option

  • Save nathggns/1178290 to your computer and use it in GitHub Desktop.

Select an option

Save nathggns/1178290 to your computer and use it in GitHub Desktop.
Mockup of input/output for my parser
/* Input */
foo {
bar: baz;
foo: {
baz: foo;
foo: baz;
}
foo {
bar: baz;
}
&foo {
baz: baz;
}
}
/* Expected Output */
Array (
[foo] => Array (
[bar] => baz,
[foo:] => Array (
[baz] => foo,
[foo] => baz
),
[foo] => Array (
[bar] => baz
),
[&foo] => Array (
[baz] => baz
)
)
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment