calendar.unix: simplify current-timeval.
							parent
							
								
									332fc7bc1a
								
							
						
					
					
						commit
						e5850f93e0
					
				| 
						 | 
				
			
			@ -35,7 +35,7 @@ M: unix gmt-offset ( -- hours minutes seconds )
 | 
			
		|||
    get-time gmtoff>> 3600 /mod 60 /mod ;
 | 
			
		||||
 | 
			
		||||
: current-timeval ( -- timeval )
 | 
			
		||||
    timeval <struct> f [ gettimeofday io-error ] 2keep drop ; inline
 | 
			
		||||
    timeval <struct> [ f gettimeofday io-error ] keep ; inline
 | 
			
		||||
 | 
			
		||||
: system-micros ( -- n )
 | 
			
		||||
    current-timeval timeval>micros ;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue