anchor.diff:  
       if e = null then null else
       match e with
  +    | (:? ConstantExpression as e)    -> upcast e
  +    | (:? ParameterExpression as e)   -> upcast e
       | (:? UnaryExpression as e) -> 
           let visited = visit e.Operand
           if visited=e.Operand then upcast e else upcast Expression.MakeUnary(e.NodeType,visited,e.Type,e.Method) 
  
positive.code:         let (|Constant|_|) (e:Expression) = 
              match e.NodeType, e with 
              | ExpressionType.Constant, (:? ConstantExpression as ce) when (ce.Value :? IComparable) -> Some (ce.Value :?> IComparable)
              | _ -> None
          let createbool b = Expression.Constant(b,  typeof<bool>) :> Expression
          match ce.Left, ce.Right with
  
negative.code:         else
              let v1, v2 = visit e.Left, visit e.Right
              if v1=e.Left && v2=e.Right then upcast e else upcast Expression.MakeBinary(e.NodeType,v1,v2,e.IsLiftedToNull, e.Method)
      | (:? MemberExpression as e)      -> 
          let v = visit e.Expression
          if v=e.Expression then upcast e else upcast Expression.MakeMemberAccess(v, e.Member)
  