hlAppend widths exprs
        | null exprStrs = showString "dot"
        | otherwise = foldl1' (hlInfixOp "+") exprStrs
        where
            offsets = scanl (+) 0 widths
            exprStrs = mapMaybe maybeInsert $ zip3 exprs offsets widths

            maybeInsert (_, _, 0) = Nothing
            maybeInsert (expr, offset, _) = Just $ hlShl expr offset
hlAppend widths exprs
        | null exprStrs = showString "dot"
        | otherwise = foldl1' (hlInfixOp "+") exprStrs
        where
            offsets = scanl (+) 0 widths
            exprStrs = mapMaybe maybeInsert $ zip3 exprs offsets widths

            maybeInsert (_, _, 0) = Nothing
            maybeInsert (expr, offset, _) = Just $ hlShl expr offset
hlAppend widths exprs
        | null exprStrs = showString "dot"
        | otherwise = foldl1' (hlInfixOp "+") exprStrs
        where
            offsets = scanl (+) 0 widths
            exprStrs = mapMaybe maybeInsert $ zip3 exprs offsets widths

            maybeInsert (_, _, 0) = Nothing
            maybeInsert (expr, offset, _) = Just $ hlShl expr offset