std::packaged_task::operator=
De cppreference.com
< cpp | thread | packaged task
![]() |
This page has been machine-translated from the English version of the wiki using Google Translate.
The translation may contain errors and awkward wording. Hover over text to see the original version. You can help to fix errors and improve the translation. For instructions click here. |
packaged_task& operator=(const packaged_task&) = delete; |
(1) | |
packaged_task& operator=(packaged_task&& rhs) |
(2) | |
1)
Opérateur d'affectation de copie est supprimée,
std::packaged_task
mouvement est seulement .Original:
Copy assignment operator is deleted,
std::packaged_task
is move-only.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
Remarque: C + 11 ne const préciser ici, c'est la defect 2067 .
Original:
Note: C++11 does not specify const here, this is the defect 2067.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
2)
Libère l'état partagé, le cas échéant, détruit la tâche antérieurement détenue, et déplace l'état partagé et la tâche appartient à
rhs
en *this. rhs
est laissé sans un état partagé et avec une tâche déplacé-de .Original:
Releases the shared state, if any, destroys the previously-held task, and moves the shared state and the task owned by
rhs
into *this. rhs
is left without a shared state and with a moved-from task.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
[modifier] Paramètres
rhs | - | l'
std::packaged_task de passer d'Original: the std::packaged_task to move fromThe text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
[modifier] Exceptions
2)[modifier] Exemple
This section is incomplete Reason: no example |