Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
  • GHC GHC
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 5,248
    • Issues 5,248
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
  • Merge requests 564
    • Merge requests 564
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Glasgow Haskell CompilerGlasgow Haskell Compiler
  • GHCGHC
  • Issues
  • #3376
Closed
Open
Issue created Jul 16, 2009 by Ian Lynagh <igloo@earth.li>@trac-igloo

hpc and CPP don't mix on Windows

Originaly reported by Dominic Steinitz here: http://www.haskell.org/pipermail/glasgow-haskell-users/2009-July/017511.html

On Windows, with these files:

CommonHPC.hs:

module Main (main) where

import Common

main = do
  test
  test

test = do
  putStrLn $ show $ fact 4
  putStrLn $ show $ fact 5

Common.hs:

module Common (fact) where

fact 0 = 1
fact n = n * fact (n-1)

This works:

$ ghc -fhpc --make CommonHPC
$ ./CommonHPC
$ cat CommonHPC.exe.tix
Tix [ TixModule "Main" 693125724 18 [1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1], TixModule "Common" 4136915291 8 [2,9,9,9,9,9,9,11]]

but with -cpp we get no ticks for Common:

$ ghc -fhpc --make CommonHPC -cpp
$ ./CommonHPC
$ cat CommonHPC.exe.tix
Tix [ TixModule "Main" 693125724 18 [1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1], TixModule "Common" 3370079577 0 []]
Trac metadata
Trac field Value
Version 6.10.4
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Code Coverage
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking