Skip to content

Covariance propagation across functors #7212

@vicuna

Description

@vicuna

Original bug ID: 7212
Reporter: @Drup
Assigned to: @garrigue
Status: acknowledged (set by @damiendoligez on 2016-04-05T14:20:18Z)
Resolution: open
Priority: normal
Severity: feature
Target version: later
Category: typing
Related to: #5984
Monitored by: @Drup

Bug description

In the attached file, one can see that covariance doesn't seem propagated across type aliases with functors. The behavior leads to rather surprising behaviors.

This appeared in a "real" situation in tyxml where we have a wrapping interface that is sometimes instantiated with covariant types:

With stable tyxml:
# #require "tyxml" ;;
# Html5.M.Xml.W.nil () ;;
- : '_a list = []

Maybe related (thanks yallop): #5984

File attachments

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions