yyd 0.1.0

Template combinators

To use this package, run the following command in your project's root directory:

Manual usage
Put the following dependency into your project's dependences section:

yYd - Mixin template combinators for D

Sequential combinators for templates.

The library allows us to bind to compiler constructs as identifiers using templates and mixin templates.

identity!T :== alias _ = T

evaluate!T :== enum _ = T

partial!(T, U...) :== (V...) => T!(U,V)

rpartial!(T, U...) :== (V...) => T!(V,U)


Many of the mixin templates start with a single underscore _ . This indicates that this mixin template defines a single identifier in scope comprising an underscore which represents an alias binding to the combinator.

The underscore may be an alias, and might be a template or a mixin template.

So we can pass an identifier to a mixin template as an argument to a combinator template. The template then instantiates the mixin as defined by its semantics of the combinator.

So for example to iterate an AliasSeq

mixin template mixinTemplate(T) { ... }

"mixinTemplate" will be applied for each member of the sequence.

Some of the conditional templates only bind the underscore alias if the condition is met, otherwise is(_!()) will evaluate to false.

  • logicfish
0.2.0 2023-Feb-09
0.1.1 2023-Feb-02
0.1.0 2023-Feb-01
~main 2023-Oct-22
Show all 4 versions
Download Stats:
  • 0 downloads today

  • 0 downloads this week

  • 0 downloads this month

  • 27 downloads total

Short URL: