Results 26 comments of Ján

> Otherwise many of our examples require a distracting shim. I added some magic to automatically strip the common boilerplate (@example-start and @example-end can be used to override it but...

It should be possible to get it down to 2 files per example I think, which seems reasonable to me. It would be either - the code (.hack) + expected...

I'm thinking of doing this along with #865. My current plan: - rename everything from .php -> .hack - `the-file.hack.hhconfig` -- make optional, only needed if non-empty - require exactly...

That's how they work currently, but my proposal is to change that so that we always need just 1 file. Current: - .expect is required, .no.auto.output is optional - .expect...

> how do .expectf and .expectre fit in? I think we want to require exactly one of all the alternatives: expect / expectf / expectre / typechecker.expect > you'll probably...

We already support a few magic substrings like that: https://github.com/hhvm/user-documentation/blob/master/tests/ExamplesTest.php#L21

Should we add `addExtends` and `setExtends` as aliases (for CodegenInterface only) to those functions?

I'm looking into this now; I like the idea of extracting the examples from the .md files -- ideally, this wouldn't just be the example code, but everything else related...

> This can also be autogenerated - see out2expectf.py in the HHVM tree Good idea, it doesn't look like it can handle everything but I like it for handling common...

> I think this is defined here https://docs.hhvm.com/hack/functions/introduction#variadic-functions. Good catch, I probably missed that page when I opened this issue. But the important part that's missing there is that the...