Skip to content

Commit

Permalink
test: show wrong "unused attribute" warning for @@@mel.config in .mli
Browse files Browse the repository at this point in the history
  • Loading branch information
anmonteiro committed Oct 20, 2023
1 parent 1167ca7 commit 316f64f
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions test/blackbox-tests/unused-attributes.t
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,16 @@

// Generated by Melange
/* This output is empty. Its source's type definitions, externals and/or unused code got optimized away. */


$ cat > x.mli <<EOF
> [@@@mel.config { flags = [|"-unboxed-types"|] }]
> EOF
$ melc -ppx melppx x.mli
File "x.mli", line 1, characters 6-16:
1 | [@@@mel.config { flags = [|"-unboxed-types"|] }]
^^^^^^^^^^
Alert unused: Unused attribute [@mel.config]
This means such annotation is not annotated properly.
For example, some annotations are only meaningful in externals

0 comments on commit 316f64f

Please sign in to comment.