jhass changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.7.2 | Paste > 3 lines of text to https://gist.github.com | GH: https://github.com/manastech/crystal - Docs: http://crystal-lang.org/docs/ | API: http://crystal-lang.org/api/ | Logs: http://irclog.whitequark.org/crystal-lang
bcardiff has joined #crystal-lang
bcardiff1 has quit [Read error: Connection reset by peer]
bcardiff has quit [Ping timeout: 272 seconds]
bcardiff has joined #crystal-lang
bcardiff has quit [Quit: Leaving.]
Locke23rus has quit [Remote host closed the connection]
kulelu88 has joined #crystal-lang
vikaton has quit []
c355E3B has quit [Quit: Connection closed for inactivity]
datanoise has quit [Ping timeout: 276 seconds]
vikaton has joined #crystal-lang
kulelu88 has left #crystal-lang ["Leaving"]
Cidan is now known as zz_Cidan
bcardiff has joined #crystal-lang
datanoise has joined #crystal-lang
bcardiff has quit [Quit: Leaving.]
NeverDie_ has joined #crystal-lang
NeverDie has quit [Read error: Connection reset by peer]
JBat has joined #crystal-lang
JBat has quit [Client Quit]
JBat has joined #crystal-lang
JBat has quit [Client Quit]
<vikaton> IO.puts?
<vikaton> wat is this elixir?
ponga has joined #crystal-lang
shama has quit [Remote host closed the connection]
shama has joined #crystal-lang
shama has quit [Remote host closed the connection]
<strcmp1> whats weird about it
<strcmp1> it comes from ruby btw
NeverDie_ is now known as NeverDie
strcmp1 has quit [Quit: Leaving]
JBat has joined #crystal-lang
ponga has quit [Quit: Leaving...]
JBat has quit [Ping timeout: 265 seconds]
bcardiff has joined #crystal-lang
NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
havenwood has joined #crystal-lang
mdz_ has joined #crystal-lang
mdz_ has quit [Remote host closed the connection]
bcardiff has quit [Quit: Leaving.]
vikaton has quit [Quit: Connection closed for inactivity]
havenwood has quit [Ping timeout: 258 seconds]
Ven has joined #crystal-lang
Ven has quit [Client Quit]
datanoise has quit [Ping timeout: 256 seconds]
Ven has joined #crystal-lang
sfate has joined #crystal-lang
ponga has joined #crystal-lang
BlaXpirit has joined #crystal-lang
zipR4ND has joined #crystal-lang
sandelius has joined #crystal-lang
leafybasil has quit [Remote host closed the connection]
datanoise has joined #crystal-lang
mdz_ has joined #crystal-lang
sfate has quit [Ping timeout: 240 seconds]
mdz_ has quit [Ping timeout: 265 seconds]
datanoise has quit [Ping timeout: 264 seconds]
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Ven has joined #crystal-lang
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zipR4ND has quit [Ping timeout: 272 seconds]
Ven has joined #crystal-lang
mdz_ has joined #crystal-lang
mdz_ has quit [Ping timeout: 276 seconds]
leafybasil has joined #crystal-lang
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ponga has quit [Remote host closed the connection]
ponga has joined #crystal-lang
ponga has quit [Ping timeout: 255 seconds]
sandelius has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sandelius has joined #crystal-lang
sandelius has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sandelius has joined #crystal-lang
<sandelius> does Crystal have self.inherited(base) ?
<jhass> sandelius: macro inherited
<jhass> {{@type}} is the base
<sandelius> jhass where's it defined? Could not find it in the API docs
<jhass> it's a special macro invoked by the compiler, so probably just undocumented
<sandelius> ok
<sandelius> jhass Ahh there it's, thanks. I'm considering porting my little web framework to Crystal http://ramverk.org
<jhass> nice
<sandelius> it's super fast and I took the best parts from Rails (and slimmed them down) and express.js.
ponga has joined #crystal-lang
<sandelius> jhass do you know if it's possible to have the macro inherited inside a module that uses included?
<jhass> sandelius: yup it is, you just need to take care to escape the inner macro variables so they won't get interpreted by the included macro
<jhass> macros are just templates that should generate code that's fed back into the compiler
<jhass> and by fed back I mean literally the parser stage
<sandelius> jhass this is what I got so far https://gist.github.com/sandelius/b92de386d0ef3f3d4495
havenwood has joined #crystal-lang
<jhass> oh, no I don't think it works that way
<jhass> I think you need to include the macro inherited directly into the macro included definition
<jhass> at least I got it working that way once
<sandelius> jhass when I do that it puts the B twice
<jhass> this way you attach the macro inherited to ClassMethods
<jhass> well, as said, escape the inner one
<sandelius> jhass don't really know what you mean by that? :)
<jhass> eh, right nvm
<jhass> interesting
<jhass> mmh
<jhass> I don't follow why it does that, but I think it's a bug
<jhass> sure I can follow what it should do
<sandelius> ahh you mean like that :)
<jhass> well, those will need to be macros anyway
<jhass> so not sure it's worth to keep the ClassModule structure at all
<jhass> *ClassMethods
<sandelius> jhass I guess I could define the methods inside the macro
<jhass> you'll have to
<jhass> class_attribute will have to be a macro
<sandelius> ahh yeah that's true
vikaton has joined #crystal-lang
datanoise has joined #crystal-lang
zipR4ND has joined #crystal-lang
strcmp1 has joined #crystal-lang
c355E3B has joined #crystal-lang
datanoise has quit [Ping timeout: 245 seconds]
sandelius has quit [Read error: Connection reset by peer]
sandelius has joined #crystal-lang
Ven has joined #crystal-lang
unshadow has joined #crystal-lang
datanoise has joined #crystal-lang
<crystal-gh> [crystal] bararchy opened pull request #735: Process.kill & Process.getpgid (master...master) http://git.io/vItB3
datanoise has quit [Ping timeout: 265 seconds]
BlaXpirit has quit [Read error: Connection reset by peer]
BlaXpirit_ has joined #crystal-lang
BlaXpirit_ is now known as BlaXpirit
asterite has joined #crystal-lang
<unshadow> I'm working on a spec, I want to check if return value is between 0..65535, but doing Process.getpgid(pid.to_i).should eq(0..65535) returns an error:
<unshadow> Failure/Error: Process.getpgid(pid.to_i).should eq(0..65535)
<unshadow> expected: 0..65535
<unshadow> got: 30663
<jhass> kinda backwards but (0..65535).should contain Process.getpgid would work
<jhass> might just add a matcher for what you need to https://github.com/manastech/crystal/blob/master/src/spec/expectations.cr
mdz_ has joined #crystal-lang
bcardiff has joined #crystal-lang
NeverDie has joined #crystal-lang
sandelius has quit [Quit: Textual IRC Client: www.textualapp.com]
datanoise has joined #crystal-lang
<unshadow> jhass: send a PR you said, it will be fun you said.... yeha...
<jhass> it isn't? :o
<jhass> :P
<unshadow> hahah
<jhass> unshadow: Process.kill(pid.to_i, Signal::SIGKILL).should eq(0) # you missed that one btw ;)
<unshadow> >> puts Signal::SIGKILL
<DeBot> unshadow: Error in line 4: undefined constant Signal::SIGKILL - http://carc.in/#/r/1pk
<unshadow> >> puts Process::Signal::SIGKILL
<DeBot> unshadow: Error in line 4: undefined constant Process::Signal::SIGKILL - http://carc.in/#/r/1pl
<unshadow> >> Signal::KILL
<DeBot> unshadow: # => 9 - http://carc.in/#/r/1pm
<jhass> ah, right, my bad
<jhass> ♥
<unshadow> XD
<BlaXpirit> what the heck how did u
<BlaXpirit> why is this heart red for me
<BlaXpirit> oh, of course, it's IRC....
<jhass> ;)
<jhass> and the channel doesn't have +c set
<jhass> sorry, won't do that again :P
<unshadow> how can I color the text ?
<unshadow> that's cool :)
<jhass> depends on your client
<unshadow> irssi
<BlaXpirit> let's just not :|
<unshadow> hahaha
<unshadow> %rtest
<unshadow> %r test
<unshadow> :(
<unshadow>  3 test
<unshadow> test
<unshadow> yehhhhh
jqwark has joined #crystal-lang
bcardiff1 has joined #crystal-lang
bcardiff has quit [Ping timeout: 264 seconds]
zipR4ND has quit [Ping timeout: 240 seconds]
asterite has quit [Ping timeout: 246 seconds]
shama has joined #crystal-lang
<unshadow> So, do I get the green light for merge ?
<jhass> lgtm
mdz_ has quit [Remote host closed the connection]
mdz_ has joined #crystal-lang
aemadrid has joined #crystal-lang
havenwood has quit [Quit: Textual IRC Client: www.textualapp.com]
leafybasil has quit []
c355E3B has quit [Quit: Connection closed for inactivity]
vikaton has quit [Quit: Connection closed for inactivity]
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zz_Cidan is now known as Cidan
Cidan is now known as zz_Cidan
zz_Cidan is now known as Cidan
havenwood has joined #crystal-lang
jqwark has quit [Quit: Page closed]
n1ftyn8 has quit [Remote host closed the connection]
endou_________ has quit [Remote host closed the connection]
vikaton has joined #crystal-lang
aemadrid has quit [Quit: Connection closed for inactivity]
vikaton has quit [Remote host closed the connection]
emmanueloga has quit [Remote host closed the connection]
bcardiff has joined #crystal-lang
sandelius has joined #crystal-lang
bcardiff1 has quit [Ping timeout: 264 seconds]
sandelius has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sandelius has joined #crystal-lang
n1ftyn8 has joined #crystal-lang
endou_________ has joined #crystal-lang
emmanueloga has joined #crystal-lang
mdz_ has quit [Remote host closed the connection]
mdz_ has joined #crystal-lang
mdz_ has quit [Remote host closed the connection]
vikaton has joined #crystal-lang
<crystal-gh> [crystal] asterite closed pull request #735: Process.kill & Process.getpgid (master...master) http://git.io/vItB3
BlaXpirit has quit [Quit: Quit Konversation]
<travis-ci> manastech/crystal#2409 (master - fc57e45 : Ary Borenszweig): The build passed.
<crystal-gh> [crystal] asterite pushed 1 new commit to master: http://git.io/vIYQb
<crystal-gh> crystal/master 3bced71 Ary Borenszweig: Made Signal an enum, and let Process.kill use it as a type restriction. Also added Process.kill variant that accepts many pids.
sandelius has quit [Quit: Textual IRC Client: www.textualapp.com]
<travis-ci> manastech/crystal#2410 (master - 3bced71 : Ary Borenszweig): The build passed.
vikaton has quit []
vikaton has joined #crystal-lang
mdz_ has joined #crystal-lang
mdz_ has quit [Remote host closed the connection]
bcardiff has quit [Quit: Leaving.]
vikaton has quit []
Cidan is now known as zz_Cidan
zz_Cidan is now known as Cidan
vikaton has joined #crystal-lang
mdz_ has joined #crystal-lang
asterite has joined #crystal-lang
mdz_ has quit [Ping timeout: 245 seconds]
asterite has quit [Ping timeout: 246 seconds]
<flaviu> Is there some way to jump to the definition of something?
<jhass> didn't see anything specifically for crystal yet
<jhass> the general jump to definition thingies with ruby support should work for most cases
<flaviu> Well, since the compiler does type inference, there should be a way to figure out exactly what's going to be called
<jhass> yeah
<jhass> first step is to be able to fully introspect a program with errors though ;)
<flaviu> Also, /doc should really be in the gitignore
<jhass> so there are ideas but nothing implemented yet
<flaviu> but, yeah, that might also be good there
<jhass> ah right, forgot those
<jhass> I think asterite made one too
bcardiff has joined #crystal-lang
<flaviu> Does crystal spawn a new process for each file it compiles?
<flaviu> Because my profiler says its spending a shit-ton of time in page copying.
<jhass> mmh, I thought it spawns a process or thread per core
<jhass> though no idea, might be all llvm itself
<flaviu> Well, 1290 clone syscalls is a little more than my 4-core CPU needs :)
<jhass> yeah, that's probably not a good idea
<jhass> should slice the units into n arrays and fork for each slice
<jhass> looks like a fun first contribution ;)
<crystal-gh> [crystal] flaviut opened pull request #736: Add /doc/ to gitignore (master...improve-gitignore) http://git.io/vIO4B
<flaviu> jhass: A little late for a first contribution ;) https://github.com/manastech/crystal/pull/736
<jhass> oh, sorry
<flaviu> I'll look into it. I can only imagine what it's like on windows, where forking is actually expensive.
<jhass> I'd still expect to see a small speedup on linux, that's a shit ton of clone calls indeed