RX14 changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.24.1 | Fund Crystal's development: http://is.gd/X7PRtI | GH: https://github.com/crystal-lang/crystal | Docs: http://crystal-lang.org/docs/ | API: http://crystal-lang.org/api/ | Gitter: https://gitter.im/crystal-lang/crystal
claudiuinberlin has quit [Quit: Textual IRC Client: www.textualapp.com]
<18WAAF1JF> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbpT2
<18WAAF1JF> crystal/master 856220c TSUYUSATO Kitsune: Fix to parse regex in default argument (#5481)
<7GHABPEJM> [crystal] RX14 closed pull request #5481: Fix to parse regex in default argument (master...fix/crystal/parse-regex-in-default-arg) https://git.io/vbNKj
<DeBot> https://github.com/crystal-lang/crystal/pull/5481 (Fix to parse regex in default argument)
<DeBot> https://github.com/crystal-lang/crystal/pull/5481 (Fix to parse regex in default argument)
cremes has joined #crystal-lang
<crystal-gh> [crystal] RX14 closed pull request #5447: Add Crystal::System::Dir (master...feature/system-dir) https://git.io/vbQNi
cremes has quit [Quit: cremes]
<travis-ci> crystal-lang/crystal#8a52f7b (master - Add Crystal::System::Dir (#5447)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/323977088
<DeBot> https://github.com/crystal-lang/crystal/pull/5447 (Add Crystal::System::Dir)
early` has quit [Quit: Leaving]
early has joined #crystal-lang
vivus has quit [Quit: Leaving]
hightower2 has joined #crystal-lang
woodruffw has quit [Ping timeout: 256 seconds]
faustinoaq has joined #crystal-lang
woodruffw has joined #crystal-lang
woodruffw has quit [Changing host]
woodruffw has joined #crystal-lang
illy_ has quit [Quit: Leaving]
Philpax has joined #crystal-lang
Philpax has quit [Ping timeout: 260 seconds]
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 272 seconds]
rohitpaulk has joined #crystal-lang
<livcd> just read ary's happy new year...things about the type system being broken and macros are a bit concerning
rohitpaulk has quit [Ping timeout: 248 seconds]
<FromGitter> <HCLarsen> The other day, someone showed me how to get a list of the methods available for an object, but I forgot. Does anyone here know how?
<FromGitter> <HCLarsen> Or better yet, is there a way to check if a Crystal object has one specific method?
rohitpaulk has joined #crystal-lang
<FromGitter> <mjago> responds_to?
rohitpaulk has quit [Ping timeout: 256 seconds]
rohitpaulk has joined #crystal-lang
jnyw has joined #crystal-lang
lachlan has joined #crystal-lang
lachlan has quit [Client Quit]
claudiuinberlin has joined #crystal-lang
<crystal-gh> [crystal] lachlan opened pull request #5507: Fix UUID.new URN string exception typos (master...fix_uuid_new_urn_string_exception_typo) https://git.io/vbp0z
lachlan has joined #crystal-lang
<FromGitter> <marin117> hi everyone
<FromGitter> <marin117> method to_json is not working with Time::Span object
<FromGitter> <marin117> anyone knows why?
<FromGitter> <marin117> error : no overload matches 'Time::Span#to_json' with type JSON::Builder
lop has joined #crystal-lang
lachlan has quit [Remote host closed the connection]
lachlan has joined #crystal-lang
lop has quit [Quit: Leaving]
<FromGitter> <straight-shoota> @marin117 There is just no converter defined for `Time::Span`
<FromGitter> <marin117> like I thought :(
<FromGitter> <marin117> what would be the best practice
<FromGitter> <marin117> convert to string
<FromGitter> <marin117> or keep seconds in json and then explicitly convert it to time::span
<FromGitter> <straight-shoota> Depends... what do you need it for
<FromGitter> <marin117> sending to and from server
<FromGitter> <marin117> and write it in database on server
<FromGitter> <straight-shoota> What format does the server expect? Or do you control the protocol on both ends?
<FromGitter> <marin117> I control it
<FromGitter> <marin117> in my opinion i should send seconds to server, but receive string from it (cause it is two different data)
<FromGitter> <marin117> but I am a little bit unsure about that
<FromGitter> <straight-shoota> Then for the time being it would probably be the easiest workaround to convert the span to integer seconds
<FromGitter> <marin117> :)
<FromGitter> <marin117> thank you for your help :)
<FromGitter> <straight-shoota> you can use a converter for this in JSON.mapping
rohitpaulk has quit [Ping timeout: 248 seconds]
lachlan has quit [Remote host closed the connection]
<dragonkh> hi - I have a class ActiveUser what would the to_json method look like - in order for the containing object to call it and it produce json instead of - no overload matches ActiveUser#to_json with type JSON::Builder
<dragonkh> aha I added: JSON.mapping(groupId: String, channelId: String) and it worked
<FromGitter> <straight-shoota> yes, that's how it works
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 252 seconds]
hightower3 has joined #crystal-lang
rohitpaulk has joined #crystal-lang
hightower2 has quit [Ping timeout: 264 seconds]
rohitpaulk has quit [Ping timeout: 264 seconds]
<FromGitter> <asterite> livcd: I should probably clarify my email, when I say it's broken I mean that is has many bugs, but it's nothing that can't eventually be fixed (or rethought without introducing many breaking changes)
<RX14> yeah, I don't think the feel of the type system has to be changed
<RX14> just the edge cases
<RX14> similarly to making type restrictions cast their arguments properly
<RX14> IMHO that will solve compile times, but really probably won't affect many methods
<RX14> unfortunately, there's not enough people who are confident enough with the crystal compiler to perform what I assume would be a major change in casting to type restrictions
jnyw has quit [Quit: WeeChat 2.0.1]
<livcd> sadly :(
<FromGitter> <asterite> I tried once but did it quickly and it had a few bugs and got tired at the moment. I also found out that we'd need to change how `a.b = c`works. That should return c, not what the `b=
<FromGitter> <asterite> ` method returns... The method might return a more general type because of that casting
<FromGitter> <asterite> In fact Ruby does this, it ignores that method return type
<FromGitter> <asterite> I also tried to implement that quickly but it had bugs so I got tired. It's all a matter of effort and time
<RX14> @asterite yeah i've been trying to make all my assign methods return c, but I thought about proposing that the compiler ignored the return type but never got around to it
<FromGitter> <sdogruyol> @dragonkh I'll cut a release today 👍
<RX14> @asterite not knowing the compiler very well - isn't there just one place where assigns are converted to method calls? Couldn't you just insert an Expressions with the method call and then a var reference to the result of the rhs?
<RX14> conceptually to me it sounds simple and i'm not sure what bugs could be introduced
<RX14> of course the reality of the compiler is different
ashirase has quit [Ping timeout: 260 seconds]
ashirase has joined #crystal-lang
<FromGitter> <asterite> Yes, I guess we could do that as a first step. I'd like to try avoiding expanding stuff to more stuff because it means more things to type and compile, so slower compile times. But we could do it and have specs for it, later redoing it should be easier
<RX14> yeah
<RX14> don't let perfect be the enemy of good @asterite
<RX14> plus if all of this is pre-work to decrease the core *amount* of typing that the compiler has to do in the first place, it seems more than worth it to me
<FromGitter> <asterite> it's not about that. if you have a property `bar` that's Int32? and you do x = foo.bar = 1, then x ends up being Int32 right now. But if we introduce casting in type restrictions, it becomes Int32?, so it breaks code
<FromGitter> <asterite> maybe it's just a minor thing, but it can be annoying
<RX14> I think the current behaviour is incorrect
<RX14> and worth breaking
<RX14> x should be of type Int32
<RX14> it's what you'd guess by inspection
<RX14> if you didn't know how the compiler worked
rohitpaulk has joined #crystal-lang
<FromGitter> <asterite> Mmm... what do you mean? x is of type Int32 right now
<RX14> not if, for example:
<RX14> def bar=(x) : Nil; @bar = x; end
<RX14> the point is it's possible for the added foo.bar to affect the type of x
rohitpaulk has quit [Ping timeout: 240 seconds]
<RX14> and that's not good
<RX14> there's plenty of setters in the stdlib right now that don't return their RHS
<RX14> stuff like io.blocking = true
<RX14> and io.close_on_exec=
<RX14> and that's clearly wrong
<RX14> well at least those two did before I refactored them for Crystal::System
<RX14> I might have fixed it can't remember
<FromGitter> <asterite> ah, yes, I understand now
<RX14> so it's worth fixing, and making an issue about, regardless of how it affects casting in type restrictions
<RX14> because not all setters are macro setter
<crystal-gh> [crystal] RX14 closed pull request #5507: Fix UUID.new URN string exception typos (master...fix_uuid_new_urn_string_exception_typo) https://git.io/vbp0z
sz0 has joined #crystal-lang
<RX14> @asterite sorry to bug you but https://github.com/crystal-lang/crystal/pull/5448 and https://github.com/crystal-lang/crystal/pull/5484 should be a really really quick review
<FromGitter> <asterite> not at all, I was planning on reviewing all prs and check which ones are easy to approve
<RX14> "all PRs"
<RX14> good luck...
<RX14> the most concerning thing about windows to me is that there's definitely a codegen/abi bug present on windows only
<RX14> and i'm not feeling that that's going to be fun to figure out...
<FromGitter> <asterite> hahaha, well, at least the recent ones :)
<FromGitter> <asterite> i have a windows machine so once I have it set up to compile crystal I could try to help. By now I'm used to seeing random errors, segfaults, crashes, etc.
<RX14> @asterite well it's never going to be as weird as this: https://github.com/crystal-lang/crystal/issues/4127
<RX14> I should see if that still reproduces...
<RX14> well it's still broken: https://my.mixtape.moe/hfxqtu.png
<vegai> perhaps just close all PRs older than a year :P
<vegai> I suggest this same thing for issues in every place I work in
<vegai> people are never very happy with the idea for some reason...
<RX14> not issues
<RX14> and not a blanket close
<RX14> but PRs, yes
<RX14> after a year they're usually pretty stale
<vegai> yeah... issues tend to get a bit stale too
<Vexatos> look at date of last relevant comment I guess
<vegai> perhaps not in a project like Crystal so much, though
<vegai> but certainly in most company projects
<Vexatos> "relevant" as in not just "yea it happens to me too"
<RX14> vegai, a lot of the old issues are just todos
<RX14> features that we want... sone day
<FromGitter> <asterite> only in linux?
cremes has joined #crystal-lang
<RX14> @asterite i assume so
<FromGitter> <asterite> such segfaults usually mean some C types are incorrectly mapped so the stack gets overwritten and undefined behaviour happens
<FromGitter> <asterite> well, not always, but it's a possibility
<RX14> running the binary in gdb disables aslr and the bug is reduced
<FromGitter> <asterite> more if it only happens in linux, maybe some type is incorrectly specified in a lib (a struct, its size)
<RX14> perhaps
<RX14> in GDB you get
<RX14> type_declaration_processor.cr (JSON::ParseException)
<RX14> which makes no sense
<RX14> no backtrace
<RX14> but it's consistent
rohitpaulk has joined #crystal-lang
<vegai> RX14: yeah, that is one way I guess
<vegai> I'm not trying to impose my philophies or anything
<vegai> for me, lingering todo-lists are a burden
<RX14> well
<RX14> perhaps they are
<RX14> I don't see too many issues as a problem personally
<RX14> we just need better tagging
<RX14> whats a bug
<RX14> what's it's pririty
<RX14> our tag system is still woefully lacking
<RX14> 99% of bugs are either
<RX14> bug/stdlib or bug/compiler
<FromGitter> <asterite> oh, lines in the callstack are wrong
<FromGitter> <asterite> it has nothing to do with this snippet
<FromGitter> <asterite> they are generally broken
<FromGitter> <asterite> so I wouldn't search there
<RX14> @asterite hmm?
<RX14> it's spilling random memory over the screen
<RX14> it's more than just the callstack being wrong
rohitpaulk has quit [Ping timeout: 248 seconds]
<FromGitter> <asterite> I know, but I wouldn't rely on the location reported by gdb to trace the bug down
<RX14> if anything I could believe a DWARF parser bug
<FromGitter> <asterite> `from /usr/lib/crystal/indexable.cr:0:17 in 'at'` -> makes no sense
<RX14> @asterite yeah I wasn't relying on gdb
<RX14> yup
<RX14> I tried to get debug info specs into crystal
<RX14> but getting gdb working on circleci macos is just
<RX14> impossible
<RX14> getting gdb working on macos seems to be an insane pain already
<crystal-gh> [crystal] RX14 closed pull request #5484: Move win32 stubs into a separate file (master...feature/windows-stubs-declutter) https://git.io/vbNFn
<crystal-gh> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbpD8
<crystal-gh> crystal/master 78ccf91 Chris Hobbs: Remove c/winapi and rename some windows types (#5448)...
<crystal-gh> [crystal] RX14 closed pull request #5488: Rename skip() macro method to skip_file() in docs (release/0.24...patch-1) https://git.io/vbAZU
<travis-ci> crystal-lang/crystal#687d665 (master - Fix UUID.new URN string exception typos (#5507)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/324118076
<DeBot> https://github.com/crystal-lang/crystal/pull/5507 (Fix UUID.new URN string exception typos)
<FromGitter> <codenoid> hi, how to puts (puts inside each) in one lin
<FromGitter> <codenoid> one line (realtime change that line)
<crystal-gh> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbpyD
<crystal-gh> crystal/master 80f94f3 Julien Reichardt: Change from `bash` to `sh` (#5468)...
<RX14> @codenoid ??
<FromGitter> <codenoid> and i want puts a changed by puts b
<FromGitter> <codenoid> ```b # a will be b``` [https://gitter.im/crystal-lang/crystal?at=5a4b8f180163b02810a2f2e5]
<RX14> oh you're talking about terminal escapes now
<RX14> you want print "a\r" puts "b"
<RX14> the print "foo\r" will print "foo" and reset the cursor to the beginning of the line
<RX14> you can't do this with multi-line strings
rohitpaulk has joined #crystal-lang
<RX14> actually the easiest way is to always use print "\r#{message}" then when you want to stop modifying your previous line just use puts with no argument
<travis-ci> crystal-lang/crystal#78ccf91 (master - Remove c/winapi and rename some windows types (#5448)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/324126645
<DeBot> https://github.com/crystal-lang/crystal/pull/5448 (Remove c/winapi and rename some windows types)
rohitpaulk has quit [Ping timeout: 276 seconds]
<crystal-gh> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbpSS
<crystal-gh> crystal/master 3903b70 Hannes Käufler: Rename 'failed' to 'failures' in junit output. (#5463)...
<crystal-gh> [crystal] RX14 closed pull request #5229: Improved search feature for API docs (master...jm-docs-search) https://git.io/vF3lH
<crystal-gh> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbp94
<crystal-gh> crystal/master 68a7ce8 William Woodruff: INI: Rewrite parser to avoid regular expressions (#5442)...
<travis-ci> crystal-lang/crystal#d3fed8b (release/0.24 - Rename skip() macro method to skip_file() in docs (#5488)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/324127304
<DeBot> https://github.com/crystal-lang/crystal/pull/5488 (Rename skip() macro method to skip_file() in docs)
<RX14> oh boy today is going to be a mergefest
<crystal-gh> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbp9K
<crystal-gh> crystal/master 56b8edd William Woodruff: Bool: Add `to_unsafe` (#5465)...
<travis-ci> crystal-lang/crystal#80f94f3 (master - Change from `bash` to `sh` (#5468)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/324133693
<DeBot> https://github.com/crystal-lang/crystal/pull/5468 (Change from `bash` to `sh`)
rohitpaulk has joined #crystal-lang
<FromGitter> <sdogruyol> it already is :P
snsei has joined #crystal-lang
<crystal-gh> [crystal] RX14 closed pull request #5423: Makefile: allow passing through LDFLAGS to final link phase (master...master) https://git.io/vby1B
<travis-ci> crystal-lang/crystal#56b8edd (master - Bool: Add `to_unsafe` (#5465)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/324140592
rohitpaulk has quit [Ping timeout: 240 seconds]
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 264 seconds]
faustinoaq has quit [Ping timeout: 248 seconds]
faustinoaq has joined #crystal-lang
<FromGitter> <bararchy> Once a year on Christmas eve @asterite comes to play, he merges all the PRs then and makes it quite a day, the Travis elf works extra hard to check then all the code, and every one is having fun PRing across the world :)
<FromGitter> <codenoid> thank @RX14, only for one line, (y)
<FromGitter> <drujensen> Good morning. Did we remove `to_json()` from NamedTuple? Looks like you have to provide an Json::Builder now?
<travis-ci> crystal-lang/crystal#3661e2d (master - Makefile: allow passing through LDFLAGS to final link phase (#5423)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/324154200
<DeBot> https://github.com/crystal-lang/crystal/pull/5423 (Makefile: allow passing through LDFLAGS to final link phase)
<RX14> uhh
<RX14> no
<RX14> to_json should work
<RX14> >> require "json"; {a: "foo"}.to_json
<DeBot> RX14: # => "{\"a\":\"foo\"}" - https://carc.in/#/r/3bto
<RX14> works
<RX14> >> Crystal::VERSION
<DeBot> RX14: # => "0.24.1" - https://carc.in/#/r/3btp
<FromGitter> <drujensen> damn, sorry. thanks. forgot to require json
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
<RX14> >> {a: "foo"}.to_json
<DeBot> RX14: Rerun with --error-trace to show a complete error trace. - https://carc.in/#/r/3btr
snsei has quit [Remote host closed the connection]
<FromGitter> <drujensen> yeah, that’s the error i got
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
<FromGitter> <drujensen> when I checked the docs, `to_json` requires `JSON::Builder`
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
<RX14> its a tad confusing
<RX14> because you override to_json(JSON::Builder)
snsei has quit [Remote host closed the connection]
<RX14> and the to_json with no arguments is defined on Object
faustinoaq has quit [Read error: Connection reset by peer]
<FromGitter> <drujensen> thanks guys
<crystal-gh> [crystal] RX14 closed pull request #5406: Change 'doc' to 'docs', fixes #5405 (master...fix/doc-to-docs) https://git.io/vbP3T
<crystal-gh> [crystal] RX14 closed pull request #5399: Add guard clause to Deque#rotate! (master...deque-rotate-patch) https://git.io/vb6Ka
<crystal-gh> [crystal] RX14 closed pull request #5376: Zip: avoid runtime modifications of deflate signature (master...freeze-deflate-signature) https://git.io/vbEXw
<crystal-gh> [crystal] RX14 closed pull request #5368: Add specs for Crystal::Doc::Highlighter (master...fix/doc-highlighter-spec) https://git.io/vb4XY
<crystal-gh> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbppu
<crystal-gh> crystal/master 0e48aac Alexander Batalov: Fix missing GC.add_finalizer throughout the stdlib (#5367)
<crystal-gh> [crystal] RX14 closed pull request #5360: Tempfile: Add `Tempfile.tempname` (master...tempfile-tempname) https://git.io/vbCrd
<07IACANR0> [crystal] RX14 closed pull request #5355: Avoid empty author and email (master...patch-1) https://git.io/vbnGX
<DeBot> https://github.com/crystal-lang/crystal/pull/5355 (Avoid empty author and email)
<7GHABPQSV> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbppy
<7GHABPQSV> crystal/master 2bff41d Faustino Aguilar: Avoid empty author and email (#5355)
<DeBot> https://github.com/crystal-lang/crystal/pull/5355 (Avoid empty author and email)
<crystal-gh> [crystal] RX14 closed pull request #5352: Change properties key in YAML.mapping to reduce chance of conflict (master...pr-5180-followup) https://git.io/vbZHW
<crystal-gh> [crystal] RX14 closed pull request #5298: Add INI.build (master...ini-build) https://git.io/vFXEy
rohitpaulk has joined #crystal-lang
<FromGitter> <drujensen> @bararchy nice poem! :-)
<crystal-gh> [crystal] RX14 closed pull request #5234: Format: indent multiline call chaining with 4 spaces (master...fix/crystal-format/multiline-call-4-space-indent) https://git.io/vFGkv
<crystal-gh> [crystal] RX14 closed pull request #5233: Change URI#to_s to handle default ports for more schemes than http/https (master...uri_default_port) https://git.io/vFsug
<crystal-gh> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbpjA
<crystal-gh> crystal/master a3f2ecc myfreeweb: Support FreeBSD 12 (64-bit inodes) (#5199)
<travis-ci> crystal-lang/crystal#82b4115 (master - Change 'doc' to 'docs', fixes #5405 (#5406)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/324172016
<DeBot> https://github.com/crystal-lang/crystal/issues/5405 (Some parts of crystal still use "doc" instead of "docs") | https://github.com/crystal-lang/crystal/pull/5406 (Change 'doc' to 'docs', fixes #5405)
<travis-ci> crystal-lang/crystal#87126b3 (master - Add `@size <= 1` guard clause to Deque#rotate! (#5399)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/324173225
<DeBot> https://github.com/crystal-lang/crystal/pull/5399 (Add guard clause to Deque#rotate!)
<crystal-gh> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbhe9
<crystal-gh> crystal/master be9d9c7 larubujo: Optimize String#to_json (#5456)
<FromGitter> <bararchy> LOL hahah
snsei has joined #crystal-lang
<dragonkh> can I make a generic method? like def something[T](value : T) - and then call it like: something(String)("hello"). ?? I can't get it to work
<jhass> dragonkh: yes, def something(value : T) forall T is the current syntax iirc
<jhass> no specifying it explicitly on the callside though
snsei has quit [Ping timeout: 246 seconds]
<dragonkh> ah great thanks - working :)
<jhass> dragonkh: note that unless you use T in the method body it's quite equivalent to just specifying no type at all
<dragonkh> ok I will try that too
<FromGitter> <Yive> Is there a documentation page on dealing with error raising? Like as in how to make the program not crash when say Cossack raises the timeout error
<RX14> begin/rescue/end
<FromGitter> <Yive> thank you
<dragonkh> how can I do a result.is_a?(klass) where klass is passed in - e.g. klass = String
<dragonkh> it says: expecting token 'CONST', not 'klass'
<RX14> dragonkh, you need to use generics for that
<dragonkh> ah never mind
<dragonkh> found it
<dragonkh> I was passing T - I just needed to use it
<RX14> and use the constant you defined using forall CONST
<RX14> yup
<dragonkh> if I have a variable in scope e.g. get "/main" do |context| go(context) end. <--- is there a way to have the go method implicitly use the context without having to pass it in?
nicbet has joined #crystal-lang
<RX14> no
<dragonkh> ok thanks
<travis-ci> crystal-lang/crystal#be9d9c7 (master - Optimize String#to_json (#5456)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/324184002
<DeBot> https://github.com/crystal-lang/crystal/pull/5456 (Optimize String#to_json)
faustinoaq has joined #crystal-lang
<dragonkh> hmm the generic thing isn't working
<dragonkh> def onParams(context, klass : T, &block) forall T <--- when I result = klass.run it says typeof(result) AddGroup | String | Nil
<jokke> was anyone at the 34C3?
<dragonkh> but when I do if result.is_a?(T) - it thinks T is Class - not AddGroup
<RX14> hmm?
<dragonkh> onParams(context, AddGroup)
<jokke> or: has anyone thought of going to the 35C3?
<RX14> can you show me your code dragonkh
<RX14> dragonkh, yeah let me explain
<jokke> there should be a crystal assembly :)
<RX14> when you pass in say String
<RX14> type type of String is Class
<RX14> so when you say klass : T
<RX14> and pass in String
<RX14> T is class
<RX14> because typeof(String) is Class
<RX14> you want to use klass : T.class
<RX14> and it'll all be fixed
<dragonkh> ok
<dragonkh> yay - it works :) thanks
<RX14> np
flaviodesousa has joined #crystal-lang
flaviodesousa has quit [Ping timeout: 252 seconds]
faustinoaq has quit [Ping timeout: 260 seconds]
faustinoaq has joined #crystal-lang
<crystal-gh> [crystal] RX14 pushed 1 new commit to master: https://git.io/vbht1
<crystal-gh> crystal/master 6399e09 Chris Hobbs: Clarify that unions are allowed in JSON.mapping (#5483)...
rohitpaulk has quit [Ping timeout: 252 seconds]
nicbet has quit [Quit: Leaving]
faustinoaq has quit [Quit: IRC client terminated!]
<travis-ci> crystal-lang/crystal#6399e09 (master - Clarify that unions are allowed in JSON.mapping (#5483)): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/324212542
<DeBot> https://github.com/crystal-lang/crystal/pull/5483 (Clarify that unions are allowed in JSON.mapping)
Poeticode has quit [Ping timeout: 264 seconds]
Poeticode has joined #crystal-lang
Poeticode has quit [Quit: Feels good to be a gangster.]
Poeticode has joined #crystal-lang
Poeticode has quit [Changing host]
Poeticode has joined #crystal-lang
vivus has joined #crystal-lang
alex1 has joined #crystal-lang
alex1 has quit [Client Quit]
alex``` has joined #crystal-lang
alex``` has quit [Client Quit]
alex``` has joined #crystal-lang
ua_ has quit [Ping timeout: 264 seconds]
ua_ has joined #crystal-lang
ua_ has quit [Client Quit]
ua has joined #crystal-lang
cremes has quit [Quit: cremes]
alex``` has quit [Quit: WeeChat 1.9]
<FromGitter> <bew> What is the `release/0.24` branch for?
<RX14> 0.24.2
<RX14> which is basically 0.24.1 + bugfixes only
<FromGitter> <bew> ah ok, and master would be 0.25 when it's time?
<RX14> supposedly
<FromGitter> <straight-shoota> Wow this year is taking off like a blast
<FromGitter> <straight-shoota> I've been out all day and it's over two pages of updated GitHub issues
<FromGitter> <sdogruyol> thanks for @asterite 👍
<FromGitter> <straight-shoota> And ~30 closed (probably merged) PRs since last year
jnyw has joined #crystal-lang
faustinoaq has joined #crystal-lang
<FromGitter> <straight-shoota> Really amazing what effect an additional active core member has ;(
<FromGitter> <straight-shoota> ;)
<FromGitter> <bararchy> Now we just need @waj back for a week to finish Multi-Thread support, and RX14 will finish Windows and we can announce 1.0 ;)
<RX14> ...
<FromGitter> <bararchy> Hahahha
<FromGitter> <straight-shoota> I mean actively working on the issue queue, reviewing contributions etc.
<oprypin> i think that at this point issue queue is less important than thread support
<FromGitter> <bararchy> If it issue queue or nothing I'll take the first :/
<FromGitter> <bararchy> Sadly
<oprypin> yeah and it's happening
<oprypin> which is nice
<RX14> @straight-shoota yeah it's amazing what doubling the number of active more members does...
<oprypin> :p
<FromGitter> <bararchy> Just add oprypin to core devs
<FromGitter> <bararchy> :)
<oprypin> i mean... i should up my activity before that happens
<FromGitter> <bararchy> Ah... You're more active then other core devs
<FromGitter> <bararchy> So...
<RX14> oprypin knows the language, he hasn't read every comment on every issue in the last 2 years though
<FromGitter> <bararchy> Oh, and who did? @asterite ?
<RX14> asterite's been doing it for longer than 2 years
<FromGitter> <straight-shoota> is that a formal requirement to become core member?
<RX14> no
<RX14> the point being: you really need to be active on the issue tracker to be a core developer
<oprypin> there are no formal requirements, only informal ones if i understand
<FromGitter> <straight-shoota> yeah, I was joking
<RX14> that means watching the repository and responding to issues
<FromGitter> <bararchy> If so then I guess @sdogruyol should be Core member
<oprypin> but he's not doing that stuff either
<RX14> not sure @sdogruyol reads all the issues...
<FromGitter> <bararchy> I think he does, he sure is sending me links to interesting ones all the time :)
<RX14> active != lurking though :P
<FromGitter> <bararchy> What about Jhass?
<FromGitter> <bararchy> Or yasbaden (can't spell he's nick)
<oprypin> they are both in
<FromGitter> <bararchy> Oh
<FromGitter> <bararchy> So 4 core devs ?
<FromGitter> <straight-shoota> @bararchy you get a personal stream of recommended issues? :D
<dragonkh> I've just started building my next epic project in Crystal - great work on the language so far :) hopefully by the time I release it - people will change from asking me - what is Crystal, why are you building it in Crystal - to cool project dude - nice choice of language ;)
<oprypin> bararchy, and basically whole manas lol
<FromGitter> <straight-shoota> more
<FromGitter> <straight-shoota> https://github.com/orgs/crystal-lang/people
<oprypin> straight-shoota, and that's not all
<FromGitter> <straight-shoota> plus incognito core members like asterite
<FromGitter> <straight-shoota> not everyone really active on github though
<FromGitter> <bararchy> @straight-shoota all via the @sdogruyol express news
<FromGitter> <straight-shoota> nice ;)
<RX14> that is all oprypin
<FromGitter> <bararchy> What about Papierkorb ?
<FromGitter> <bararchy> He is pretty active + helps in issues
<oprypin> i dunno, probably not quite there either, but close
<RX14> iirc Papierkorb doesn't follow either
<RX14> @straight-shoota you're more active than Papierkorb on the issue tracker
<RX14> I don't think we need more people though
<RX14> we need more people to be active
<FromGitter> <straight-shoota> yeah I've been following quite actively for the last months
<FromGitter> <bararchy> @straight-shoota yeha, I see you review and answer all the time
<FromGitter> <straight-shoota> I try to do my best. And it helps to follow many issues so you get a broad view of whats going on and connect things
<FromGitter> <straight-shoota> takes a lot of time but it's mostly fun and I learn a lot
<FromGitter> <straight-shoota> still don't know much about the inner workings of the language and only basics of C stuff. So I wouldn't recommend myself as a core member.
<FromGitter> <bew> that's for sure! for myself I'm watching since... a long time, but I try to unsubscribe for issues/prs when I know I won't be of any help, or it's not interesting
<FromGitter> <bew> I think I would love to be a core member, but I also think I'm not ready now..
<FromGitter> <straight-shoota> yep
<FromGitter> <bew> the "that's for sure" was for "I learn a lot" (just to clarify) ^^
<FromGitter> <straight-shoota> I figured as much :P
<oprypin> i don't even know what i'm doing anymore. not handling my free time well, that's for sure.
jokke has quit [Ping timeout: 264 seconds]
jokke has joined #crystal-lang
<RX14> it's hard to find someone i'd consider as a good core team member
<oprypin> :|
<RX14> you need to find someone who is opinionated, passionate, has a large breadth of general practical programming knowledge, has time to follow the issue tracker, and is well-versed in the internals of crystal's stdlib and the compiler
<oprypin> just need a lot of free time and i got it
<RX14> yeah pretty much oprypin
<RX14> i probably shouldn't say but thats my assesment of you and Papierkorb for the core team: if only you had the free time and will to follow and be much more active on the issue tracker
greengriminal has joined #crystal-lang
<FromGitter> <paulcsmith> I think community skills are important as well. Making people feel welcome and encouraging new opinions and contributions
<FromGitter> <paulcsmith> The core team has a huge effect on the community as a whole
<FromGitter> <straight-shoota> it does
<FromGitter> <straight-shoota> but also non-core members can get pretty far in helping with community management
alex``` has joined #crystal-lang
<RX14> that's the part i'm worst about @paulcsmith
<RX14> i'll admit
rohitpaulk has joined #crystal-lang
<RX14> @straight-shoota updated my feature/windows-spec to be rebased on master
claudiuinberlin has quit [Quit: Textual IRC Client: www.textualapp.com]
<FromGitter> <straight-shoota> great
<FromGitter> <paulcsmith> @straight-shoota Definitely. You and others outside the core team have been really helpful here an in the Crystal repo :D
<RX14> @straight-shoota i cheated, git reset --hard onto your rebased Crystal::Ssytem::Time PR and then cherry-pciked the relevant commits
<FromGitter> <straight-shoota> RX14, great! I didn't get it to run completely yet because of some lib issues. But I'll give it another go
<RX14> I can help you with compiling the libs
<RX14> what issues?
<FromGitter> <straight-shoota> whatever gets the job done...
<FromGitter> <straight-shoota> can't tell right now
<FromGitter> <paulcsmith> @RX14 I'm grateful for your work and I've noticed you are doing an awesome job at teaching others and helping with newcomers. So don't be hard on yourself :) I've definitely noticed a lot of improvement
<FromGitter> <straight-shoota> linker complained about something not matching up
<RX14> with pcre?
<RX14> yeah that happens if you follow TXE's instructions exactly
<RX14> the cmake invocation is incorrect
<RX14> you need -D before the options
<RX14> then it gives you the correct pcre.lib
cremes has joined #crystal-lang
<FromGitter> <straight-shoota> no wasn't that
cremes has quit [Quit: cremes]
<FromGitter> <straight-shoota> Not sure if this is what I encountered last time, but now I get this: @RX14 ⏎ ⏎ ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=5a4c16ac84fb74b9402e52d9]
<FromGitter> <straight-shoota> ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=5a4c16bab48e8c3566924dbb]
<RX14> you need x86_64-pc-windows-msvc
<RX14> not x86_64-windows-msvc
<RX14> what's your cross-cimpile command exactly?
<FromGitter> <straight-shoota> oh, I had a typo there. Amazing that you immediately catched it
<FromGitter> <straight-shoota> Now it's this: ⏎ ⏎ ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=5a4c1756edd223081105f1fe]
alex``` is now known as alexherbo2
<RX14> because i went through that journey of discovery myself lol
<FromGitter> <straight-shoota> hehe
<RX14> i have no idea why it emits ELF without pc
<RX14> it's stupid
<FromGitter> <straight-shoota> Now the linker gives this error: ⏎ `gc.lib(misc.obj) : error LNK2019: unresolved external symbol __imp_MessageBoxA referenced in function GC_win32_MessageBoxA ⏎ spec_test.exe : fatal error LNK1120: 1 unresolved externals`
<FromGitter> <bew> what is `pc` in this case?
<RX14> @bew the vendor
<RX14> machine-vendor-os
<RX14> where os can be two fields
<FromGitter> <bew> and what is `vendor`?
<RX14> so x86_64-linux-gnu is actually: machine: x86_64, vendor: unknown/undefined, os: linux-gnu
<RX14> @bew well pc is just personal computer
<FromGitter> <bew> ah x) what else could it be?
<RX14> the target triple stuff needs to actually go
<RX14> we need to abstract over it
<RX14> we need to have a simple list of "os", "architecture" and additional flags such as fpu on arm
<RX14> but actually maybe thats a bad idea
<RX14> the whole thing is a mess either way
<FromGitter> <bew> I've found my answers here https://clang.llvm.org/docs/CrossCompilation.html#target-triple (for other who might wonder)
<RX14> it's weird
<RX14> so x86_64-unknown-windows-msvc != x86_64-pc-windows-msvc
<RX14> what
<RX14> no
<RX14> x86_64-unknown-windows-msvc == x86_64-pc-windows-msvc
<RX14> it's just that x86_64-windows-msvc != x86_64-unknown-windows-msvc
<RX14> which is weird to me
<RX14> even just x86_64--windows-msvc emits PE
<RX14> one character