import Data.Typeable(typeOf)
myFunc :: (Show a) => [a] -> [String]
myFunc
| show (typeOf a) == "[Char]" = ...
| otherwise = ..
I use the above code to test if the input is of the String type.
Is this correct and acceptable or are there other better ways?