[GHC] #9616: Incorrect numbers from HpcMarkup.markup_plugin
#9616: Incorrect numbers from HpcMarkup.markup_plugin -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Code Coverage | Version: 7.9 Keywords: | Operating System: Architecture: Unknown/Multiple | Unknown/Multiple Difficulty: Easy (less than 1 | Type of failure: Incorrect hour) | result at runtime Blocked By: | Test Case: Related Tickets: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- `showBigNum` in the `openTick` function accidentally puts 0s in the wrong place when formatting large numbers. 12345 will be formatted as 120,345 instead of 012,345. The correct answer is probably to add some locale- specific numeric formatting stuff somewhere, but until then, I'll just fix this. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9616> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9616: Incorrect numbers from HpcMarkup.markup_plugin -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Code | Version: 7.9 Coverage | Keywords: Resolution: | Architecture: Unknown/Multiple Operating System: | Difficulty: Easy (less than 1 Unknown/Multiple | hour) Type of failure: Incorrect | Blocked By: result at runtime | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Changes (by dfeuer): * status: new => patch Comment: The patch I just attached should fix the 0 placement. It also uses `dropWhileEnd` now instead of `reverse . dropWhile ... . reverse`, and adds left padding in a somewhat saner manner in general. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9616#comment:1> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9616: Incorrect numbers from HpcMarkup.markup_plugin -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Code | Version: 7.9 Coverage | Keywords: Resolution: | Architecture: Unknown/Multiple Operating System: | Difficulty: Easy (less than 1 Unknown/Multiple | hour) Type of failure: Incorrect | Blocked By: result at runtime | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Comment (by dfeuer): D259 uploaded to Phabricator and awaiting review. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9616#comment:2> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9616: Incorrect numbers from HpcMarkup.markup_plugin -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Code | Version: 7.9 Coverage | Keywords: Resolution: | Architecture: Unknown/Multiple Operating System: | Difficulty: Easy (less than 1 Unknown/Multiple | hour) Type of failure: Incorrect | Blocked By: result at runtime | Related Tickets: Test Case: | Blocking: | Differential Revisions: Phab:D259 | -------------------------------------+------------------------------------- Changes (by nomeata): * differential: => Phab:D259 Comment: You can use the Phab:D259 syntax to automatically link it. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9616#comment:3> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9616: Incorrect numbers from HpcMarkup.markup_plugin -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Code | Version: 7.9 Coverage | Keywords: Resolution: | Architecture: Unknown/Multiple Operating System: | Difficulty: Easy (less than 1 Unknown/Multiple | hour) Type of failure: Incorrect | Blocked By: result at runtime | Related Tickets: Test Case: | Blocking: | Differential Revisions: Phab:D259 | -------------------------------------+------------------------------------- Comment (by Joachim Breitner <mail@…>): In [changeset:"2a8856884de7d476e26b4ffa829ccb3a14d6f63e/ghc"]: {{{ #!CommitTicketReference repository="ghc" revision="2a8856884de7d476e26b4ffa829ccb3a14d6f63e" Use dropWhileEndLE p instead of reverse . dropWhile p . reverse Summary: Using `dropWhileEndLE` tends to be faster and easier to read than the `reverse . dropWhile p . reverse` idiom. This also cleans up some other, nearby, messes. Fix #9616 (incorrect number formatting potentially leading to incorrect numbers in output). Test Plan: Run validate Reviewers: thomie, rwbarton, nomeata, austin Reviewed By: nomeata, austin Subscribers: simonmar, ezyang, carter, thomie Projects: #ghc Differential Revision: https://phabricator.haskell.org/D259 GHC Trac Issues: #9623, #9616 Conflicts: compiler/basicTypes/OccName.lhs }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9616#comment:4> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9616: Incorrect numbers from HpcMarkup.markup_plugin -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Code | Version: 7.9 Coverage | Keywords: Resolution: fixed | Architecture: Unknown/Multiple Operating System: | Difficulty: Easy (less than 1 Unknown/Multiple | hour) Type of failure: Incorrect | Blocked By: result at runtime | Related Tickets: Test Case: | Blocking: | Differential Revisions: Phab:D259 | -------------------------------------+------------------------------------- Changes (by nomeata): * status: patch => closed * resolution: => fixed -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9616#comment:5> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9616: Incorrect numbers from HpcMarkup.markup_plugin -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Code | Version: 7.9 Coverage | Keywords: Resolution: fixed | Architecture: Unknown/Multiple Operating System: | Difficulty: Easy (less than 1 Unknown/Multiple | hour) Type of failure: Incorrect | Blocked By: result at runtime | Related Tickets: Test Case: | Blocking: | Differential Revisions: Phab:D259 | -------------------------------------+------------------------------------- Comment (by Joachim Breitner <mail@…>): In [changeset:"9bf5228fdc1937f44901a945553eea3cb0f14faa/ghc"]: {{{ #!CommitTicketReference repository="ghc" revision="9bf5228fdc1937f44901a945553eea3cb0f14faa" Use dropWhileEndLE p instead of reverse . dropWhile p . reverse Summary: Using `dropWhileEndLE` tends to be faster and easier to read than the `reverse . dropWhile p . reverse` idiom. This also cleans up some other, nearby, messes. Fix #9616 (incorrect number formatting potentially leading to incorrect numbers in output). Test Plan: Run validate Reviewers: thomie, rwbarton, nomeata, austin Reviewed By: nomeata, austin Subscribers: simonmar, ezyang, carter, thomie Projects: #ghc Differential Revision: https://phabricator.haskell.org/D259 GHC Trac Issues: #9623, #9616 Conflicts: compiler/basicTypes/OccName.lhs }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9616#comment:6> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
participants (1)
-
GHC