Skip to content

Instantly share code, notes, and snippets.

@majiang
Created May 15, 2013 09:02
Show Gist options
  • Save majiang/5582602 to your computer and use it in GitHub Desktop.
Save majiang/5582602 to your computer and use it in GitHub Desktop.
module map;
auto map(FT, ATR)(FT f, ATR x)
{
struct R
{
auto front()
{
return f(x.front);
}
void popFront()
{
x.popFront;
}
bool empty()
{
return x.empty();
}
}
return R();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment