RLInterface is only used in main.cpp so it was pretty easy to remove the global.
Don't use std::unique_ptr.
Refs: #4211
Differential D5103
Make the RLInterface local phosit on Aug 16 2023, 10:04 PM. Authored by
Details
RLInterface is only used in main.cpp so it was pretty easy to remove the global. Refs: #4211 Run with and without the RLInterface.
Diff Detail
Event TimelineComment Actions Build failure - The Moirai have given mortals hearts that can endure. Link to build: https://jenkins.wildfiregames.com/job/macos-differential/7209/display/redirect Comment Actions Successful build - Chance fights ever on the side of the prudent. Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/8298/display/redirect Comment Actions Successful build - Chance fights ever on the side of the prudent. Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/8301/display/redirect Comment Actions Build failure - The Moirai have given mortals hearts that can endure. Link to build: https://jenkins.wildfiregames.com/job/macos-differential/7212/display/redirect
Comment Actions Successful build - Chance fights ever on the side of the prudent. Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/8303/display/redirect Comment Actions Build failure - The Moirai have given mortals hearts that can endure. Link to build: https://jenkins.wildfiregames.com/job/macos-differential/7214/display/redirect
Comment Actions Unswitch the visual and the non-visual loop. This removes the need for std::optional but now there are four similar loops. I deduplicated the loop in to WhileNoShutdown. Comment Actions Build failure - The Moirai have given mortals hearts that can endure. Debug: 4>e:\jenkins\workspace\vs2015-differential\source\main.cpp(680): error C2248: 'RL::Interface::Interface': cannot access private member declared in class 'RL::Interface' [E:\Jenkins\workspace\vs2015-differential\build\workspaces\vs2017\pyrogenesis.vcxproj] 4>e:\jenkins\workspace\vs2015-differential\source\main.cpp(692): error C2248: 'RL::Interface::Interface': cannot access private member declared in class 'RL::Interface' [E:\Jenkins\workspace\vs2015-differential\build\workspaces\vs2017\pyrogenesis.vcxproj] Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/8306/display/redirect Comment Actions Build failure - The Moirai have given mortals hearts that can endure. Link to build: https://jenkins.wildfiregames.com/job/macos-differential/7217/display/redirect Comment Actions I don't think that: WhileNoShutdown( []{ Frame(); }); is more readable/safe than: while (g_Shutdown == ShutdownType::None) Frame(); But I have no strong objections.
Comment Actions Yes it's a bit less readable, but it's better then repeating while (g_Shutdown == ShutdownType::None) four times.
Comment Actions Build failure - The Moirai have given mortals hearts that can endure. Debug: 4>e:\jenkins\workspace\vs2015-differential\source\main.cpp(680): error C2248: 'RL::Interface::Interface': cannot access private member declared in class 'RL::Interface' [E:\Jenkins\workspace\vs2015-differential\build\workspaces\vs2017\pyrogenesis.vcxproj] 4>e:\jenkins\workspace\vs2015-differential\source\main.cpp(692): error C2248: 'RL::Interface::Interface': cannot access private member declared in class 'RL::Interface' [E:\Jenkins\workspace\vs2015-differential\build\workspaces\vs2017\pyrogenesis.vcxproj] Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/8307/display/redirect Comment Actions Build failure - The Moirai have given mortals hearts that can endure. Link to build: https://jenkins.wildfiregames.com/job/macos-differential/7218/display/redirect Comment Actions I changed my mind about "unswitching". Now i think it's better if the code path are unified (only one loop and switching/branching inside the loop). Bacicly this version Comment Actions Build failure - The Moirai have given mortals hearts that can endure. Link to build: https://jenkins.wildfiregames.com/job/docker-differential/8895/display/redirect Comment Actions Build failure - The Moirai have given mortals hearts that can endure. Link to build: https://jenkins.wildfiregames.com/job/macos-differential/7224/display/redirect |