{-# LANGUAGE CPP #-}
#include "ghclib_api.h"
module Language.Haskell.GhclibParserEx.GHC.Hs.Types(
fromTyParen
, isTyQuasiQuote, isUnboxedTuple
) where
#if defined (GHCLIB_API_HEAD) || defined (GHCLIB_API_902) || defined (GHCLIB_API_900) || defined (GHCLIB_API_810)
import GHC.Hs
#else
import HsSyn
#endif
#if defined (GHCLIB_API_HEAD) || defined (GHCLIB_API_902) || defined (GHCLIB_API_900)
import GHC.Types.SrcLoc
#else
import SrcLoc
#endif
fromTyParen :: LHsType GhcPs -> LHsType GhcPs
fromTyParen :: LHsType GhcPs -> LHsType GhcPs
fromTyParen (L SrcSpan
_ (HsParTy XParTy GhcPs
_ LHsType GhcPs
x)) = LHsType GhcPs
x
fromTyParen LHsType GhcPs
x = LHsType GhcPs
x
isTyQuasiQuote :: LHsType GhcPs -> Bool
isTyQuasiQuote :: LHsType GhcPs -> Bool
isTyQuasiQuote (L SrcSpan
_ (HsSpliceTy XSpliceTy GhcPs
_ HsQuasiQuote{})) = Bool
True
isTyQuasiQuote LHsType GhcPs
_ = Bool
False
isUnboxedTuple :: HsTupleSort -> Bool
isUnboxedTuple :: HsTupleSort -> Bool
isUnboxedTuple HsTupleSort
HsUnboxedTuple = Bool
True
isUnboxedTuple HsTupleSort
_ = Bool
False