Skip to content

Commit

Permalink
'for' seems better than 'while'
Browse files Browse the repository at this point in the history
  • Loading branch information
andreakarasho committed Jun 8, 2024
1 parent bab690d commit 5423de3
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions tools/TinyEcs.Generator/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ public partial {className}
{fieldList}
while (count - 4 > 0)
for (; count - 4 > 0; count -= 4)
{{
fn({signCallback});
{advanceField}
Expand All @@ -355,15 +355,12 @@ public partial {className}
fn({signCallback});
{advanceField}
count -= 4;
}}
while (count > 0)
for (; count > 0; count -= 1)
{{
fn({signCallback});
{advanceField}
count -= 1;
}}
}}
Expand Down

0 comments on commit 5423de3

Please sign in to comment.