[m-rev.] for review: implement io__file_modification_time_2 in C#

Peter Moulder Peter.Moulder at infotech.monash.edu.au
Tue Nov 4 17:58:15 AEDT 2003


On Sat, Nov 01, 2003 at 04:17:49PM +1100, Fergus Henderson wrote:
> Index: library/time.m
> [...]
> @@ -270,7 +271,7 @@
>  :- pragma foreign_proc("C#", time__c_clocks_per_sec(Ret::out),
>  	[will_not_call_mercury, promise_pure],
>  "{
> -	// XXX TicksPerSecond is long in .NET!
> +	// TicksPerSecond is guaranteed to be 10,000,000
>  	Ret = (int) System.TimeSpan.TicksPerSecond;
>  }").

Such comments are usually better written as assertions.  If
TicksPerSecond is a class constant, then the assertion should disappear
at compile time.

Same goes for time__clk_tck.

pjm.
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list