Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Interlock.Add() for double [duplicate]

.Net framework has Interlocked.Add() methods only for int and long. But I need Interlock.Add() for double type. How can I do that?

like image 200
user Avatar asked Jul 01 '13 04:07

user


1 Answers

It is not possible, which you can read in this question on stackoverflow. It also provides an article about it:

Why is there no overload of Interlocked.Add that accepts Doubles as parameters?

like image 198
ian Avatar answered Oct 14 '22 10:10

ian