Jon*_*Mee 2 c++ decomposition auto c++17
auto [x, y] = div_t{ 1, 0 };
Run Code Online (Sandbox Code Playgroud)
从答案的代码看起来这像是tie对div_t结构.我希望有人能解释这里发生的事情.完整的功能代码如下:
constexpr bool first_quot() {
auto [x, y] = std::div_t{1, 0};
(void)y;
return x;
}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
125 次 |
| 最近记录: |