AutoOpen and RequireQualifiedAccess can both be specified on a module
Open
Area-Diagnostics
Feature Improvement
- Dominant language
- F#
- Stars
- 4.3k
- Forks
- 876
- Avg merge
- 4d 11h
- Merged PRs (30d)
- 131
Description
Consider the following code:
```fsharp
[]
module M =
let f x = ()
f 12 // Compiles!
```
Now consider this code:
```fsharp
[]
module M =
let f x = ()
open M // Compile error!
f 12
```
In the second example, we cannot `open M` because of the `RequireQualifiedAccess` attribute.
However, we can get around that by plopping `AutoOpen` in the attribute list and removing the `open M` declaration.
Contributor guide
Assessment
This issue has not been assessed yet.