diff options
| author | Shinya Sato <shinnya.sato@gmail.com> | 2021-12-21 01:13:02 +0900 |
|---|---|---|
| committer | Shinya Sato <shinnya.sato@gmail.com> | 2021-12-21 01:13:02 +0900 |
| commit | b2838090e35634aac6bb412b9394c16aca4c1d05 (patch) | |
| tree | b76e5684733ff042b4fbd2cebfd85ab1eb6578c2 | |
| parent | 7663449bb9fc1f1f3967bbc2560fc94f1e19edba (diff) | |
| download | inpla-b2838090e35634aac6bb412b9394c16aca4c1d05.tar.gz inpla-b2838090e35634aac6bb412b9394c16aca4c1d05.zip | |
Update README.md
Diffstat (limited to '')
| -rw-r--r-- | README.md | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -687,13 +687,13 @@ Of course, it works as an addition operation on two attributes: >>> ``` -However, it can cause runtime error because the argument `b` of `add` can be not connected to an attribute when the rule is invoked. For instance, we take the following computation: +However, it can cause runtime error because the second argument `int b` of `add` can haven't been connected to an attribute when the rule is invoked. For instance, we take the following computation: ``` >>> add(r, b)~3, add(b, 10)~20; ``` -If the `add(r, b)~3` is operated first, it causes runtime error because the `b` is not connected to an attribute, though it is OK if the `add(b, 10)~20` is operated first. To prevent this fragile situation, **we have to have extra rules to ensure that every port with the modifier `int` connects to an attribute**. For the rule of the `add` agent, the following is a **solution** to have the extra rule where `addn` is introduced as an extra agent: +If the `add(r, b)~3` is operated first, it causes runtime error because the `b` has not been connected to an attribute, whereas it is OK if the `add(b, 10)~20` is operated first. To prevent this fragile situation, **we have to have extra rules to ensure that every port with the modifier `int` has been connected to an attribute**. For the rule of the `add` agent, the following is a **solution** to have the extra rule (the `addn` is introduced as the extra agent): ``` >>> add(result, b) >< (int a) => addn(result, a) ~ b; |
