jemc changed the topic of #ponylang to: Welcome! Please check out our Code of Conduct => https://github.com/ponylang/ponyc/blob/master/CODE_OF_CONDUCT.md | Public IRC logs are available => http://irclog.whitequark.org/ponylang
jemc has quit [Ping timeout: 240 seconds]
Praetonus has quit [Quit: Leaving]
Perelandric has quit [Ping timeout: 250 seconds]
runehog_ has quit []
runehog has joined #ponylang
c355e3b has quit [Quit: Connection closed for inactivity]
runehog has quit []
jemc has joined #ponylang
killerswan has joined #ponylang
killerswan has left #ponylang [#ponylang]
killerswan has joined #ponylang
killerswan has quit [Quit: killerswan]
killerswan has joined #ponylang
aturley has quit [Ping timeout: 264 seconds]
aturley has joined #ponylang
rurban has joined #ponylang
omarkj has quit [Ping timeout: 250 seconds]
gornikm has quit [Ping timeout: 250 seconds]
gornikm has joined #ponylang
omarkj has joined #ponylang
rurban has left #ponylang [#ponylang]
rurban1 has joined #ponylang
rurban2 has joined #ponylang
rurban1 has quit [Ping timeout: 265 seconds]
rurban2 has left #ponylang [#ponylang]
jemc has quit [Ping timeout: 260 seconds]
trapped has joined #ponylang
Praetonus has joined #ponylang
rurban has joined #ponylang
rurban has left #ponylang [#ponylang]
killerswan has quit [Quit: killerswan]
gsteed has joined #ponylang
rurban1 has joined #ponylang
killerswan has joined #ponylang
killerswan has quit [Client Quit]
killerswan has joined #ponylang
rurban1 has left #ponylang [#ponylang]
c355e3b has joined #ponylang
trapped_ has joined #ponylang
Perelandric has joined #ponylang
trapped has quit [Ping timeout: 258 seconds]
killerswan has quit [Quit: killerswan]
trapped_ has quit [Read error: Connection reset by peer]
tm-exa has joined #ponylang
rurban has joined #ponylang
aturley has quit [Ping timeout: 258 seconds]
rurban has quit [Quit: Leaving.]
tm-exa has quit [Quit: Computer has gone to sleep]
aturley has joined #ponylang
SilverKey has joined #ponylang
SilverKey has quit [Quit: Halted.]
SilverKey has joined #ponylang
SilverKey has quit [Quit: Halted.]
jemc has joined #ponylang
rurban has joined #ponylang
SilverKey has joined #ponylang
rurban has quit [Quit: Leaving.]
aturley has quit [Ping timeout: 265 seconds]
theodus has joined #ponylang
theodus has quit [Remote host closed the connection]
aturley has joined #ponylang
graaff has joined #ponylang
SilverKey has quit [Quit: Halted.]
SilverKey has joined #ponylang
theodus has joined #ponylang
zaquest has quit [Quit: Leaving]
theodus has quit []
SilverKey has quit [Quit: Halted.]
SilverKey has joined #ponylang
SilverKey has quit [Client Quit]
aturley has quit [Ping timeout: 276 seconds]
graaff has quit [Quit: Leaving]
tm-exa has joined #ponylang
tm-exa has quit [Client Quit]
SilverKey has joined #ponylang
rurban has joined #ponylang
emancu has joined #ponylang
tm-exa has joined #ponylang
tm-exa has quit [Client Quit]
rurban1 has joined #ponylang
aturley has joined #ponylang
rurban has quit [Ping timeout: 276 seconds]
rurban1 has left #ponylang [#ponylang]
aturley has quit [Ping timeout: 244 seconds]
aturley has joined #ponylang
rurban has joined #ponylang
rurban has quit [Client Quit]
aturley has quit [Ping timeout: 264 seconds]
aturley has joined #ponylang
SilverKey has quit [Quit: Halted.]
SilverKey has joined #ponylang
unbalancedparen has joined #ponylang
SilverKey has quit [Client Quit]
SilverKey has joined #ponylang
Matthias247 has joined #ponylang
killerswan has joined #ponylang
SilverKey has quit [Quit: Halted.]
emancu has quit []
killerswan has quit [Quit: killerswan]
killerswan has joined #ponylang
michael_campbell has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
killerswan has quit [Quit: killerswan]
jemc has quit [Ping timeout: 260 seconds]
hibnico has joined #ponylang
hibnico has quit [Client Quit]
SilverKey has joined #ponylang
SilverKey has quit [Quit: Halted.]
SilverKey has joined #ponylang
aturley has quit [Ping timeout: 265 seconds]
michael_campbell has joined #ponylang
<Perelandric> If I have an `var a: Array[Foo | Bar]` where `Foo` and `Bar` are primitives...
<Perelandric> should it be possible to assign an array literal?
<Perelandric> Like: `var a: Array[(Foo | Bar)] = [Foo, Foo]`
<Perelandric> Because it sees the Array literal as `Array[Foo]` when I try it.
<Perelandric> "Array[Foo val] ref has different type arguments than Array[(Foo val | Bar val)] ref"
Matthias247 has quit [Read error: Connection reset by peer]
<Praetonus> Perelandric: You can explicitly specify the element type of your array literal: `[as (Foo | Bar): Foo, Foo]`
<Perelandric> Thank you, Praetonus. That's what I was missing!
SilverKey has quit [Quit: Halted.]
killerswan has joined #ponylang
<Perelandric> Given: `type Foobar is ((Foo, USize) | (Bar, USize))` where `Foo` and `Bar` are still primitives.
<Perelandric> An assignment succeeds: `var test: Foobar = (Foo, USize(2))` ...
<Perelandric> But attempting to read from the tuple fails: `Debug(test._2.string())`
<Perelandric> "Error: can't lookup by name on a tuple" ... "Error: couldn't find _2 in (Foo val, USize val)"
<Perelandric> Seem like a bug? Or am I abusing the type system a little too much?
<Praetonus> Perelandric: I think what you're trying to do is impossible, but the compiler is giving you a really unhelpful error message. The thing with union types is that you can't access a field directly even if it exists in every member of the union, because the field layout of the members may differ
<Praetonus> Could you open an issue for that?
<Perelandric> That makes sense. I would need to use a `match` in any other situation, so here too.
<Perelandric> Yes, I'll open an issue in a little bit. Thanks again!
killerswan has quit [Quit: killerswan]
unbalancedparen has quit [Quit: WeeChat 1.5]
Praetonus has quit [Quit: Leaving]
unbalancedparen has joined #ponylang
aturley has joined #ponylang
bb010g has quit [Quit: Connection closed for inactivity]
unbalancedparen has quit [Client Quit]
aturley has quit [Ping timeout: 276 seconds]