Use var everywhere

This commit is contained in:
ScottNZ
2014-06-15 22:17:34 +12:00
parent dbffce81a6
commit 90894aa03e
99 changed files with 312 additions and 312 deletions

View File

@@ -24,7 +24,7 @@ namespace OpenRA
var regex = new Regex("([^=]+)=(.*)");
foreach (var s in src)
{
Match m = regex.Match(s);
var m = regex.Match(s);
if (!m.Success)
continue;

View File

@@ -71,7 +71,7 @@ namespace OpenRA.Support
public IEnumerable<double> Samples()
{
int n = head;
var n = head;
while (n != tail)
{
--n;
@@ -82,8 +82,8 @@ namespace OpenRA.Support
public double Average(int count)
{
int i = 0;
int n = head;
var i = 0;
var n = head;
double sum = 0;
while (i < count && n != tail)
{
@@ -98,7 +98,7 @@ namespace OpenRA.Support
{
get
{
int n = head;
var n = head;
if (--n < 0) n = samples.Length - 1;
return samples[n];
}