Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Apress/beginning-cpp20
/ swap
Method
swap
Examples/NoModules/Chapter 17/Ex17_04A/Stack.h:98–101 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
96
// noexcept swap member function
97
template <typename T>
98
void Stack<T>::swap(Stack& other) noexcept
99
{
100
std::swap(m_head, other.m_head);
101
}
102
103
// Conventional noexcept swap non-member function
104
template <typename T>
Callers
1
swap
Function · 0.45
Calls
1
swap
Function · 0.70
Tested by
no test coverage detected