mIRC Home    About    Download    Register    News    Help

Print Thread
#50973 23/09/03 08:27 PM
D
demitrix
demitrix
D
Other then $cr and $lf being preserved what other purposes does saving a hash in binary offer?

#50974 23/09/03 08:50 PM
Joined: Dec 2002
Posts: 1,893
O
Hoopy frood
Offline
Hoopy frood
O
Joined: Dec 2002
Posts: 1,893
I think that's the only benefit a binary file offers.

#50975 24/09/03 07:58 PM
Joined: Feb 2003
Posts: 806
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Feb 2003
Posts: 806
Anything a &binvar offers, I guess. Like preserving multiple spaces, too. But I'm not really sure if they'll be preserved when loaded as well.

Last edited by cold; 24/09/03 07:59 PM.
#50976 25/09/03 12:01 AM
Joined: Dec 2002
Posts: 2,884
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 2,884
Saving/loading a hash table as text will preserve spaces. The lack of consecutive spaces is a quirk of mIRC involving space-tokenizing lines given to it via the command line or a script file, but since each value of a hash table is saved and loaded internally the consecutive spaces aren't stripped.

#50977 27/09/03 04:08 AM
O
Olathe
Olathe
O
It also preserves NULs (ASCII 0s), which is useful if you need to use a binary file in your script correctly.

#50978 27/09/03 10:26 AM
Joined: Jan 2003
Posts: 2,125
Q
Hoopy frood
Offline
Hoopy frood
Q
Joined: Jan 2003
Posts: 2,125
Unfortunately it doesn't frown

//bset &a 1 65 0 66 | hadd -mb table item &a | echo 3 -s $hget(table,item,&b) : $bvar(&b,1-) | hsave -bo table table.hash | hload -b table table.hash | echo 4 -s $hget(table,item,&b) : $bvar(&b,1-) | .remove table.hash


Link Copied to Clipboard