STD::_MU(3cxx)
π NAME π
std::_Mu< _Arg, _IsBindExp, _IsPlaceholder > β bestie, this is the little secret helper class that does the behind-the-scenes mapping magic for bind(). No cap.
Oh and hii, welcome to the std::_Mu< _Arg,...IsPlaceholder >(3cxx) page π
yes the man page name is giving "template soup" but we're gonna vibe through it together.
β¨ SYNOPSIS β¨
Detailed Description
Okay so first, the receipt. The actual declaration is this, and you're gonna want to copy it exactly:
template<typename _Arg, bool _IsBindExp = is_bind_expression<_Arg>::value,
bool _IsPlaceholder = (is_placeholder<_Arg>::value > 0)>
class std::_Mu< _Arg, _IsBindExp, _IsPlaceholder >
So what does this cutie actually do? It maps an argument to bind() into an actual argument for the bound function object β that's [func.bind.bind]/10 if you wanna go read the standard, iykyk π
And here's the thing you NEED to know, no skipping: only the first parameter should be specified. Like, only _Arg. The rest of them? They're just there so the implementation can figure out which of the various implementations it's dealing with. Not your job, babe, that's the compiler's job π«Ά
Now for the iconic part. Even though this class is a function object, it is not entirely normal β and honestly? relatable. It takes only two parameters, regardless of how many parameters got passed to the bind expression. The way that works is:
- The first parameter is the bound argument π
- The second parameter is a tuple containing references to the rest of the arguments π
Periodt. That's the whole vibe check.
πΈ Author πΈ
This whole thing was generated automatically by Doxygen for libstdc++ from the source code. Not a human typing it out at 3am β the robot did it. Slay, I guess π€β¨
And that's the page, bestie! This one came from libstdc++, generated by Doxygen straight from the source code, and the footer it left us with literally reads libststd::_Mu< _Arg,...IsPlaceholder >(3cxx) β yeah the title got a lil smooshed into the page number, iconic typo energy fr fr ππΈ Go forth and let _Mu do its mysterious little mapping thing behind the scenes, you don't gotta understand all three template params, you just gotta pass the first one ππ
π¦ where this page comes from
- ubuntu noble: libstdc++-10-doc 10.5.0-4ubuntu2
- ubuntu noble: libstdc++-10-doc 10.5.0-4ubuntu2.1
- ubuntu noble: libstdc++-11-doc 11.4.0-9ubuntu1
- ubuntu noble: libstdc++-11-doc 11.5.0-1ubuntu1~24.04.1
- ubuntu questing: libstdc++-11-doc 11.5.0-7ubuntu1
- ubuntu questing: libstdc++-11-doc 11.5.0-7ubuntu1.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms