Open tcr opened 7 years ago
e.g. in this code, the colons will wrongly be treated as function arguments.
baseTypeOf :: [CDeclSpec] -> EnvMonad s (Maybe CStorageSpec, EnvMonad s IntermediateType) baseTypeOf specs = do -- TODO: process attributes and the `inline` keyword let (storage, _attributes, basequals, basespecs, _inlineNoReturn, _align) = partitionDeclSpecs specs mstorage <- case storage of [] -> return Nothing [spec] -> return (Just spec) _ : excess : _ -> badSource excess "extra storage class specifier" base <- typedef (mutable basequals) basespecs return (mstorage, base) where
Another case where case parsing falls down here:
IsFunc{} -> return expr' _ -> badSource node "dereference of non-pointer"
e.g. in this code, the colons will wrongly be treated as function arguments.