Fixed unnecessary zero-length array allocations
Changed all currently present zero-length array allocations in the codebase to use `Array.Empty` instead.
This commit is contained in:
@@ -54,7 +54,7 @@ namespace OpenRA.Mods.Common.Activities
|
||||
aircraft = self.Trait<Aircraft>();
|
||||
this.target = target;
|
||||
this.offset = offset;
|
||||
this.clearCells = clearCells ?? new CPos[0];
|
||||
this.clearCells = clearCells ?? Array.Empty<CPos>();
|
||||
this.landRange = landRange.Length >= 0 ? landRange : aircraft.Info.LandRange;
|
||||
this.targetLineColor = targetLineColor;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user