chiark
/
gitweb
/
~ian
/
chiark-tcl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ulongs and ushorts
[chiark-tcl.git]
/
base
/
tables-examples.tct
diff --git
a/base/tables-examples.tct
b/base/tables-examples.tct
index 6f8755a8495d88d182bb358081c80372660458d0..37286adb6bcf5597d479aaa4dfbcb9534b59cedd 100644
(file)
--- a/
base/tables-examples.tct
+++ b/
base/tables-examples.tct
@@
-8,8
+8,8
@@
Fini hbv fini_hbv(ip, rc, &@);
Type sockaddr: SockAddr_Value @
Init sockaddr sockaddr_clear(&@);
Type sockaddr: SockAddr_Value @
Init sockaddr sockaddr_clear(&@);
-Type sockid:
int
@
-Init sockid @=-1;
+Type sockid:
DgramSockID
@
+Type ulong: unsigned long @
H-Include "hbytes.h"
H-Include "hbytes.h"
@@
-28,6
+28,18
@@
Table hbytes HBytes_SubCommand
h2raw
hex hb
=> obj
h2raw
hex hb
=> obj
+ ulong2h
+ value ulong
+ => hb
+ h2ulong
+ hex hb
+ => ulong
+ ushort2h
+ value ulong
+ => hb
+ h2ushort
+ hex hb
+ => ulong
length
v hb
=> int
length
v hb
=> int
@@
-91,5
+103,10
@@
Table dgram_socket DgramSocket_SubCommand
=> sockid
close
sock sockid
=> sockid
close
sock sockid
-# transmit
-#
+ transmit
+ sock sockid
+ data hb
+ remote sockaddr
+ on-receive
+ sock sockid
+ ?script obj