「view this page in B3 βῆτα server」

Revisions №60956

branch: master 「№60956」
Commited by: Jack Maguire
GitHub commit link: 「e60f20795c0db6d5」 「№4237」
Difference from previous tested commit:  code diff
Commit date: 2019-10-01 08:47:08
linux.clang linux.gcc linux.srlz mac.clang
linux.clang.cxx11thread.serialization.python37.PyRosetta4.unit linux.gcc.python36.PyRosetta4.unit mac.PyRosetta.unit build.clean.debug cppcheck mysql postgres linux.clang.python36.build.debug linux.zeromq.debug mpi mpi.serialization linux.icc.build.debug OpenCL mac.clang.python36.build.debug build.header build.levels ninja graphics static linux.ui mac.ui build.xcode beautification code_quality.clang_analysis serialization integration.addsan integration.mpi integration.release_debug integration.tensorflow integration.thread integration.tutorials integration performance profile linux.clang.python36.release.PyRosetta4.MinSizeRel linux.clang.python37.release.PyRosetta4.MinSizeRel ubuntu.clang.python36.release.PyRosetta4.MinSizeRel release.PyRosetta4.Release release.source scientific.FlexPepDock.debug scientific.FlexPepDock scientific.antibody_h3_modeling.debug scientific.antibody_h3_modeling scientific.cartesian_relax.debug scientific.cartesian_relax scientific.cofactor_binding_sites.debug scientific.docking.debug scientific.enzyme_design.debug scientific.enzyme_design scientific.fast_relax_5iter.debug scientific.fast_relax_5iter scientific.fast_relax scientific.ligand_docking.debug scientific.ligand_docking scientific.ligand_scoring_ranking.debug scientific.ligand_scoring_ranking scientific.loop_modeling_ccd_12res.debug scientific.loop_modeling_kic_12res.debug scientific.loop_modeling_kic_fragments_12res.debug scientific.loop_modeling_ngk_12res.debug scientific.mp_domain_assembly.debug scientific.mp_domain_assembly scientific.mp_f19_energy_landscape.debug scientific.mp_f19_energy_landscape scientific.mp_f19_sequence_recovery.debug scientific.mp_relax scientific.mp_symdock scientific.rna_denovo_favorites.debug scientific.sewing.debug scientific.sewing scientific.simple_cycpep_predict.debug scientific.stepwise_rna_favorites.debug linux.clang.score linux.gcc.score mac.clang.score linux.scripts.pyrosetta scripts.rosetta.parse scripts.rosetta.validate scripts.rosetta.verify linux.clang.unit.release linux.gcc.unit.release unit.ubsan unit.valgrind util.apps

Merge pull request #4237 from RosettaCommons/JackMaguire/StrongTypeAliases Adding Utility To Make C++'s Type System Help Us Catch Bugs We're having an issue in JD3 right now where we have a lot of Sizes and Reals floating around and we are forced to use variable/parameter names to make sure they line up correctly when calling functions. This is very bug prone because the compiler will not tell you if you pass the wrong arguments if all of them are the same type (`core::Size`, for example). This PR adds a theoretically zero-overhead way to assign different type names to different Sizes. See below for an example. I'm also adding a few use cases to the MC HBNet data structure to make sure this works and to make sure the HBNet profile test does not get worse. ```c++ //OLD: void draw_rectangle( int width, int height ); void foo( int h, int w ){ draw_rectangle( h, w ); //logic error, may not be caught at runtime draw_rectangle( w, h ); //correct } //NEW: using Width = utility::StrongSize< struct Width_ >; using Height = utility::StrongSize< struct Height_ >; void draw_rectangle( Width width, Height height ); void foo( Size h, Size w ){ draw_rectangle( h, w ); //compiler error draw_rectangle( w, h ); //compiler error draw_rectangle( Width( h ), Height( w ) ); //logic error, but the developer should be able to notice that this is wrong draw_rectangle( Width( w ), Height( h ) ); //correct } ``` Here's proof that this abstraction gets compiled away: https://godbolt.org/z/eWM_uJ

Test: ubuntu.gcc.integration.addsan

Failed sub-tests (click for more details):
Test: linux.clang.integration.release_debug_no_symbols

Failed sub-tests (click for more details):
Test: linux.clang.profile

Failed sub-tests (click for more details):
Test: linux.clang.scientific.mp_symdock

 View log


 View log in dialog  View log in log in separate window