Tritlo / PropR

Genetic program repair using GHC
MIT License
30 stars 2 forks source link

The fixes from repairAttempt are broken #73

Closed Tritlo closed 3 years ago

Tritlo commented 3 years ago

I tried to use the fixes from repairAttempt for initialFixes, and got a bunch of type errors:

...
temp_dir/172a5b9e/tests/cases/Data/checks/719c512a/FakeCheckTarget719c512a.hs:1265:16: error:
    * Couldn't match type `Int' with `Int -> Expr'
      Expected type: Int -> Int -> Expr
        Actual type: Expr -> Int
    * In the expression: evalExpr
      In the expression:
          (let
             evalExpr :: Expr -> Int
             plus :: Int -> Int -> Expr
             evalExpr (Add a b) = a + b
             evalExpr (Mul a b) = a * (succ (b))
             ....
           in evalExpr) ::
            Int -> Int -> Expr
      In an equation for `expr__plus':
          expr__plus
            = (let
                 evalExpr :: Expr -> Int
                 plus :: Int -> Int -> Expr
                 ....
               in evalExpr) ::
                Int -> Int -> Expr
     |
1265 |             in evalExpr) ::
     |                ^^^^^^^^

temp_dir/172a5b9e/tests/cases/Data/checks/719c512a/FakeCheckTarget719c512a.hs:1291:16: error:
    * Couldn't match type `Int' with `Int -> Expr'
      Expected type: Int -> Int -> Expr
        Actual type: Expr -> Int
    * In the expression: evalExpr
      In the expression:
          (let
             evalExpr :: Expr -> Int
             plus :: Int -> Int -> Expr
             evalExpr (Add a b) = a + b
             evalExpr (Mul a b) = a * (toEnum (b))
             ....
           in evalExpr) ::
            Int -> Int -> Expr
      In an equation for `expr__plus':
          expr__plus
            = (let
                 evalExpr :: Expr -> Int
                 plus :: Int -> Int -> Expr
                 ....
               in evalExpr) ::
                Int -> Int -> Expr
     |
1291 |             in evalExpr) ::
     |                ^^^^^^^^
...

I think it's got something to do with #72 or #59, I'm leaning towards #72