bitcoin-sv / sol2scrypt

Solidity to sCrypt Transplier
BSD 3-Clause "New" or "Revised" License
1 stars 0 forks source link

remove all compile warnings #146

Closed xhliu closed 2 years ago

xhliu commented 2 years ago
/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformations/Sol2IR/Function.hs:22:1: warning: [-Wunused-imports]
    The import of ‘Utils’ is redundant
      except perhaps to import instances from ‘Utils’
    To import instances alone, use: import Utils()
   |                    
22 | import Utils       
   | ^^^^^^^^^^^^       

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformations/Sol2IR/Function.hs:100:35: warning: [-Wunused-matches]
    Defined but not used: ‘tags’
    |                   
100 | toIRFuncParams (ParameterList pl) tags (FuncRetTransResult rt ort rn) vis funcBlk = do
    |                                   ^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformations/Sol2IR/Function.hs:100:60: warning: [-Wunused-matches]
    Defined but not used: ‘rt’
    |                   
100 | toIRFuncParams (ParameterList pl) tags (FuncRetTransResult rt ort rn) vis funcBlk = do
    |                                                            ^^
[52 of 56] Compiling IR.Transformations.Sol2IR.Contract
[53 of 56] Compiling IR.Transformations.Sol2IR.Program
[54 of 56] Compiling IR.Transformer

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:8:5: warning: [-Wdodgy-exports]
    The export item ‘module IR.Transformations.IR2Scr.Type’ exports nothing
  |                     
8 |     module IR.Transformations.IR2Scr.Type,
  |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:12:5: warning: [-Wdodgy-exports]
    The export item ‘module IR.Transformations.IR2Scr.Statement’ exports nothing
   |                    
12 |     module IR.Transformations.IR2Scr.Statement,
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:14:5: warning: [-Wdodgy-exports]
    The export item ‘module IR.Transformations.IR2Scr.Identifier’ exports nothing
   |                    
14 |     module IR.Transformations.IR2Scr.Identifier,
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:16:5: warning: [-Wdodgy-exports]
    The export item ‘module IR.Transformations.IR2Scr.Variable’ exports nothing
   |                    
16 |     module IR.Transformations.IR2Scr.Variable,
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:21:5: warning: [-Wdodgy-exports]
    The export item ‘module IR.Transformations.Sol2IR.Program’ exports nothing
   |                    
21 |     module IR.Transformations.Sol2IR.Program,
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:22:5: warning: [-Wdodgy-exports]
    The export item ‘module IR.Transformations.IR2Scr.Program’ exports nothing
   |                    
22 |     module IR.Transformations.IR2Scr.Program,
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:28:1: warning: [-Wunused-imports]
    The import of ‘IR.Transformations.IR2Scr.Empty’ is redundant
      except perhaps to import instances from ‘IR.Transformations.IR2Scr.Empty’
    To import instances alone, use: import IR.Transformations.IR2Scr.Empty()
   |                    
28 | import IR.Transformations.IR2Scr.Empty
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:30:1: warning: [-Wunused-imports]
    The import of ‘IR.Transformations.IR2Scr.Struct’ is redundant
      except perhaps to import instances from ‘IR.Transformations.IR2Scr.Struct’
    To import instances alone, use: import IR.Transformations.IR2Scr.Struct()
   |                    
30 | import IR.Transformations.IR2Scr.Struct
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:32:1: warning: [-Wunused-imports]
    The import of ‘IR.Transformations.IR2Scr.Identifier’ is redundant
      except perhaps to import instances from ‘IR.Transformations.IR2Scr.Identifier’
    To import instances alone, use: import IR.Transformations.IR2Scr.Identifier()
   |                    
32 | import IR.Transformations.IR2Scr.Identifier
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:33:1: warning: [-Wunused-imports]
    The import of ‘IR.Transformations.IR2Scr.Statement’ is redundant
      except perhaps to import instances from ‘IR.Transformations.IR2Scr.Statement’
    To import instances alone, use: import IR.Transformations.IR2Scr.Statement()
   |                    
33 | import IR.Transformations.IR2Scr.Statement
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:34:1: warning: [-Wunused-imports]
    The import of ‘IR.Transformations.IR2Scr.Type’ is redundant
      except perhaps to import instances from ‘IR.Transformations.IR2Scr.Type’
    To import instances alone, use: import IR.Transformations.IR2Scr.Type()
   |                    
34 | import IR.Transformations.IR2Scr.Type
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:35:1: warning: [-Wunused-imports]
    The import of ‘IR.Transformations.IR2Scr.Variable’ is redundant
      except perhaps to import instances from ‘IR.Transformations.IR2Scr.Variable’
    To import instances alone, use: import IR.Transformations.IR2Scr.Variable()
   |                    
35 | import IR.Transformations.IR2Scr.Variable
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:44:1: warning: [-Wunused-imports]
    The import of ‘IR.Transformations.Sol2IR.Program’ is redundant
      except perhaps to import instances from ‘IR.Transformations.Sol2IR.Program’
    To import instances alone, use: import IR.Transformations.Sol2IR.Program()
   |                    
44 | import IR.Transformations.Sol2IR.Program
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:45:1: warning: [-Wunused-imports]
    The import of ‘IR.Transformations.IR2Scr.Program’ is redundant
      except perhaps to import instances from ‘IR.Transformations.IR2Scr.Program’
    To import instances alone, use: import IR.Transformations.IR2Scr.Program()
   |                    
45 | import IR.Transformations.IR2Scr.Program
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:49:3: warning: [-Wunused-top-binds]
    Defined but not used: ‘nodeType’
   |                    
49 |   nodeType :: Show a => a -> String
   |   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/Users/xhliu/projects/scrypt/public/sol2scrypt/src/IR/Transformer.hs:52:3: warning: [-Wunused-top-binds]
    Defined but not used: ‘current’
   |                    
52 |   current :: a -> a
   |   ^^^^^^^^^^^^^^^^^
[55 of 56] Compiling IR 
[56 of 56] Compiling Transpiler
zhfnjust commented 2 years ago

Fixed. https://github.com/sCrypt-Inc/sol2scrypt/pull/178