@@ -67,7 +67,17 @@ pPkg = do
6767-- |
6868-- | Treated for now as an identifier or a double-quoted string.
6969filename :: (MonadicParsing m, HasLastTokenSpan m) => m String
70−filename = (token $ stringLiteral <|> (fst <$> identifier)) <?> "filename"
70+filename = token $
71+ -- Treat a double-quoted string as a filename to support spaces.
72+ -- This also moves away from tying filenames to identifiers, so
73+ -- it will also accept hyphens
74+ -- (https://github.com/idris-lang/Idris-dev/issues/2721)
75+ stringLiteral
76+ <|>
77+ -- Through at least version 0.9.19.1, IPKG executable values were
78+ -- possibly namespaced identifiers, like foo.bar.baz.
79+ show <$> fst <$> iName []
80+ <?> "filename"
7181
7282
7383pClause :: PParser ()