The smallest log function

Do you need to trace your code outside Caché ? This single function allows to send strings to a log file, located in the same directory as your cache.dat.

trace(str) s fi="mylog.txt" open fi:("A"):0 i '$TEST {		open fi:("WN"):0 }	q:'$TEST use fi w $ZD($H),": ",str,! close fi	q