git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Merge pull request #1707 from purescript/1700
4b144d6Phil Freeman
src/Language/PureScript/Docs/Convert.hs+1−1
@@ -96,7 +96,7 @@ augmentDeclarations (partitionEithers -> (augments, toplevels)) =
96-- fixity declarations.
96-- fixity declarations.
97--
97--
98-- TODO: This may no longer be necessary after issue 806 is resolved, hopefully
98-- TODO: This may no longer be necessary after issue 806 is resolved, hopefully
99−-- in 0.8.
99+-- in 0.9.
100addDefaultFixity :: Declaration -> Declaration
100addDefaultFixity :: Declaration -> Declaration
101addDefaultFixity decl@Declaration{..}
101addDefaultFixity decl@Declaration{..}
102 | isOp declTitle && isNothing declFixity =
102 | isOp declTitle && isNothing declFixity =
src/Language/PureScript/Parser/Common.hs−5
@@ -27,11 +27,6 @@ import Language.PureScript.Names
27
27
28import qualified Text.Parsec as P
28import qualified Text.Parsec as P
29
29
30−featureWasRemoved :: String -> TokenParser a
31−featureWasRemoved err = do
32− pos <- P.getPosition
33− error $ "It looks like you are trying to use a feature from a previous version of the compiler:\n" ++ err ++ "\nat " ++ show pos
34−
35properName :: TokenParser ProperName
30properName :: TokenParser ProperName
36properName = ProperName <$> uname
31properName = ProperName <$> uname
37
32
src/Language/PureScript/Parser/Declarations.hs+1−6
@@ -106,9 +106,6 @@ parseExternDeclaration = P.try (reserved "foreign") *> indented *> reserved "imp
106 (ExternDataDeclaration <$> (P.try (reserved "data") *> indented *> properName)
106 (ExternDataDeclaration <$> (P.try (reserved "data") *> indented *> properName)
107 <*> (indented *> doubleColon *> parseKind)
107 <*> (indented *> doubleColon *> parseKind)
108 <|> (do ident <- parseIdent
108 <|> (do ident <- parseIdent
109− -- TODO: add a wiki page link with migration info
110− -- TODO: remove this deprecation warning in 0.8
111− _ <- P.optional $ stringLiteral *> featureWasRemoved "Inline foreign string literals are no longer supported."
112 ty <- indented *> doubleColon *> noWildcards parsePolyType
109 ty <- indented *> doubleColon *> noWildcards parsePolyType
113 return $ ExternDeclaration ident ty))
110 return $ ExternDeclaration ident ty))
114
111
@@ -525,10 +522,8 @@ parseIdentifierAndBinder =
525-- Parse a binder
522-- Parse a binder
526--
523--
527parseBinder :: TokenParser Binder
524parseBinder :: TokenParser Binder
528−parseBinder = withSourceSpan PositionedBinder (P.buildExpressionParser operators (buildPostfixParser postfixTable parseBinderAtom))
525+parseBinder = withSourceSpan PositionedBinder (buildPostfixParser postfixTable parseBinderAtom)
529 where
526 where
530− -- TODO: remove this deprecation warning in 0.8
531− operators = [ [ P.Infix (P.try $ C.indented *> colon *> featureWasRemoved "Cons binders are no longer supported. Consider using purescript-lists or purescript-sequences instead.") P.AssocRight ] ]
532 -- TODO: parsePolyType when adding support for polymorphic types
527 -- TODO: parsePolyType when adding support for polymorphic types
533 postfixTable = [ \b -> flip TypedBinder b <$> (P.try (indented *> doubleColon) *> parseType)
528 postfixTable = [ \b -> flip TypedBinder b <$> (P.try (indented *> doubleColon) *> parseType)
534 ]
529 ]
src/Language/PureScript/Parser/Types.hs−13
@@ -17,17 +17,6 @@ import Language.PureScript.Environment
17import qualified Text.Parsec as P
17import qualified Text.Parsec as P
18import qualified Text.Parsec.Expr as P
18import qualified Text.Parsec.Expr as P
19
19
20−-- TODO: remove these deprecation warnings in 0.8
21−parseArray :: TokenParser Type
22−parseArray = do
23− _ <- squares $ return tyArray
24− featureWasRemoved "Array notation is no longer supported. Use Array instead of []."
25−
26−parseArrayOf :: TokenParser Type
27−parseArrayOf = do
28− _ <- squares $ TypeApp tyArray <$> parseType
29− featureWasRemoved "Array notation is no longer supported. Use Array _ instead of [_]."
30−
31parseFunction :: TokenParser Type
20parseFunction :: TokenParser Type
32parseFunction = parens $ rarrow >> return tyFunction
21parseFunction = parens $ rarrow >> return tyFunction
33
22
@@ -56,8 +45,6 @@ parseForAll = mkForAll <$> (P.try (reserved "forall") *> P.many1 (indented *> id
56parseTypeAtom :: TokenParser Type
45parseTypeAtom :: TokenParser Type
57parseTypeAtom = indented *> P.choice (map P.try
46parseTypeAtom = indented *> P.choice (map P.try
58 [ parseConstrainedType
47 [ parseConstrainedType
59− , parseArray
60− , parseArrayOf
61 , parseFunction
48 , parseFunction
62 , parseObject
49 , parseObject
63 , parseTypeWildcard
50 , parseTypeWildcard