Move querysort into its own file
Remove superfluous braces
Use VCL_xxx types and add missing matching prototypes

While here unify check.
Add real2time, time2integer and time2real to the std vmod

As discussed on the latest VDD.