I want to use this in a macro but wondering if there
was a less clumsy way of writing it?
ifb <axt>
ifnb <fl>
dw $+2
else
dw cfadr
endif
else
dw cfadr
endif
On Saturday, September 11, 2021 at 1:28:35 PM UTC-4, dxforth wrote:
I want to use this in a macro but wondering if there
was a less clumsy way of writing it?
ifb <axt>
ifnb <fl>
dw $+2
else
dw cfadr
endif
else
dw cfadr
endif
Not completely sure, but you may want to consider
local v
v set cfaddr
ifnb <axt>
ifb <fl>
v set $+2
endif
endif
dw v
Gets rid of the else clauses.
On 14/09/2021 01:48, [email protected] wrote:
On Saturday, September 11, 2021 at 1:28:35 PM UTC-4, dxforth wrote:
I want to use this in a macro but wondering if there
was a less clumsy way of writing it?
ifb <axt>
ifnb <fl>
dw $+2
else
dw cfadr
endif
else
dw cfadr
endif
Not completely sure, but you may want to consider
local v
v set cfaddr
ifnb <axt>
ifb <fl>
v set $+2
endif
endif
dw v
Gets rid of the else clauses.
It's one line shorter, however the logic is easier to follow.
Thanks.
| Sysop: | Keyop |
|---|---|
| Location: | Huddersfield, West Yorkshire, UK |
| Users: | 715 |
| Nodes: | 16 (2 / 14) |
| Uptime: | 23:51:51 |
| Calls: | 12,105 |
| Calls today: | 5 |
| Files: | 15,006 |
| Messages: | 6,518,148 |