Skip to content

GitLab

  • Menu
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 4,970
    • Issues 4,970
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
  • Merge requests 460
    • Merge requests 460
  • 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 Compiler
  • GHCGHC
  • Issues
  • #8180
Closed
Open
Created Aug 27, 2013 by Richard Eisenberg@raeDeveloper

Template Haskell now requires -dynamic or -dynamic-too

I have the following files:

{-# LANGUAGE TemplateHaskell #-}

module THSplice where

number3 = [| 3 |]
{-# LANGUAGE TemplateHaskell #-}

module Main where

import THSplice

main = putStrLn (show $number3)

When I say ghc Main.hs, I get this:

[1 of 2] Compiling THSplice         ( THSplice.hs, THSplice.o )
[2 of 2] Compiling Main             ( Main.hs, Main.o )
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Main.hs:7:23:
    cannot find normal object file ‛./THSplice.dyn_o’
    while linking an interpreted expression

It's possible a different collection of flags could get this to work, but I think this behavior goes against the intended "it just works" flavor of --make.

This is a regression bug -- ghc 7.6.3 does the right thing.

I'm on MacOS 10.7.5, Xcode 4.3.3.

Trac metadata
Trac field Value
Version 7.7
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system MacOS X
Architecture x86_64 (amd64)
Edited Mar 09, 2019 by Simon Marlow
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking