#10537: Parser: commas_tup_tail duplicate SrcSpan on "Missing" value
-------------------------------------+-------------------------------------
Reporter: alanz | Owner: alanz
Type: bug | Status: patch
Priority: normal | Milestone: 7.10.2
Component: Compiler | Version: 7.10.1
(Parser) | Keywords:
Resolution: | Architecture:
Operating System: Unknown/Multiple | Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Revisions: Phab:D995
-------------------------------------+-------------------------------------
Comment (by Alan Zimmerman ):
In [changeset:"72b21c393831b49867a296f19a2d039e48bb8dcd/ghc"]:
{{{
#!CommitTicketReference repository="ghc"
revision="72b21c393831b49867a296f19a2d039e48bb8dcd"
Parser: commas_tup_tail duplicate SrcSpan on "Missing" value
Summary:
Parsing
{-# LANGUAGE TupleSections #-}
baz = (1, "hello", 6.5,,) 'a' (Just ())
Results in the following AST fragment
(L tests/examples/Tuple.hs:3:7-25
(ExplicitTuple
[ L tests/examples/Tuple.hs:3:8
(Present
(L tests/examples/Tuple.hs:3:8
(HsOverLit
(OverLit
(HsIntegral [ '1' ] 1)
PlaceHolder
(HsLit
(HsString
[]
{abstract:FastString}))
PlaceHolder))))
, L tests/examples/Tuple.hs:3:11-17
(Present
(L tests/examples/Tuple.hs:3:11-17
(HsLit
(HsString
[ '"'
, 'h'
, 'e'
, 'l'
, 'l'
, 'o'
, '"'
]
{abstract:FastString}))))
, L tests/examples/Tuple.hs:3:20-22
(Present
(L tests/examples/Tuple.hs:3:20-22
(HsOverLit
(OverLit
(HsFractional
(FL
[ '6' , '.' , '5' ]
(:% 13 2)))
PlaceHolder
(HsLit
(HsString
[]
{abstract:FastString}))
PlaceHolder))))
, L tests/examples/Tuple.hs:3:24
(Missing PlaceHolder)
, L tests/examples/Tuple.hs:3:24
(Missing PlaceHolder)
]
The final `Missing PlaceHolder` has a duplicated `SrcSpan`
Test Plan: ./validate
Reviewers: austin, hvr, bgamari
Reviewed By: bgamari
Subscribers: thomie, bgamari, mpickering
Differential Revision: https://phabricator.haskell.org/D995
GHC Trac Issues: #10537
}}}
--
Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/10537#comment:6
GHC http://www.haskell.org/ghc/
The Glasgow Haskell Compiler