Skip to content
  • Krzysztof Gogolewski's avatar
    1dbdb9d0
    Refactor: introduce stgArgRep · 1dbdb9d0
    Krzysztof Gogolewski authored and Marge Bot's avatar Marge Bot committed
    The function 'stgArgType' returns the type in STG. But this violates
    the abstraction: in STG we're supposed to operate on PrimReps.
    
    This introduces
    stgArgRep ty = typePrimRep (stgArgType ty)
    stgArgRep1 ty = typePrimRep1 (stgArgType ty)
    stgArgRep_maybe ty = typePrimRep_maybe (stgArgType ty)
    
    stgArgType is still directly used for unboxed tuples (should be fixable), FFI
    and in ticky.
    1dbdb9d0
    Refactor: introduce stgArgRep
    Krzysztof Gogolewski authored and Marge Bot's avatar Marge Bot committed
    The function 'stgArgType' returns the type in STG. But this violates
    the abstraction: in STG we're supposed to operate on PrimReps.
    
    This introduces
    stgArgRep ty = typePrimRep (stgArgType ty)
    stgArgRep1 ty = typePrimRep1 (stgArgType ty)
    stgArgRep_maybe ty = typePrimRep_maybe (stgArgType ty)
    
    stgArgType is still directly used for unboxed tuples (should be fixable), FFI
    and in ticky.
Loading