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 | Please consider participating in our mailing lists => https://pony.groups.io/g/pony
tj800x has quit [Quit: Page closed]
Matthias247 has quit [Read error: Connection reset by peer]
tj800x_ has quit [Quit: Page closed]
jemc has quit [Ping timeout: 268 seconds]
smoon has quit [Quit: smoon]
smoon has joined #ponylang
smoon has quit [Client Quit]
jemc has joined #ponylang
jemc has quit [Ping timeout: 248 seconds]
jemc has joined #ponylang
_whitelogger has joined #ponylang
smoon has joined #ponylang
jemc has quit [Ping timeout: 260 seconds]
smoon has quit [Quit: smoon]
smoon has joined #ponylang
smoon has quit [Quit: smoon]
smoon has joined #ponylang
acarrico has joined #ponylang
smoon has quit [Quit: smoon]
jemc has joined #ponylang
_whitelogger has joined #ponylang
smoon has joined #ponylang
smoon has quit [Quit: smoon]
jemc has quit [Ping timeout: 240 seconds]
amclain has quit [Quit: Leaving]
endformationage has quit [Quit: WeeChat 1.7]
<SeanTAllen> @Praetonus do you have a simple reproduction case for the String.reserve bug?
<Praetonus> This will eventually segfault in the loop from accessing random memory
<Praetonus> Also the same bug exists for String.create
Matthias247 has joined #ponylang
<SeanTAllen> Can you open an issue for that praetonus and i'll take a shot at it while i am polyconf'ing today (although i might not get through it before i start vacation).
<SeanTAllen> Pony 0.15.0 has been released. Upgrading as soon as possible is recommended: https://www.ponylang.org/blog/2017/07/0.15.0-released/
<Praetonus> SeanTAllen: Will do
<SeanTAllen> thanks
<SeanTAllen> i spent the last 3 hours working on release notes and 0.15.0 release. there was a lot to cover.
Bombe has quit [Ping timeout: 255 seconds]
Bombe has joined #ponylang
papey_lap has joined #ponylang
Matthias247 has quit [Read error: Connection reset by peer]
smoon has joined #ponylang
smoon has quit [Client Quit]
_whitelogger has joined #ponylang
Praetonus has quit [Quit: Leaving]
kempe has quit [Quit: WeeChat 1.5]
kempe has joined #ponylang
krisleipus has joined #ponylang
krisleipus has quit [Client Quit]
jemc has joined #ponylang
jemc has quit [Quit: WeeChat 1.4]
jemc has joined #ponylang
smoon has joined #ponylang
smoon has quit [Quit: smoon]
Praetonus has joined #ponylang
jemc has quit [Ping timeout: 248 seconds]
jemc has joined #ponylang
jemc has quit [Ping timeout: 268 seconds]
tj800x has joined #ponylang
<tj800x> I'm working on an article, possibly a book about learning pony. I'd like to share an analogy and get some feedback.
<tj800x> What is is central, and so-far unique, to the Pony programming language is the idea that it provides a way to write highly concurrent programs without requiring the programmer to manage locking critical resources like shared memory. Whenever two independent threads access the same shared mutable memory there is a danger that update-timing might conflict with read-timing, resulting in one or both threads having invalid data. The stan
<tj800x> he standard solution to this problem is to have locking mechanisms that only allow reading of data when no updating is occurring, and to only allow writing of data when no reads are occuring. Pony's solution is to structure the language in such a way as to allow the compiler to detect and enforce the two basic rules.
<tj800x> The Two Basic Rules of Concurrency
<tj800x> 1. When reading shared memory, no other thread must be allowed to read or write to that shared memory.
<tj800x> 2. When writing to shared memory, no other thread may read from that shared memory.
<tj800x> ## Six Memory Access Mechanisms Pony adheres to these two rules through the use of six different mechanisms to access memory. Those mechanisms are isolated memory access, transition memory access, reference memory access, immutable memory access, opaque memory access, and box memory access.
<tj800x> Since Pony's way of managing shared memory is so new and unique it is often hard to imagine how this might work, especially at compile-time.
<tj800x> ## A Dancing Analogy Modern Western Square Dancing is a form of dance involving multiple partners where the dancers move through time and space and interactive in predetermined ways.
<tj800x> Much like the way square dancers follow a series of steps as to avoid running into each other, the Pony compiler uses the Six Memory Access Mechanisms to ensure that data collisions access collisions do not take place.
<tj800x> The difference is that instead of physical space, potential conflicts exist in memory space. Individual actors, operating separately are capable of of managing memory without conflicts.
<tj800x> An immutable memory read could be thought of as viewing a tile on the floor. Multiple dancers (actors) can examine the state without conflict.
<tj800x> An isolated memory read can be thought of as stepping onto a particular tile. Only one actor may perform this action at a time and once the actor steps onto the tile "they own it" until they decide to release the exclusive access to that tile.
<tj800x> Reference memory access is like two dancing partners surrounding a tile. These dancing partners are akin to multiple memory aliases withing the same actor.
endformationage has joined #ponylang
<tj800x> These aliases, because they are part of a dance partnership ("An actor") are capable of coordinated activity.
<tj800x> The analogy can be extended in that the dance partners allow others to "look around their feet" to determine the status of the tile ("memory")
<tj800x> Opaque memory access is the equivalent of calling out the coordinates of the tile within the dance floor. It is information that can be freely shared among dancers (actors) without actually revealing any information about the tile's content.
<tj800x> I'm not sure how to describe transitive memory access.
<tj800x> Thoughts?
<cquinn> I think you have #1 and #2 mixed up a bit. I'd say it: 1. When writing shared memory, all other threads must be prevented from reading or writing to that memory. 2. When reading from shared memory, all other threads must be prevented from writing to that memory.
<tj800x> Ahhh...yes. I need to go back and fix that.
smoon has joined #ponylang
<tj800x> Oh and I skipped box. I've got to figure that one out too.
<cquinn> the dancing analogy is interesting. But I don't see how you can describe multiple references within one actor vs across actors.
<tj800x> I was thinking aliases are dance partners.
<cquinn> but coming up with a good analogy will be a big win
<tj800x> I'm no dancer myself, but my understanding is that dance partners work together. Within a single actor my understanding is that aliases are coordinated and that is why two refs aliases can read and write to the memory space.
<tj800x> All analogies break down of course, but I'm trying to take something concepts that I found absolutely foreign and make them a bit more accessible.
<tj800x> I've used this analogy to my non-techie family to explain how Pony is different than traditional programming...which I have described as more of a mosh pit.
<tj800x> That is probably not giving traditional lock-based programming its full due, but the idea of 1000 people crashing around in a mosh pit versus a 1000 people doing fancy square dancing makes an impact.
<tj800x> I will pull all this together and send it out on the mailing list. That is probably a better forum.
chamar has joined #ponylang
obadz has quit [Ping timeout: 240 seconds]
obadz has joined #ponylang
mikeyhew has joined #ponylang
mikeyhew has quit [Client Quit]
mikeyhew has joined #ponylang
Praetonus has quit [Quit: Leaving]
papey_lap has quit [Ping timeout: 260 seconds]
smoon has quit [Quit: smoon]
smoon has joined #ponylang
SimonJF has joined #ponylang
smoon has quit [Quit: smoon]
papey_lap has joined #ponylang
<SeanTAllen> tj800x: "When writing to shared memory, no other thread may read from that shared memory." <-- you dont want 2 threads writing to the same memory either
<SeanTAllen> ah i see you already covered that with cquinn
papey_lap has quit [Ping timeout: 255 seconds]
smoon has joined #ponylang
smoon has quit [Client Quit]
chamar has quit [Quit: Konversation terminated!]
<mikeyhew> Are there docs for the standard library somewhere?
<mikeyhew> never mind, I found them
<SeanTAllen> they are automatically extracted from the source mikeyhew, so you can also view the src in packages/ as well for all docs. there's an open bug at the moment for constructor doc strings not appearing in the generated documentation.
<mikeyhew> Thanks Sean
endformationage has quit [Read error: Connection reset by peer]
endformationage has joined #ponylang
endformationage has quit [Read error: Connection reset by peer]
smoon has joined #ponylang
smoon has quit [Client Quit]
smoon has joined #ponylang
smoon has quit [Client Quit]
autodidaddict has joined #ponylang
smoon has joined #ponylang
smoon has quit [Quit: smoon]
<autodidaddict> quick question.. if I'm maintaining an array of TCPConnection tags of clients connected to my server ... when I get the closed() notification for a given TCPConnection, how do I figure out _which_ TCP connection to remove from my array?
<autodidaddict> is there a UUID on the connection, or does the actor by virtue of being a tag automatically have uniqueness where I can do an equality check?