Ignore:
Timestamp:
Jan 11, 2019, 2:16:53 PM (6 years ago)
Author:
Aaron Moss <a3moss@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, no_list, persistent-indexer, pthread-emulation, qualifiedEnum
Children:
52ffa30
Parents:
e99e43f
Message:

Fix new cost model by boosting precedence of safe costs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/ResolvExpr/ConversionCost.cc

    re99e43f rd97c3a4  
    2929namespace ResolvExpr {
    3030        const Cost Cost::zero =      Cost{  0,  0,  0,  0,  0,  0 };
    31         const Cost Cost::infinity =  Cost{ -1, -1, -1,  1, -1, -1 };
     31        const Cost Cost::infinity =  Cost{ -1, -1, -1, -1,  1, -1 };
    3232        const Cost Cost::unsafe =    Cost{  1,  0,  0,  0,  0,  0 };
    3333        const Cost Cost::poly =      Cost{  0,  1,  0,  0,  0,  0 };
    34         const Cost Cost::var =       Cost{  0,  0,  1,  0,  0,  0 };
    35         const Cost Cost::spec =      Cost{  0,  0,  0, -1,  0,  0 };
    36         const Cost Cost::safe =      Cost{  0,  0,  0,  0,  1,  0 };
     34        const Cost Cost::safe =      Cost{  0,  0,  1,  0,  0,  0 };
     35        const Cost Cost::var =       Cost{  0,  0,  0,  1,  0,  0 };
     36        const Cost Cost::spec =      Cost{  0,  0,  0,  0, -1,  0 };
    3737        const Cost Cost::reference = Cost{  0,  0,  0,  0,  0,  1 };
    3838
Note: See TracChangeset for help on using the changeset viewer.