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
endformationage has joined #ponylang
acarrico has joined #ponylang
voldyman has joined #ponylang
_whitelogger has joined #ponylang
_whitelogger has joined #ponylang
endformationage has quit [Quit: WeeChat 2.3]
a-pugachev has joined #ponylang
Foaly has joined #ponylang
a-pugachev has quit [Ping timeout: 245 seconds]
a-pugachev has joined #ponylang
Foaly has quit [Quit: Now 'mid shadows deep falls blessed sleep.]
srenatus has joined #ponylang
endformationage has joined #ponylang
_whitelogger has joined #ponylang
Foaly has joined #ponylang
a-pugachev has quit [Quit: a-pugachev]
EEVV has joined #ponylang
<EEVV> weird, I got a ponyc segmentation fault even though I was just messing with the code it is pretty useless
<EEVV> stack dump "Function Pass Manager", "Move heap allocations to the stack"
<EEVV> seems to be somehow an issue of my "AES" class
<EEVV> it uses OpenSSL but the fields are all pony types
<EEVV> I'm trying to recreate it in playground
<EEVV> I don't know if I can recreate it... doesn't seem to work
so has quit [Ping timeout: 246 seconds]
so has joined #ponylang
srenatus has quit [Quit: Connection closed for inactivity]
<SeanTAllen> which version of LLVM are you using EEVV ?
<EEVV> SeanTAllen, how can I check?
<SeanTAllen> well that depends on how you installed LLVM
<EEVV> on my OS (void linux) I used their packaging which makes a chroot and downloads the appropriate files as far as I know
<SeanTAllen> do you have llvm-config in your $PATH
<EEVV> no
<SeanTAllen> well then ¯\_(ツ)_/¯
<SeanTAllen> it could be installed anywhere
<SeanTAllen> anyway
<SeanTAllen> both llvm 5 and 6
<SeanTAllen> we had to work around a bug in "Move heap allocations to the stack"
<SeanTAllen> so its possible you found another
<SeanTAllen> if you are using llvm 5 or 6
<EEVV> hmm
<EEVV> I will check what version
<EEVV> I remember it is in the config files
<EEVV> SeanTAllen, yeah it says llvm6.0
<EEVV> is this version too high? What is the recommended
<SeanTAllen> we know of no bugs in 3.9.1
<SeanTAllen> 6.0 we dont know of bugs but the work around for the Move heap allocations to the stack issue would make generated code somewhat slower
<SeanTAllen> its possible that there are other issues
<SeanTAllen> I'm not saying that it is
<SeanTAllen> I'm saying that its possible
<EEVV> SeanTAllen, what I did is make a `Array[U8 val] val` variable (let) and use it twice for the class fields
<SeanTAllen> i take it you dont have a small reproducible case?
<EEVV> I can show you in a second
<EEVV> this doesn't work in playground however
<SeanTAllen> when you have one that works, open an issue and ill try to reproduce on macos with llvm 3.9.1
<EEVV> ok one second
<EEVV> yes
<EEVV> this one segfaults for me
<EEVV> might be able to tweak it further to get rid of the clutter (maybe _d doesn't need to be a union?)
<SeanTAllen> segfaults for me as well
<EEVV> :D
<SeanTAllen> try to narrow it down to smallest bit that does it
<SeanTAllen> open an issue with your OS, pony version, LLVM version
<EEVV> on pony-lang?
<SeanTAllen> and drop the link here and I'll add my information that it is more than just your particular versions
<SeanTAllen> github.com/ponylang/ponyc
<SeanTAllen> open an issue there
<SeanTAllen> be sure to include the code
a-pugachev has joined #ponylang
Foaly has quit [Quit: Now 'mid shadows deep falls blessed sleep.]
<SeanTAllen> thanks
<EEVV> SeanTAllen, how can I skip a body?
<EEVV> like instead of putting code, do nothing essentially
<SeanTAllen> sorry what?
<EEVV> empty method
<SeanTAllen> why do you want an empty method?
<EEVV> SeanTAllen, like a placeholder, sometimes I have nothing to put in methods
<EEVV> is there any guidelines for this?
<SeanTAllen> placeholder like in an interface?
<SeanTAllen> or like you know you want the method but you dont know what the actual implementation will be?
<EEVV> SeanTAllen, for example in `TCPConnectionNotify` don't put code in `closed` methods
<SeanTAllen> so that method has no return type so you can put `None` as the method of the body
<EEVV> oh wow
<SeanTAllen> ?
<EEVV> I don't know if I feel smarter or dumber now
<SeanTAllen> "no return type" is "None"
<EEVV> yeah I understand
<SeanTAllen> fun ref closed(conn: TCPConnection ref)
<SeanTAllen> and
<EEVV> it's just that I don't know how I didn't realize that
<SeanTAllen> fun ref closed(conn: TCPConnection ref): None
<SeanTAllen> are the same
<EEVV> yeah I understand
EEVV has quit [Ping timeout: 256 seconds]
Foaly has joined #ponylang
EEVV has joined #ponylang
<EEVV> Hello again, can I add a destructor for a class?
<SeanTAllen> can you define "destructor"?
<SeanTAllen> you can define _final() which will be run at some time after an object is garbage collected
<SeanTAllen> so if you wanted to do cleanup of some resources, you could do it there
<SeanTAllen> however, you shouldnt assume that it will happen when the object is gc'd
<EEVV> SeanTAllen, this is where I would put my `@free[None](x)` yes?
<EEVV> or any form of free
<SeanTAllen> well
<SeanTAllen> ummm
<SeanTAllen> im missing context
<SeanTAllen> i assume you mean "i manually allocated some memory and now i need to free it"
<SeanTAllen> if that is the case then yes
<SeanTAllen> you can also explicitly get memory from the pool allocator and if you do that, you don't need to manually free it
<SeanTAllen> if possible, the latter route is a better idea
EEVV has quit [Quit: Page closed]
acarrico has quit [Ping timeout: 268 seconds]
acarrico has joined #ponylang
acarrico has quit [Ping timeout: 245 seconds]
Foaly has quit [Quit: Now 'mid shadows deep falls blessed sleep.]