Page MenuHomeWildfire Games

Refactor UpdateMessageSubscriptions in CCmpRangeOverlayRenderer
ClosedPublic

Authored by Silier on Sep 15 2020, 12:51 PM.

Details

Reviewers
bb
Group Reviewers
Restricted Owners Package(Owns No Changed Paths)
Commits
rP24072: Refactor UpdateMessageSubscriptions in CCmpRangeOverlayRenderer
Summary

rewrite 3 ifs to 1 if
merge 2 member variables into 1 member variable
remove 2 function local variables
save one call for CComponentManager as both ifs would or execute or not

code is shorter and looks nicer

Test Plan

confirm logic is the same

Diff Detail

Repository
rP 0 A.D. Public Repository
Branch
/ps/trunk
Lint
Lint OK
SeverityLocationCodeMessage
Errorsource/simulation2/components/CCmpRangeOverlayRenderer.cpp:45CPPCheckBear (unknownMacro)CPPCheckBear (unknownMacro)
Unit
No Unit Test Coverage
Build Status
Buildable 13182
Build 26250: Vulcan BuildJenkins
Build 26249: Vulcan Build (macOS)Jenkins
Build 26248: Vulcan Build (Windows)Jenkins
Build 26247: arc lint + arc unit

Event Timeline

Silier created this revision.Sep 15 2020, 12:51 PM
Owners added a subscriber: Restricted Owners Package.Sep 15 2020, 12:51 PM
Silier published this revision for review.Sep 15 2020, 12:51 PM
Silier added a reviewer: Restricted Owners Package.

Successful build - Chance fights ever on the side of the prudent.

builderr-release-macos.txt
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: ../../../binaries/system/libsimulation2.a(precompiled.o) has no symbols

Link to build: https://jenkins.wildfiregames.com/job/macos-differential/1549/display/redirect

bb accepted this revision.Sep 21 2020, 2:12 PM
bb added a subscriber: bb.

Digging back to D555, this code must be ccmpSelectable copy-pasta

Front doesn't fall

source/simulation2/components/CCmpRangeOverlayRenderer.cpp
1

Why didn't the linter work?

This revision is now accepted and ready to land.Sep 21 2020, 2:12 PM
Silier added a subscriber: Itms.Sep 21 2020, 2:16 PM
Silier added inline comments.
source/simulation2/components/CCmpRangeOverlayRenderer.cpp
1

ping @Itms

This revision was automatically updated to reflect the committed changes.