提交 9655d978 authored 作者: Brandon T. Willard's avatar Brandon T. Willard 提交者: Brandon T. Willard

Add a note about the indestructible tag in inplace.txt

上级 b0a1d33c
...@@ -170,6 +170,9 @@ first input (position 0). ...@@ -170,6 +170,9 @@ first input (position 0).
myop.destroy_map = {0: [0, 1]} # first output operates inplace on both the first and second input myop.destroy_map = {0: [0, 1]} # first output operates inplace on both the first and second input
# unlike for views, the previous line is legal and supported # unlike for views, the previous line is legal and supported
.. note::
``DestroyHandler`` provides a hackish means of specifying that a variable cannot be
"destroyed" by an in-place operation: ``var.tag.indestructible = True``.
Destructive Operations Destructive Operations
====================== ======================
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论