提交 bdb9f59c authored 作者: Guillaume Alain's avatar Guillaume Alain

minor edits for Arnaud's suggestions on the pull request

上级 a15c4841
......@@ -298,7 +298,7 @@ You can try it as follows:
Example for properties of a Op
==========
==============================
We can modify the previous piece of code in order to demonstrate
the usage of the :attr:`__props__` attribute.
......@@ -342,6 +342,7 @@ and ``b`` are equal.
The use of :attr:`__props__` saves
the user the trouble of implementing :func:`__eq__` and :func:`__hash__` manually.
It also generates a default :func:`__str__` method that prints the attribute names and their values.
We can test this by running the following segment:
......@@ -363,12 +364,6 @@ We can test this by running the following segment:
assert numpy.allclose(4 * inp + 5, f(inp))
assert numpy.allclose(2 * inp + 3, g(inp))
How To Test it
==============
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论