Skip to content
This repository has been archived by the owner on Jan 27, 2021. It is now read-only.

'None' class conflicts with typical F# code #11

Open
vivainio opened this issue May 12, 2018 · 2 comments
Open

'None' class conflicts with typical F# code #11

vivainio opened this issue May 12, 2018 · 2 comments

Comments

@vivainio
Copy link

None is a heavily used word in F# (https://docs.microsoft.com/en-us/dotnet/fsharp/language-reference/options)

If you do "open Schemy" in any F# program, it will almost certainly break because CommonTypes.cs defines it as a public class. Please consider changing the name.

@kflu
Copy link
Contributor

kflu commented May 12, 2018

Thanks. I could put common types under a more specific inner namespace, like Schemy.Types. Or, ideally, I need to think about if I really need this type None - currently, None and () are used quite interchangably in Schemy. And I think () is used to mean null or "empty" in Scheme in general. So maybe I should consolidate it with ().

@johnwcowan
Copy link

I'm not sure what "empty in general" would mean. () is specifically the empty list (as opposed to the empty vector or the empty string or whatever). It would probably be more Schemey, as opposed to Schemy :-), to call the class EmptyList. Scheme doesn't have any concept of null or None, although when interfacing with SQL it is not uncommon to use the Scheme symbol null for the purpose, since SQL has no notion of symbols.

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

No branches or pull requests

3 participants