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

@inlined doesn't seem to work with module aliases #7538

Closed
vicuna opened this issue May 23, 2017 · 4 comments
Closed

@inlined doesn't seem to work with module aliases #7538

vicuna opened this issue May 23, 2017 · 4 comments
Assignees

Comments

@vicuna
Copy link

vicuna commented May 23, 2017

Original bug ID: 7538
Reporter: talex
Assigned to: @mshinwell
Status: assigned (set by @mshinwell on 2017-05-23T13:46:02Z)
Resolution: open
Priority: normal
Severity: minor
Version: 4.04.1
Category: middle end (typedtree to clambda)

Bug description

When building a project with @inlined annotations using jbuilder, OCaml complains that 'the "inlined" attribute cannot appear in this context'. Turning off "wrapped" mode made the warning go away. It looks like @inlined doesn't work with module aliases.

Steps to reproduce

(simplified by lpw25)

module M = Map.Make@inlined;;

works, but:

module N = Map
module M = N.Make@inlined;;

gives:

Warning 53: the "inlined" attribute cannot appear in this context

@vicuna
Copy link
Author

vicuna commented May 23, 2017

Comment author: @mshinwell

Before anyone else spends time on this: Leo and I are aware of various other problems relating to inlining annotations on functors (including their failure to work when functors have multiple arguments and/or coercions). We will produce fixes as soon as we can.

@github-actions
Copy link

github-actions bot commented May 8, 2020

This issue has been open one year with no activity. Consequently, it is being marked with the "stale" label. What this means is that the issue will be automatically closed in 30 days unless more comments are added or the "stale" label is removed. Comments that provide new information on the issue are especially welcome: is it still reproducible? did it appear in other contexts? how critical is it? etc.

@github-actions github-actions bot added the Stale label May 8, 2020
@lpw25
Copy link
Contributor

lpw25 commented May 8, 2020

The weird difference in behaviour with aliases for the warning has been fixed. Although I should point out that placing the annotation there in both cases will do nothing useful. Probably we should be warning in both cases.

@github-actions github-actions bot closed this as completed Jun 8, 2020
@lpw25
Copy link
Contributor

lpw25 commented Jun 12, 2020

Fix for this in #9669. It will now give the warning on all the cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants