Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] data-dependencies break on reexport of TypeOperators #11447

Closed
cocreature opened this issue Oct 28, 2021 · 0 comments · Fixed by #11451
Closed

[BUG] data-dependencies break on reexport of TypeOperators #11447

cocreature opened this issue Oct 28, 2021 · 0 comments · Fixed by #11451
Assignees
Labels
language/now Language team priority NOW

Comments

@cocreature
Copy link
Contributor

Consider this example:
package dep has those two modules:

module Dep where

type (&) a b = (a, b)

``
module DepReexport
(module Dep)
where

import Dep

package `main` depends on `dep` via a `data-dependency`

This fails with

.daml/package-database/1.14/dep-0.0.1-71ebdf0c0009585fa8f6d6de8c841366c209fd2c66e2e4c5932c1d826658ad34/DepReexport.daml:10:29:
error:
Expecting a type constructor but found a variable, ‘Dep.&’.
If ‘Dep.&’ is a type constructor then enable ExplicitNamespaces and use the 'type' keyword.


We should do exactly what the error suggests and enamle ExplicitNameSpaces and use `type`.

Probably worth testing for both synonyms and type constructors.
@cocreature cocreature added the language/now Language team priority NOW label Oct 28, 2021
@cocreature cocreature added this to the Daml Language Team Backlog milestone Oct 28, 2021
moisesackerman-da pushed a commit that referenced this issue Oct 28, 2021
This ensures that type operators are reexported correctly.

Closes #11447

changelog_begin
changelog_end
akrmn pushed a commit that referenced this issue Oct 28, 2021
This ensures that type operators are reexported correctly.

Closes #11447

changelog_begin
changelog_end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
language/now Language team priority NOW
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants