plunder

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

TRICKS.md (931B)


      1 Dev Tricks
      2 ==========
      3 
      4 Updating Jet Hashes
      5 -------------------
      6 
      7 Updating the jet hashes is annoying, so there's a hacky "trick" for
      8 updating them more easily.
      9 
     10 The runtime system outputs Haskell code when it does jet matching.
     11 This output can be caputured from stderr.
     12 
     13     rm sire.cache
     14     sh/sire-load-all 2>stderr <<<""
     15     grep ' , e' <stderr >new-jets-table
     16 
     17 Then `new-jets-table` can be copied into the big list-literal in
     18 `Fan.JetHash`, and you can review the changes with:
     19 
     20     git diff lib/Fan/JetHash.hs
     21 
     22 Make sure that nothing is missing!  If a the name changed, or the jet
     23 name in the code doesn't match the one in the table, it wont appear in
     24 the output at all.
     25 
     26 ### Detecting Jet Mismatches
     27 
     28 Using the same stderr trick, you can check for jet mistmatches by search
     29 for the string "NOT MATCHED".
     30 
     31     grep "NOT MATCHED" stderr
     32 
     33 You can also just search back in your terminal history to see if this
     34 shows up anywhere.