Closed jimfoye closed 5 years ago
I cannot reproduce it:
open System
module M =
type MyAttribute() =
inherit Attribute()
open M
[<My>]
type Foo() = class end
M
in open M
is not grayed out.
I suspect RemoteAttribute
is defined in a auto open module, not directly in WebSharper
?
No, it's just a type in the namespace WebSharper. Source is here:
If I try your code it also works fine for me.
A quick way to reproduce this is to just create a new sitelet app (I did it with the Websharper 4.0 beta VS extension, AKA "Zafir"), then open the generated "Remoting.fs" file. I'm attaching a screenshot - I have not edited this code, as did for my original post.
ok, I'll look at it (and play with WS 4 as well :) )
This is on 2.5.0. I searched prior issues but may have missed it.
See screenshots, the code is the Remoting.fs module from the Websharper (4.0 beta) Client Server template, very slightly modified.
The only symbol belonging to the WebSharper namespace is the Remote attribute on the DoSomething function. If the attribute lacks the "Attribute" suffix, then of course it's perfectly OK for the compiler, but now the namespace is grayed out. I would think that the expected behavior is that it's not.