Re: Needed enhancement for documentable unittest

2013-03-30 Thread Timothee Cour
Examples moved out to unittests: Cons: doc gets spread out in unittests Pros: much easier to write those examples, no quoting necessary, code is syntax highlighted, compilable and ran by unittest suite. Much better than the hack of embedding examples inside doc For proof, see how many embedded exam

Re: Needed enhancement for documentable unittest

2013-03-29 Thread Andrej Mitrovic
On 3/25/13, Jens Mueller wrote: > I thought the example (embedded code) is not being moved into unittests > rather it's copied. No, that's not how it works. Code in in documented unittests is moved into Example sections in ddoc output. So the new definition of map would look like: /** $(D auto

Re: Needed enhancement for documentable unittest

2013-03-25 Thread Jens Mueller
Andrej Mitrovic wrote: > On 2/7/13, Andrei Alexandrescu wrote: > > I'm very happy that this will be part of the upcoming release: > > https://github.com/D-Programming-Language/dmd/pull/1342 (see also > > http://d.puremagic.com/issues/show_bug.cgi?id=2630) allows defining > > unittests that simulta

Re: Needed enhancement for documentable unittest

2013-03-24 Thread Andrej Mitrovic
On 2/7/13, Andrei Alexandrescu wrote: > I'm very happy that this will be part of the upcoming release: > https://github.com/D-Programming-Language/dmd/pull/1342 (see also > http://d.puremagic.com/issues/show_bug.cgi?id=2630) allows defining > unittests that simultaneously work as documentation. Th