jhass changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.7.3 | 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
havenn has quit [Ping timeout: 264 seconds]
vifino has joined #crystal-lang
mdz_ has joined #crystal-lang
mdz_ has quit [Ping timeout: 264 seconds]
<crystal-gh> [crystal] asterite pushed 2 new commits to master: http://git.io/vIj1K
<crystal-gh> crystal/master c877a7c Tobias Pfeiffer: "as" isn't used for comparisons like this
<crystal-gh> crystal/master 644bf9c Ary Borenszweig: Merge pull request #754 from PragTob/context-spec-grammar-fix...
<travis-ci> manastech/crystal#2472 (master - 644bf9c : Ary Borenszweig): The build passed.
<crystal-gh> [crystal] asterite pushed 4 new commits to master: http://git.io/vIjDH
<crystal-gh> crystal/master 41a8876 Ary Borenszweig: Codegen: automatically inline enum constants
<crystal-gh> crystal/master 6edd2f4 Ary Borenszweig: Fixed `String#[]` and `Array#[]` semantic for some border cases.
<crystal-gh> crystal/master 46d71cc Ary Borenszweig: Fixed: special vars didn't work in methods with default arguments
n0xff has joined #crystal-lang
flaviu has joined #crystal-lang
<travis-ci> manastech/crystal#2473 (master - d83c239 : Ary Borenszweig): The build passed.
zipR4ND has joined #crystal-lang
havenwood has joined #crystal-lang
zipR4ND has quit [Ping timeout: 255 seconds]
bcardiff has quit [Quit: Leaving.]
<vikaton> is def times(x: T) a generic function?
asterite has joined #crystal-lang
<asterite> vikaton: all methods are generic in crystal
<asterite> jeromegn: you can do `include OtherStruct` in C bindings, I forgot to document this
<vikaton> never thought of that lol
<vikaton> well that works though
<asterite> Yes, that's just for setting T as the type of x
asterite has quit [Quit: Page closed]
xd1le has joined #crystal-lang
<xd1le> what does wrong number of type vars mean?
<xd1le> For example: http://carc.in/#/r/31u
mdz_ has joined #crystal-lang
drizz has quit [Ping timeout: 244 seconds]
mdz_ has quit [Ping timeout: 240 seconds]
drizz has joined #crystal-lang
xd1le has quit [Ping timeout: 265 seconds]
xd1le has joined #crystal-lang
xd1le is now known as Guest15564
Guest15564 has quit [Client Quit]
<wmoxam> ^^ this segfaults, just wondering if it's a known issue
<wmoxam> (I didn't see anything in a quick look in the issues)
icezimm has quit [Quit: Leaving.]
asterite has joined #crystal-lang
<asterite> wmoxam: in doubt, please report it as a bug. It's an infinite type recursion bug
asterite has quit [Ping timeout: 246 seconds]
mdz_ has joined #crystal-lang
mdz_ has quit [Ping timeout: 252 seconds]
epitron is now known as epitron_
epitron_ is now known as epitron
jua_ has joined #crystal-lang
bcardiff has joined #crystal-lang
fowlduck has quit [Remote host closed the connection]
jua_ has quit [Ping timeout: 264 seconds]
bcardiff has quit [Quit: Leaving.]
jua_ has joined #crystal-lang
BlaXpirit has joined #crystal-lang
unshadow has joined #crystal-lang
<unshadow> >> a = {} of String => Bool; a["testing"] = true'; puts a
<DeBot> unshadow: Syntax error in eval:4: unterminated char literal - http://carc.in/#/r/325
<unshadow> >> a = {} of String => Bool; a["testing"] = true; puts a
<DeBot> unshadow: {"testing" => true} - more at http://carc.in/#/r/326
<unshadow> >> a = {} of String => Bool; a["testing"] = "true"; puts a
<DeBot> unshadow: Error in line 4: no overload matches 'Hash(String, Bool)#[]=' with types String, String - http://carc.in/#/r/327
NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
havenwood has quit [Ping timeout: 246 seconds]
zipR4ND has joined #crystal-lang
n0xff has quit [Remote host closed the connection]
unshadow has quit [Quit: leaving]
zipR4ND has quit [Ping timeout: 244 seconds]
mdz_ has joined #crystal-lang
mdz_ has quit [Ping timeout: 276 seconds]
unshadow has joined #crystal-lang
<unshadow> Someone has a small exmaple of how to use OptionParser ?
wmoxam has quit [Quit: leaving]
wmoxam has joined #crystal-lang
<unshadow> >> puts 1 => 2
<DeBot> unshadow: Syntax error in eval:4: unexpected token: => - http://carc.in/#/r/32g
<unshadow> >> puts 1 <= 2
<DeBot> unshadow: true - more at http://carc.in/#/r/32h
<unshadow> >> puts 1 =< 2
<DeBot> unshadow: Syntax error in eval:4: unexpected token: = - http://carc.in/#/r/32i
<unshadow> >> puts 1 => 2
<DeBot> unshadow: Syntax error in eval:4: unexpected token: => - http://carc.in/#/r/32j
<unshadow> >> puts 1 >= 2
<DeBot> unshadow: false - more at http://carc.in/#/r/32k
<crystal-gh> [crystal] asterite pushed 5 new commits to master: http://git.io/vLv1O
<crystal-gh> crystal/master 30d55de Tobias Pfeiffer: Basic documentation for crystal's spec standard library :)
<crystal-gh> crystal/master 34c8f1a Tobias Pfeiffer: Worked in feedback from @kirbyfan64
<crystal-gh> crystal/master f9c4383 Tobias Pfeiffer: Remove reference to ruby
grindhold has joined #crystal-lang
<grindhold> can i use crystal shards from c? when i try nm -D on a lib i compiled with crystal i can't see any symbols exposed that resemble the methods i wrote in my crystal library
<jhass> grindhold: at the moment the language provides no "please export this function into a library" flag, however the names of fun's are not mangled afaik
<jhass> >> fun foo; puts "Hello World"; end; foo
<DeBot> jhass: Error in line 7: undefined method 'inspect' for Void - http://carc.in/#/r/32m
<jhass> >> fun foo; puts "Hello World"; end; foo; nil
<DeBot> jhass: Hello World - more at http://carc.in/#/r/32o
<grindhold> jhass: i thought fun was only for declaring functions that reside in c libraries. how does it work the other way round?
<jhass> fun inside lib definitions, outside lib definitions fun just creates a function, similar to what a C function would be generated as, from my understanding
<grindhold> jhass: maybe i should ask one more basic question first: why does crystal still compile elf-executables instead of a shared object even when i initialize my project with the "lib"-parameter
<travis-ci> manastech/crystal#2475 (master - 5d251b9 : Ary Borenszweig): The build passed.
<jhass> atm lib projects are designed to be pulled as source into other projects
<grindhold> ah okay, so it's currently only providing namespace infrastructure
<jhass> yes
<jhass> crystal doesn't support precompiled libraries written in Crystal, at least not yet
<grindhold> jhass: is it planned for the foreseeable future?
<jhass> no idea, I'm not making the roadmap ;)
<grindhold> :) okay
<grindhold> i'd really love to move from vala to crystal as crystal does not impose glib-2.0 as dependency for any project, but only for the ones i use gobject introspection in
<jhass> for the moment the workflow is similar to dynamic languages, say ruby gems, python modules, perl cpan thingys (modules?)
Ven has joined #crystal-lang
<grindhold> well, this makes it impossible to separate libraries into binary packages :|
<grindhold> at least for now
<jhass> yes, crystal's still young so we'll see
<jhass> on the plus side if you use say only 3 functions from a 50kloc library only these will end up in your binary
<grindhold> that's true
havenwood has joined #crystal-lang
mdz_ has joined #crystal-lang
<jeromegn> crystal’s development is so active
<jeromegn> I love it
<unshadow> jhass: Can you please take a look at this code: http://carc.in/#/r/32v when I try to run it with giving it some arguments it seems to crash
<unshadow> I want to make sure if this is a bug or a mistake I made by following a Ruby guide
<jhass> why don't you indent begin /rescue blocks :/
mdz_ has quit [Ping timeout: 245 seconds]
<unshadow> I dont want them, it was just a quick debug, usually I do :)
<vikaton> I wonder how heavy Amethyst is
<vikaton> looks p cool
<jhass> unshadow: your flag definitions are wrong
<jhass> it's "-t THREADS" for example
<jhass> "-t" is a parameterless flag
<unshadow> haaa
<jeromegn> jhass: been thinking of contributing some design to carc.in. Love what you’ve done, but I think it could probably benefit from some small css tweaks :)
<unshadow> jhass: Thanks :)
<jhass> unshadow: specs usually provide good hints ;) https://github.com/manastech/crystal/blob/master/spec/std/option_parser_spec.cr
<jhass> jeromegn: sure whatever, just open a pull request ,)
<jhass> ;)
<jeromegn> will do!
<jeromegn> need to do some client work first and then I’ll be on it
<jhass> jeromegn: you can point the api host just to the production server, that atm has wide open CORS headers
<jeromegn> oh that’s nice
<jeromegn> should be easier for dev
<jhass> yeah, else you'd need to build a sandbox and that's quite specific to the systems I run :P
<jeromegn> I bet
<jhass> I mean it should work on any archlinux (or derivate) with a btrfs but still
<jeromegn> jhass: yea I’ve set that up once in a VM. Not the greatest experience.
<jeromegn> why btrfs though?
<jhass> sublvolumes & subvolume snapshot
<jeromegn> we use btrfs in production at work for our container architecture
<unshadow> vikaton: Yeha :) I like codecore's project
<jhass> base sandbox -> snapshot, install tools to build language -> snapshot, install specific version
<jeromegn> vikaton: I think so too. however, without some decent templating lib it might suck
<vikaton> jeromegn: whats wrong with ecr ?
<jhass> takes up no extra space
<jeromegn> vikaton: I’d say what’s wrong is that you need extra code outside the file to make it work (basically, you need to create a class to handle it)
<jeromegn> I’d like something simpler, runtime-evaled. I don’t mind if it offers less functionalities
<jeromegn> like mustache
<jhass> liquid, handlebars, mustache, I think slim has a non-evaling variant too
<jeromegn> yea
<jeromegn> I had a plan to inspire from the Markdown parser in the standard lib to create a small templating language that looks like slim
<jeromegn> I’ve never written a lexer before
<jhass> that'd be great, I like slim
<flaviu> Has there been any talk of a different GC than Boehm?
<flaviu> I saw some mention of it being temporary, but I don't know of any concrete plans.
<jhass> I think there are no concrete plans
<jhass> there simply are bigger pain points atm
<flaviu> I see. Has anyone written down a list of the problems? I'm occupied atm, but I'd like to help out when I get the time.
jeromegn has quit [Ping timeout: 264 seconds]
<unshadow> :)
jeromegn has joined #crystal-lang
NeverDie has joined #crystal-lang
NeverDie has quit [Max SendQ exceeded]
NeverDie has joined #crystal-lang
<unshadow> it looks like I have some issues with spawn, the code here -> http://carc.in/#/r/32w should at least return "conn" once
unshadow has quit [Quit: leaving]
_whitelogger has joined #crystal-lang
_unshadow_ has joined #crystal-lang
mdz_ has joined #crystal-lang
mdz_ has quit [Ping timeout: 276 seconds]
_unshadow_ has quit [Quit: AndroIRC - Android IRC Client ( http://www.androirc.com )]
Codcore has joined #crystal-lang
<crystal-gh> [crystal] waj pushed 3 new commits to master: http://git.io/vLfIE
<crystal-gh> crystal/master 8bca56f Juan Wajnerman: Added Regex#==
<crystal-gh> crystal/master f268c6f Juan Wajnerman: Added TypeNode#type_params for macros
<crystal-gh> crystal/master 15237cc Juan Wajnerman: Added StringIO#to_slice
_unshadow_ has joined #crystal-lang
<travis-ci> manastech/crystal#2476 (master - f268c6f : Juan Wajnerman): The build passed.
Codcore has quit [Quit: Page closed]
_unshadow_ has quit [Quit: AndroIRC - Android IRC Client ( http://www.androirc.com )]
asterite has joined #crystal-lang
<asterite> grindhold: there won't be precompiled libraries, it's kind of impossible because everything is a template in crystal
<asterite> It's almost like asking for precompiled Ruby libraries
<asterite> (not that I don't see the point in doing that, it's just that it's kind of hard/impossible to do at the moment)
<jhass> asterite: found another interesting attempt: http://carc.in/#/r/2y9
<asterite> jhass: interesting. it works with `bar` instead of `<` so I wonder if we should support that too
<jhass> yep, my thoughts
<jhass> http://carc.in/#/r/2ys this is one where I think the error could be improved
<asterite> flaviu: my plan is to make a Roadmap/"TODO list" and make that public so anyone can contribute and we solve those issues faster. I just have to sit down with waj and do it, but we also have to finish the talk for Prague... I wish we had more time for everything :/
<flaviu> I know that feeling :)
havenwood has quit [Ping timeout: 272 seconds]
asterite has quit [Ping timeout: 246 seconds]
<vikaton> >> (-3).to_s(2)
<DeBot> vikaton: # => "-11" - http://carc.in/#/r/32x
<vikaton> shouldnt that be 11111111111111111111111111111101 ?
<jhass> no
<jhass> to_s(2) converts to a general representation, not a specific implementation
<vikaton> o
<jhass> just because it's the latter in your computers memory it doesn't make sense a general representation
<jhass> else -3.to_s(10) would need to yield the same thing
<jhass> (or any base)
<jhass> and 3.to_s(10) would need to yield 0000000000000000011 or whatever
<jhass> *as a general
<vikaton> thanks for the explanation
<vikaton> > -3.to_s(10)
<vikaton> >> -3.to_s(10)
<DeBot> vikaton: # => "-3" - http://carc.in/#/r/32y
bcardiff has joined #crystal-lang
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Ven has joined #crystal-lang
havenwood has joined #crystal-lang
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mdz_ has joined #crystal-lang
tilpner has left #crystal-lang ["Have an awesome day!"]
mdz_ has quit [Ping timeout: 264 seconds]
jua__ has joined #crystal-lang
jua_ has quit [Ping timeout: 264 seconds]
NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
bcardiff has quit [Quit: Leaving.]
jua__ has quit [Quit: Vision[0.9.7-H-20140108]: i've been blurred!]
BlaXpirit has quit [Quit: Quit Konversation]
Dreamer3 has quit [Quit: Computer has gone to sleep.]
havenwood has quit [Ping timeout: 272 seconds]
zipR4ND has joined #crystal-lang
zipR4ND has quit [Ping timeout: 240 seconds]
havenwood has joined #crystal-lang
willl has quit [Quit: Connection closed for inactivity]