> I agree with the idea in principle but I may be a symptom of a bigger 
> problem, which is how to represent data constructors generally.

Yep, I totally agree.

> We could of course introduce two or three letter sigils (or remove the 
> restriction altogether)

I like the idea of no limit for sigil names, I think this is really a good 
direction, even enabling people to use metaprograming to do some really 
interesting things (shorter_maps for example could be able to do 
`~MyStruct{id}` instead of `~M{%MyStruct id}`)

> how we would want to handle the casing in said situations

Well, IMO the convention adopted now is interesting but not very reasonable. I 
mean, I know the benefits we take from not allowing interpolation for some 
sigils (I suppose it might make a huge difference for some cases), but in the 
end it is just a convention and people are already allowed to break it right? 
What if we just don’t care about that at all and let people create sigils 
however they want? I don’t think we should change the current convention 
though, I think we must leave it as it is for one letter sigils and leave it 
open for more.

Best,
Kelvin Stinghen
kelvin.sting...@me.com

> On Oct 24, 2019, at 17:47, Wojtek Mach <woj...@wojtekmach.pl> wrote:
> 
> So this is a separate discussion but what I'd rather see is another sigil 
> like mechanism for structs that would make these valid:
> 
> URI[https://elixir-lang.org]
> Decimal[1]
> Complex[0, 1]
> Ratio[1, 3]
> MapSet[1, 2, 3]
> Money[100 USD]
> Date.Range[2019-01-01/12-31]
> 
> Having such mechanism doesn't address your concern but if such exists I feel 
> like at least sigils become less scarce because I feel like people would 
> reach out for them.
> If there's appetite for something like this, let me know. Off the bat there's 
> a huge difference semantically between Decimal[1] and Complex[0, 1] but maybe 
> there's a way to reconcile it.
> (Btw, it happens so that `Decimal[1]` is _syntactically_ correct but 
> `Complex[0, 1]` isn't :))
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "elixir-lang-core" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to elixir-lang-core+unsubscr...@googlegroups.com 
> <mailto:elixir-lang-core+unsubscr...@googlegroups.com>.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/elixir-lang-core/c7d345e5-b1df-4014-b683-ff499a1fada5%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/elixir-lang-core/c7d345e5-b1df-4014-b683-ff499a1fada5%40googlegroups.com?utm_medium=email&utm_source=footer>.

-- 
You received this message because you are subscribed to the Google Groups 
"elixir-lang-core" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to elixir-lang-core+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elixir-lang-core/6B80ED07-814E-4FA0-8E5D-FB846AC5983C%40gmail.com.

Reply via email to