PageRenderTime 2ms queryTime 36ms sortTime 0ms getByIdsTime 2ms findMatchingLines 3ms

2+ results for 'while !isfinite(x)' (2 ms)

Not the results you expected?
RandomizedPropertyTest.jl https://git.sr.ht/~quf/RandomizedPropertyTest.jl/ | Julia | 443 lines
                    
225      x = $TF(NaN)
                    
226      while !isfinite(x)
                    
227        x = reinterpret($TF, rand(rng, $TI)) # generate a random int and pretend it is a float.
                    
428  z = Complex{T}(Inf, Inf)
                    
429  while !(abs(z - z₀) < r)
                    
430    z = r * complex(2rand(rng, T)-1, 2rand(rng, T)-1) + z₀
                    
                
palette.c https://git.sr.ht/~coco/imscript/ | C | 423 lines
                    
152	static float nodes[4*PALSAMPLES];
                    
153	while(fgets(buf, bufsize, f) && nnodes < PALSAMPLES) {
                    
154		//fprintf(stderr, "s = \"%s\"\n", buf);
                    
172	static float nodes[4*PALSAMPLES];
                    
173	while(fgets(buf, bufsize, f) && nnodes < PALSAMPLES) {
                    
174		//fprintf(stderr, "s = \"%s\"\n", buf);
                    
238	}
                    
239	if (!isfinite(x)) {
                    
240		rgb[0] = rgb[1] = rgb[2] = 255;
                    
                
 

Source

Language