<< 13-11-2013 >>

00:00:23OrionPKzahary i'll see if i can reproduce it in something small
00:05:54OrionPKzahary my bad, I think I had a field of the same name as the iterator
00:06:54fowlOrionPK, clean out your desk and go home, you're fired
00:07:27fowlOrionPK, hey i am back home now so i have more time to work on stuff, lets collaborate on something
00:11:34OrionPK:P
00:11:53OrionPKfowl I'm working on an IRC thingy right now
00:12:59OrionPKbasically it's a web server/web app that connects to IRC
00:13:11OrionPKand acts as a proxy for a single client to connect to IRC
00:13:37OrionPKand remains connected when the connected client leaves
00:15:37OrionPKI wanted to make it all in nimrod, but it's been a challenge because of a lot of bugs in sockets.nim and gaps in the standard library
00:22:20*EXetoC quit (Quit: WeeChat 0.4.2)
00:24:26NimBotAraq/Nimrod master 32c6adf Zahary Karadjov [+0 ±6 -0]: support for multiple test variables and var qualifiers in user-defined type classes
00:25:14zaharygood night everyone
00:25:22OrionPKnight
00:37:35MFlamerzahary: did you just submit something for userdefined type classes?
00:39:01MFlamerexciting!
00:46:27*BitPuffin quit (Ping timeout: 246 seconds)
00:55:14filwitlol, i just responded to someone on Phoronix about Nimrod
00:55:32filwitthen i noticed the guy above me did the same thing
00:55:47filwit(respond to someone, and recommend Nimrod).
01:14:12*mflamer_ joined #nimrod
01:22:35*VarriountPhone joined #nimrod
01:23:06VarriountPhoneMeep
01:25:45*VarriountPhone quit (Read error: Connection reset by peer)
01:37:44*Boscop quit (Read error: Connection reset by peer)
01:38:06*Boscop joined #nimrod
01:38:07*Boscop quit (Changing host)
01:38:07*Boscop joined #nimrod
01:45:01VarriountIt's a shame that the typedesc method is a bit more verbose.
01:50:21*Trixar_za quit (Ping timeout: 240 seconds)
01:50:26*Arcanum_za joined #nimrod
01:53:15*noam_ quit (Ping timeout: 241 seconds)
01:53:38*noam_ joined #nimrod
01:58:23OrionPKVarriount i agre it's not ideal
01:58:33OrionPKespecially for library authoring
02:01:13*mflamer_ quit (Ping timeout: 272 seconds)
02:05:42*brson joined #nimrod
02:06:13*brson quit (Client Quit)
02:08:04*mflamer_ joined #nimrod
02:16:21*brson joined #nimrod
02:42:35*xenagi joined #nimrod
02:57:54filwitjust use 'type Foo'
03:00:21fowlOrionPK, Varriount, if you have to specify the type for a generic, then it can't be inferred by the arguments (ie marshal.to) so its probably better to make it a param anyways
03:01:12fowlgood example of this is system.new(T: typedesc): ref T
03:03:00*freezerburnv joined #nimrod
03:06:32*xenagi quit (Quit: Leaving)
03:06:39*freezerburnv quit (Client Quit)
03:07:10*xenagi joined #nimrod
03:25:16*freezerburnv joined #nimrod
03:26:05*brson quit (Ping timeout: 272 seconds)
03:35:02*mflamer_ quit (Ping timeout: 240 seconds)
03:36:14*xenagi quit (Ping timeout: 240 seconds)
03:36:41*xenagi joined #nimrod
03:36:46*mflamer_ joined #nimrod
03:36:48*freezerburnv quit (Quit: freezerburnv)
03:41:52*xenagi|2 joined #nimrod
03:42:30*xenagi|2 quit (Client Quit)
03:44:05*xenagi quit (Ping timeout: 248 seconds)
03:45:59*webskipper quit (Ping timeout: 272 seconds)
03:48:34*xenagi joined #nimrod
04:31:41*filwit quit (Quit: Leaving)
04:38:02*ics quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
04:40:06*ics joined #nimrod
04:41:32*brson joined #nimrod
05:15:55*brson quit (Ping timeout: 272 seconds)
05:21:59*mflamer_ quit (Ping timeout: 272 seconds)
05:26:38*mflamer_ joined #nimrod
05:54:45*xenagi quit (Quit: Leaving)
05:58:25*OrionPK quit (Read error: Connection reset by peer)
06:36:50mflamer_When you create a newIntNode() why dosent it have a type assigned to it? I'm hacking in the compiler in the semantic phase, so after idents get looked up and turned into symbols.
06:41:50*DAddYE joined #nimrod
06:58:53*mflamer_ quit (Ping timeout: 272 seconds)
07:35:53*brson joined #nimrod
07:53:27*brson quit (Ping timeout: 246 seconds)
08:17:49*brson joined #nimrod
08:46:51*dymk quit (Ping timeout: 245 seconds)
08:48:43*DAddYE quit (Ping timeout: 272 seconds)
08:54:34*DAddYE joined #nimrod
08:57:54*dymk joined #nimrod
08:59:07*noam_ quit (Read error: Connection reset by peer)
08:59:33*noam_ joined #nimrod
09:30:31*delian2 quit (Quit: Terminated!)
09:38:28*CarpNet joined #nimrod
09:57:11*BitPuffin joined #nimrod
09:57:27BitPuffing'day guvenös!
09:58:25BitPuffinsomebody should really update the babel package in the aur
09:58:28BitPuffinit's really stupid
09:59:09BitPuffinfirst of all nimrod-git should provide nimrod so that it doesn't install 0.9.2 when installing babel. Second of all, if there is no nimrod installed then it should probably default to the one in community and not compile it from source
09:59:12BitPuffin</rant>
10:14:54*DAddYE quit (Remote host closed the connection)
10:31:57*XAMPP quit (Read error: Connection reset by peer)
10:33:02*ics quit (Ping timeout: 240 seconds)
10:36:39*ics joined #nimrod
11:18:20*MFlamer quit (Read error: Connection reset by peer)
11:26:18*DAddYE joined #nimrod
11:30:35*DAddYE quit (Ping timeout: 252 seconds)
11:43:28*brson quit (Ping timeout: 245 seconds)
11:47:22*Arcanum_za is now known as Trixar_za
12:10:06*webskipper joined #nimrod
12:33:58*EXetoC joined #nimrod
12:36:07*brson joined #nimrod
12:54:30*Ricky_Ricardo joined #nimrod
13:25:55*freezerburnv joined #nimrod
13:31:50*Endy joined #nimrod
13:49:36*Jackneill joined #nimrod
13:51:19*[1]Endy joined #nimrod
13:53:53*Endy quit (Ping timeout: 245 seconds)
13:53:53*[1]Endy is now known as Endy
13:55:17*EXetoC quit (Ping timeout: 248 seconds)
14:11:47*[1]Endy joined #nimrod
14:14:17*Endy quit (Ping timeout: 240 seconds)
14:14:17*[1]Endy is now known as Endy
14:16:13*brson quit (Ping timeout: 246 seconds)
14:19:09*DAddYE joined #nimrod
14:19:27*phil4mac joined #nimrod
14:19:44*Jackneill quit (Ping timeout: 244 seconds)
14:20:08*Jackneill joined #nimrod
14:21:35phil4macHi all, can anyone point me in the right direction for how to use a serial port with nimrod? E.g. open /dev/ttyS1 and read/write it etc...?
14:21:53*Ricky_Ricardo quit (Quit: laptop[lid].close)
14:23:20*DAddYE quit (Ping timeout: 245 seconds)
14:23:53*Ricky_Ricardo joined #nimrod
14:29:22BitPuffinphil4mac: the same way you'd do it in C would definitely work. No idea if there is anything like that in the stdlib but have a look
14:31:47phil4macBitPuffin: that was my theory too, but I can find a way to make it do an open(...) call in C such as "fd = open("/dev/ttyS0", O_RDWR | O_NOCTTY | O_NDELAY);"...
14:32:20*[1]Endy joined #nimrod
14:32:24*Ricky_Ricardo quit (Quit: laptop[lid].close)
14:35:17*Endy quit (Ping timeout: 248 seconds)
14:35:18*[1]Endy is now known as Endy
14:40:05BitPuffinphil4mac: seems like a regular file open to me
14:42:29phil4macBitPuffin: I gave it a try and it seems to work, I notice under the surface the nimrod has turned it into an fopen(...) call rather than open(...), not sure what the implications of that are yet...
14:44:12BitPuffinphil4mac: well it's probably a wrapper around the C function
14:44:22BitPuffinor oh
14:44:24BitPuffinI dunno
14:44:28BitPuffin:P
14:44:39phil4macI shall investigate...
14:46:58BitPuffingo for it!
14:47:25*OrionPK joined #nimrod
14:47:40*Ricky_Ricardo joined #nimrod
14:52:52*[1]Endy joined #nimrod
14:55:25*Endy quit (Ping timeout: 245 seconds)
14:55:25*[1]Endy is now known as Endy
14:57:32*mflamer joined #nimrod
14:58:24mflamerGood morning
15:01:35mflamerI wonder if Araq or zahary would concider it worthwhile to have a quick gotomeeting session sometime to give an overview of the compiler structure, stages, Q&A for a few of us who are interested in working on it. Might be more efficent use of time as opposed to answering questions over and over
15:03:18mflamerIt might be a nice intermediate step towards our Nimrod "conference" in the middle of the atlantic
15:13:19*[1]Endy joined #nimrod
15:16:05*Endy quit (Ping timeout: 252 seconds)
15:16:06*[1]Endy is now known as Endy
15:20:06dom96mflamer: That's a cool idea.
15:20:12*DAddYE joined #nimrod
15:24:21*DAddYE quit (Ping timeout: 248 seconds)
15:25:53mflamerI have a goto account and will be happy to set it up anytime
15:26:51dom96Never used goto, what is it exactly?
15:28:09mflameronline meetings and webinars http://www.gotomeeting.com/online/
15:29:18dom96cool
15:33:54*[1]Endy joined #nimrod
15:36:57*mflamer quit (Ping timeout: 272 seconds)
15:37:33*Endy quit (Ping timeout: 246 seconds)
15:37:33*[1]Endy is now known as Endy
15:43:33*alex_nx joined #nimrod
15:52:53*[1]Endy joined #nimrod
15:55:12*[2]Endy joined #nimrod
15:56:51*Endy quit (Ping timeout: 272 seconds)
15:56:52*[2]Endy is now known as Endy
15:57:05dom96hi alex_nx
15:57:50alex_nxdom96, hello
15:57:55*[1]Endy quit (Ping timeout: 245 seconds)
15:59:10BitPuffinyeah that idea mflamer had would be nice
15:59:18BitPuffinbut why not make a G+ hangout instead?
16:00:26dom96Would be nice if we could record it for later reference.
16:00:33dom96or perhaps we could all take notes.
16:00:56BitPuffindom96: G+ has recording support
16:09:24BitPuffindom96: it can even publish to youtube
16:10:40mkb5
16:11:10BitPuffinmake sense mkb
16:12:23mkbs/^/\/w /
16:12:42*mkb is sure that just confused you more
16:14:58BitPuffinmore or less
16:15:15mkbirssi crap
16:16:04*[1]Endy joined #nimrod
16:16:05*Ricky_Ricardo quit (Quit: laptop[lid].close)
16:17:54*MFlamer joined #nimrod
16:19:40*Endy quit (Ping timeout: 272 seconds)
16:19:49*Endy joined #nimrod
16:21:18*DAddYE joined #nimrod
16:23:24*[1]Endy quit (Ping timeout: 246 seconds)
16:25:26*DAddYE quit (Ping timeout: 240 seconds)
16:25:43NimBotnimrod-code/babel master 37b8c46 Grzegorz Adam Hankiewicz [+0 ±1 -0]: Adds support for optional web field.... 2 more lines
16:25:43NimBotnimrod-code/babel master 292bb41 Grzegorz Adam Hankiewicz [+0 ±1 -0]: Rewrites requiredField on top of optionalField.
16:25:43NimBotnimrod-code/babel master 0a35930 Grzegorz Adam Hankiewicz [+0 ±1 -0]: Puts TPackage json initialization into single proc.
16:25:43NimBotnimrod-code/babel master 911957d Dominik Picheta [+0 ±1 -0]: Merge pull request #13 from gradha/pr_adds_web_field... 2 more lines
16:28:56*[1]Endy joined #nimrod
16:29:21NimBotnimrod-code/babel master 09a898f Grzegorz Adam Hankiewicz [+0 ±1 -0]: Implements path command for packages.... 2 more lines
16:29:21NimBotnimrod-code/babel master 27167e3 Dominik Picheta [+0 ±1 -0]: Merge pull request #14 from gradha/pr_path_command... 2 more lines
16:31:50*Endy quit (Ping timeout: 240 seconds)
16:31:51*[1]Endy is now known as Endy
16:38:34*[1]Endy joined #nimrod
16:42:15*Endy quit (Ping timeout: 252 seconds)
16:42:16*[1]Endy is now known as Endy
16:44:57*[1]Endy joined #nimrod
16:47:00*[2]Endy joined #nimrod
16:48:09*Endy quit (Ping timeout: 272 seconds)
16:48:10*[2]Endy is now known as Endy
16:50:05*BitPuffin quit (Ping timeout: 244 seconds)
16:50:14*[1]Endy quit (Ping timeout: 246 seconds)
16:51:00MFlamerzahary: If I create an nkInt node in the semantic phase, it dosent seem to have a type by default. I can easily create a new tyInt but it seems wrong to create a new type.
16:52:13MFlamerlike I should be using a symbol instead. Does that make any sense?
16:56:28*phil4mac left #nimrod (#nimrod)
17:03:38*[1]Endy joined #nimrod
17:04:40*[1]Endy quit (Client Quit)
17:07:13*Endy quit (Ping timeout: 245 seconds)
17:28:05MFlamerso quiet today
17:39:10*gradha joined #nimrod
17:44:57gradhadom96: were you able to test babel path on windows?
17:45:15dom96no, not yet.
17:47:22*DAddYE joined #nimrod
17:47:44*DAddYE quit (Remote host closed the connection)
17:48:32*DAddYE joined #nimrod
18:06:26*MFlamer quit (Remote host closed the connection)
18:15:04*BitPuffin joined #nimrod
18:30:11*CarpNet quit (Quit: Leaving)
18:30:40*alex_nx quit (Quit: Leaving)
18:32:37*alex_nx joined #nimrod
18:46:08BitPuffinahoy
18:46:11BitPuffindom96: what are you up to?
18:46:34BitPuffinmkb: switch to weechat :P
18:47:51OrionPKdom96 is there an HTML encode function in jester somewhere?
18:48:03OrionPKor in the std lib
18:48:08BitPuffinOrionPK: html encode?
18:48:11BitPuffinOrionPK: you mean htmlgen?
18:48:25gradhagenerate html from macros? htmlgen module?
18:48:28OrionPKno, I mean convert <tag> to &lt;tag&gt;
18:48:45gradhathere's an escape proc in the cgi module
18:48:46BitPuffinsomething like that would be nice indeed
18:48:58BitPuffinis there a markdown parser for nimrod?
18:49:14gradhaBitPuffin: sssshh, or you will awaken Araq
18:49:26OrionPKgradha i see url encoding
18:49:29OrionPKnot html encoding
18:49:36gradhaOrionPK: doesn't XMLencode do what you want?
18:49:43OrionPKhmm..
18:49:44BitPuffingradha: hmm?
18:49:55OrionPKyeah that might do it
18:49:57OrionPKweird thing to call it though
18:50:21gradhaBitPuffin: something about markdown being crap and a subset of rest
18:50:40BitPuffingradha: :P but it's simple
18:50:51gradhaand it's overflowed
18:50:54gradhaand githubbed
18:51:08BitPuffingradha: is there a rest parser for nimrod?
18:51:16dom96BitPuffin: Trying to muster up the determination to finish the homework I have due for tomorrow.
18:51:54BitPuffingradha: and tumbled
18:52:03BitPuffindom96: go do it!
18:52:08BitPuffindom96: did that help?
18:52:26dom96BitPuffin: Not really :P
18:53:21BitPuffindom96: go do it! or else!!
18:53:26gradhaBitPuffin: like "nimrod rst2html" command?
18:54:20BitPuffingradha: I mean like a library that I could use for my website
18:55:20gradhagradha: hmm... not sure what you mean, isn't "a library" what ipsumgenera does for generation of the static blog?
18:55:33OrionPKdom96 did you write the IRC module?
18:55:41dom96yes
18:56:00OrionPKdo you mind if I add a TTime stamp to TEvent
18:56:03Araqdocutils is already a library
18:56:03OrionPKor whatever it's called
18:56:06BitPuffingradha: something where I can do like var html = rstToHtml(rstText)
18:56:21Araqthat's already supported, BitPuffin
18:56:40BitPuffinAraq: but where?
18:56:43Araqlib/packages/docutils
18:57:07OrionPKTIRCEvent
18:57:26dom96BitPuffin: look at how ipsumgenera does it
18:58:13dom96OrionPK: nope, go ahead. What do you need it for?
18:58:29OrionPKlogging, manually to maintain a history of TIRCEvents
18:58:34OrionPKmainly* not manually
18:58:47gradhaBitPuffin: another example would be nimforum, generating the html for the web pages or the rss feed
18:59:09dom96OrionPK: Why not create some tuple type with that info?
18:59:28OrionPKdom96 I could do that, but I figured it was such a basic thing it ought to be kept with the event
19:00:36BitPuffinI'll take a look
19:00:59BitPuffingradha, Araq, dom96 etc: is there a talk you guys recommend on concurrency/multithreading?
19:03:56gradhaI'm sold on the Apple way of doing things, which unfortunately requires very expensive hardware and programming languages nobody uses
19:05:03dom96OrionPK: I'd rather keep IRC as basic as possible. NimBot uses a little tuple for this: https://github.com/nimrod-code/nimbuild/blob/master/irclogrender.nim#L7
19:05:22OrionPKit's an integer
19:05:28OrionPKwith a unix timestamp
19:05:32OrionPKcant get much more basic than that
19:06:45*eigenlicht joined #nimrod
19:07:16OrionPKthe module is already importing times even
19:07:55OrionPKall we''re doing by not having the timestamp is complicating what callers have to do IMO
19:09:14AraqI have no idea what you're talking about, but I think I agree with OrionPK ...
19:10:20AraqBitPuffin: dunno, many people like Rich's Hickey talks about concurrency. of course I don't ;-)
19:10:54OrionPKAraq its re: having a timestamp in TIRCEvent
19:12:09Araqhaving a timestamp is always a good idea
19:15:04gradhadom96: I'm thoroughly dissappointed in reddit
19:15:37gradhadom96: after learning about /r/programming and more importantly /r/kpop, I stumbled upon /r/kpopfap
19:15:52gradhadom96: but there is no /r/programmingfap. Where's your rule 34 now?
19:16:06dom96OrionPK: Fine, add it then.
19:16:15dom96gradha: You just need to create it then :P
19:16:43OrionPKk
19:17:34*gradha pictures fakes of Jobs, Gates and Torvalds in hardcore action
19:17:44*gradha runs to the bathroom to vomit
19:17:49gradhadom96: yeah, nevermind
19:17:50BitPuffinAraq: what's bad about it? :P
19:19:00Araqit's yet another "shared mutable state doesn't work" which is wrong
19:19:14OrionPKim not a fan of people on /r/programming.. they're very negative
19:19:29OrionPKeverybody is not only critical of everything, but cruelly so
19:19:54OrionPKsomeone pours their heart and soul into working on a toy language, they submit it and people rip it to shreds
19:20:13eigenlicht/r/coding is a bit better on that matter
19:20:56*gradha wonders if /r/programming should be renamed to /r/stressrelief
19:21:29gradhaOrionPK: I think it's more a problem of programmers not looking at happy things, like kpop
19:21:48OrionPKdom96 https://github.com/Araq/Nimrod/pull/670
19:22:23BitPuffinAraq: a-ha!
19:22:25eigenlichtAraq: long time ago I saw that talk from RH, but wasnt he more like "shared mutable state is overly complex"?
19:22:33BitPuffinAraq: well shared mutable state can be problematic
19:22:40BitPuffinAraq: but it can work.
19:22:43eigenlichtrather than saying flat out: "it doesn't work"
19:22:45OrionPKgradha we should start an /r/niceprogrammers
19:22:47OrionPK:P
19:23:03OrionPKor maybe a /r/politeprogramming
19:23:10eigenlichtexactly, BitPuffin - and iirc that's what RH wanted to say
19:23:13eigenlichtbut I may be wrong
19:24:01eigenlicht(but as a clojure programmer, I'm a it biased)
19:24:19gradhaOrionPK: right, I even try to implement polite software https://github.com/gradha/babel/tree/pr_polite_install
19:24:28OrionPK:)
19:25:10BitPuffineigenlicht: :P
19:25:58BitPuffinAraq: I'd really like to know what you think is the right way to do it. I assume that is competitive concurrency but I don't know what that means :P
19:26:50Araqhi alex_nx welcome
19:27:56AraqBitPuffin: you'll see
19:28:09BitPuffinAraq: But I am impatient :'(
19:30:01gradhaBitPuffin: I recommend watching https://www.youtube.com/watch?v=2IzR_ClTE8Y while you wait for Araq's masterpiece
19:32:25BitPuffingradha: wtf >.<
19:33:03gradhaBitPuffin: sorry, it was a test to see if we admitted you to /r/politeprogramming, you didn't pass I'm afraid
19:34:41BitPuffingradha: then I'll start my own /r/politeprogrammingbutbetter
19:34:53eigenlichtwith black jack an hookers!
19:35:26gradhaBitPuffin: surely you jest! I'll be drinking tea on the other channel
19:37:41BitPuffingradha: and I'll be drinking espresso
19:37:50BitPuffinexpresso?
19:39:50OrionPKyou had it right th 1st time
19:40:02BitPuffinmaybe
19:41:09BitPuffinAraq: nimrod channels can be passed around as arguments right?
19:43:56BitPuffinwhy the fuck does html5 feel like it needs to tell me that something is full screen. I CAN SEE THAT
19:54:53AraqBitPuffin: no, use a PChannel for that
20:04:52BitPuffinAraq: TChannel PChmammel. No but I only said channel
20:05:15BitPuffinAraq: I was kind of thinking about for a moment whether I needed to make a ref TChannel type (PChannel)
20:05:47BitPuffinAraq: By the way do you think it was the right decision for linagl to avoid sideffects?
20:06:21Araqsure
20:07:25freezerburnvBitPuffin: You might consider having ways to mutate stuff in place, but have the default behavior be no side effects
20:07:58BitPuffinfreezerburnv: there is nothing stopping you from doing vec[1] = 4
20:08:23freezerburnvBitPuffin: I meant more for something such as someVec *= someVec
20:08:30freezerburnvEr, someVec *= someOtherVec
20:08:35BitPuffinfreezerburnv: that's not supported
20:09:06BitPuffinbut I guess I could make a template
20:09:17freezerburnvBitPuffin: That's what I figured based on what you said, but it might be nice to have for tight loops
20:09:45BitPuffintemplate `*=`(a, b: TVector): expr = a = a * b
20:10:20BitPuffinthat way it kind of remains pure
20:10:51BitPuffinrather than doing proc `*=`(var a, b: TVector) = a = a * b
20:11:26Araqwhat?
20:11:27freezerburnvBitPuffin: Does the template allocate memory? (not sure how your * works, but I'm guessing it does in some form. dunno if Nimrod optimizes that somehow though)
20:11:52Araqyou've some weird notions about what a side effect is
20:12:18Araqproc `*=` ... is perfectly fine
20:12:42BitPuffinAraq: well no, I know that a side effect would be for example if the proc modified some global variable
20:13:10BitPuffinfreezerburnv: no the template just rewrites the a *= b code to a = a * b at compile time
20:13:52BitPuffinAraq: I said pure. And a proc that modifies an incoming parameter is not pure
20:14:10freezerburnvBitPuffin: I know, I was more concerned about how the "a = a * b" would work at runtime. I don't know how that would affect a tight loop doing lots of vector math. Maybe it runs just fine
20:15:00BitPuffinfreezerburnv: I'm sure that's low hanging fruit for an optimizer
20:15:55BitPuffinnow we are kind of disregarding the fact that there isn't a `*` for TVector
20:16:10BitPuffinonly *. and *+
20:16:30BitPuffinbut I'm considering making * component wise multiplication. Because that is sort of useful in image processing
20:21:28*ics quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
20:31:25*freezerburnv quit (Quit: freezerburnv)
20:41:27*ics joined #nimrod
20:42:19BitPuffinAraq: did you write this? https://github.com/Araq/Nimrod/wiki/Coding-Guidelines
20:43:50gradhaaccording to the history dom96 did
20:45:04BitPuffinalso is a != b defines as not a == b? because when it comes to the types that are compared bit by bit, isn't it more efficient to determine that they are not equal wen comparing bits, so maybe you'll see at the first bit that they are not equal. Whereas with equality you need to check all bits to know that they are equal
20:45:18BitPuffinso doesn't that mean that it's better to define a == b as not a != b
20:45:30BitPuffinbut maybe that's not how cpu's work I guess
20:45:40BitPuffingradha: that guy, I have heard of him
20:45:42fowl!= is a template
20:45:44fowlnot(a == b)
20:46:20BitPuffinfowl: yeah exactly
20:46:46BitPuffinfowl: my point is couldn't you determine faster that something is not equal than that something is equal
20:47:04gradhado we have any architecture today where checking single bits and breaking out is faster than the whole thing?
20:47:23fowlshrug
20:47:36BitPuffinI dunno, that's why I said maybe that's not how CPUs work
20:48:41BitPuffinmaybe I focus too much on details :P
20:49:00BitPuffinsame thing when trying to learn the compiler. I focus on understanding every single line ._.
20:49:01gradhamaybe what you say could be useful for complex object comparisons, but I guess you could overload the template with a specific proc
20:49:22gradhaor simply specify in your API to use a faster "notEqual" proc
20:49:41BitPuffinI think overloading would be better in that case
20:49:47BitPuffinwhy even give the option to do it wrong :D
20:49:55gradhaI think profiling your code would be better in any case
20:50:10BitPuffinsure
20:50:41BitPuffintoo bad I'm not sure what the output showed in http://nimrod-code.org/estp.html is trying to tell me
20:50:47BitPuffinin the example
20:52:45*Jackneill quit (Remote host closed the connection)
20:54:59*CarpNet joined #nimrod
21:00:43Araqer ... for == you can stop as soon as you encounter a position where the bits are not equal
21:01:07Araqsame as for !=
21:01:11*filwit joined #nimrod
21:01:32*MFlamer joined #nimrod
21:08:23MFlamerAraq: : If I create an nkInt node in the semantic phase, it dosent seem to have a type by default. I can easily create a new tyInt but it seems like I shouldnt need to do this
21:08:49MFlamerI asked zahary eariler, but hes busy or away
21:09:06Araqcheck what other parts of the compiler do
21:11:58zaharyand yes, the AST structures are a bit tautological sometimes - other parts of the compiler depend on the proper typ appearing in the typ field so you need to assign it
21:11:58VarriountAraq, you're back!
21:12:59BitPuffinAraq: hmm did not think of that xD
21:13:06VarriountAny particular reason parameters without any type specified default to the expr type, instead of throwing an error? I mean, what is the reasoning behind it?
21:13:34BitPuffinhey zahary!
21:13:44BitPuffinI was gonna ask you something but I can't seem to recall what it was
21:13:48Araqthe reasoning is zahary likes it this way. more seriously it's consistent with the rest of the language
21:13:58filwiti like it too
21:14:03Araqtemplate foo(a, b) = a + b
21:14:13Araqer, bad example
21:14:26Araqtemplate foo(a, b): expr = a + b
21:14:40VarriountYeah, but then you get wierd bugs or errors if you forget a type.
21:14:42Araq'expr' makes most sense as the default type
21:14:58Araqwell bugs are bugs ...
21:15:01BitPuffinweird*
21:16:00BitPuffinAraq: was this the talk you ment by hickey? http://youtu.be/dGVqrGmwOAw
21:16:03filwitVarriount: it's no less bug-prone than having expr really
21:16:33Varriountfilwit, new users might be confused by this -> proc foo(x:proc(int):int, arg:int): bool =
21:16:37MFlamerI guess what I'm wondering is shouldnt there be 1 nkInt type for the entire AST, as oposed to many?
21:17:01MFlamerOr, maybe that dosent matter
21:18:13zaharynkInt really means int literal appearing in the source code
21:18:35zaharymost integers in the program are nkSymbol (i.e. things like variables, constants, etc)
21:18:41MFlamersorry tyInt
21:19:23zaharywell, the multitude of tyInt types is preserved for the C backend
21:20:34MFlamerso, every symbol of skVar that is an int will have an individual type of tyInt?
21:20:48Araqno, they are cached
21:20:50zaharyah, I see what you mean
21:21:18zaharyit was getSystemType(tyInt) or something like that
21:21:27MFlamerin the symbol table, correct?
21:22:23zaharysee magicsys.nim/getSysType
21:22:48Araqin fact you need to be careful. there is tyInt and then tyInt + n(X) which is "int literal(X)"
21:23:26MFlamerok
21:23:34Araqwhich is different so that mybyte + 1 produces a byte
21:26:49fowlhttp://clickingbad.nullism.com/
21:29:02reactormonkno more cookies?
21:30:09VarriountAraq, just in case you don't know, there's about 7 pull requests open for contributions to the nimrod repo.
21:30:46AraqVarriount: there are 4 people who can merge iirc
21:32:25VarriountYes, but do they know *they* know they can merge? I assumed that such things had to go through you.
21:33:42Araqwell indeed I should do some reviews
21:35:31*freezerburnv joined #nimrod
21:36:47*XAMPP-8 joined #nimrod
21:47:02Varriountzahary, could you explain this? -> https://gist.github.com/Varriount/7456992
21:47:45*XAMPP joined #nimrod
21:49:46*MFlamer quit (Remote host closed the connection)
21:51:00fowlVarriount, you arent calling typedescproc correctly
21:51:14fowltesttypedescproc(seq[int], int, iter)
21:51:49filwitAraq (or anyone): how can i iterator over a typedesc field pairs? The iterators in the system lib and typeinfo don't work with typedesc.
21:52:15filwitcan i iterate** over..
21:53:36zaharyfilwit, the typetrais module should gain magics for obtaining field names and types from a type, but in order to actually iterate over the values of an object, well, you need an object
21:54:44*XAMPP-8 quit (Ping timeout: 246 seconds)
21:55:00filwitzahary: hmm.. Can i make a macro which does it somehow ? (takes in a symbol name, finds type data from it, etc.. ) ?
21:55:32zaharycan you clarify a bit more your goal
21:55:55filwiti'm trying to answer stingers question in the forums
21:57:39zaharyhe really needs a richer typetraits API
21:57:42filwitbasically, i need a macro which transforms this: "type Vec3 = tuple[x, y, z:float32]" into this: "type TAosoa = object; x:array[4, float32], ..."
21:58:15fowlzahary, compiletime typetraits
21:58:26filwithmm.. it's interesting, I wasn't expecting to run up to a wall with Nimrod on this.
21:58:55filwitso currently there's no way to run over a field pairs of an typedesc in any way?
21:59:07zaharythere is another topic in the forum where I explain how easy it is to add new typetraits to the compiler :)
21:59:22zaharymaybe you could try to do that
21:59:41filwitzahary: okay, so it's a "needs to be done" thing, i see
21:59:54filwitzahary: i will look into it later then
22:00:22zaharyhttps://github.com/Araq/Nimrod/blob/master/lib/pure/typetraits.nim that's all we have so far
22:00:29fowlfilwit, var x: t ; var any = x.toAny ; fieldpairs over y
22:00:33filwitzahary: as it will probably effect my life down the road, i'll fix it when it become relevant.
22:00:39fowlfilwit, where x is a typedesc param
22:00:54zaharyhttp://forum.nimrod-code.org/t/218
22:01:00zaharythe forum post I mentioned
22:03:03filwitsorry, one sec folks, on the phone
22:06:44*ics quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
22:07:56*ics joined #nimrod
22:11:21filwitfowl: not sure i follow entirely. where did 'y' come from in your example?
22:11:30filwitzahary: thanks, i'll take a look.
22:11:46fowlfilwit, sry i meant "any" instead of y
22:11:59filwitfowl: ah, okay.
22:12:02gradhaI can't write '\n' but I can write char(0x0A), is there a more readable form for a newline char constant?
22:12:02fowlfilwit, i used y in the test i did in aporia
22:12:26filwitfowl: 'x' is a typedesc?
22:12:43fowlfilwit, yes
22:12:44filwitguess i'll just try it real quick
22:12:59fowlfilwit, no, T is a typedesc, var x: t allocates a t
22:13:19fowlproc foo(t: typedesc) = var x: t; var any = x.toAny
22:13:29filwitokay. i see
22:14:00filwiti tried that earlier, but didn't know about 'toAny'
22:14:31fowlfilwit, its in typeinfo
22:14:43filwitthanks
22:14:55zaharyinteresting method fowl, but I guess the typeinfo module won't work in compile-time context
22:15:23fowloh hrm i only suggested that because i thought fieldpairs was in typeinfo
22:16:21filwitit's okay, i found it, but having a access nil error now
22:16:31gradhais there any clear restriction on what can be done at runtime vs compile time?
22:16:35filwitwhat happens if type T is a ref object?
22:16:53filwitoh, wait.. that probably doesn't matter..
22:19:18filwityeah, 'toAny()' causes the compiler to SIGSEGV
22:19:31filwitif used from a macro
22:19:51fowlfilwit, i dont think typeinfo works at compiletime
22:20:26filwityeah, just wanted to make sure
22:24:30zaharygradha, the typeinfo module makes some assumptions about the memory layout of the objects that are only true in the C backend after the code is compiled
22:25:11zaharyother than that, C imported procs are not usable unless the compiled was compiled with FFI enabled
22:25:50zahary* unless the compiler (nimrod) was compiled*
22:27:14zaharyVarriount: there are number of strange things in your gist. what are you trying to do exactly? is var x = testGenProc[seq[int],int] supposed to become a "factory" for creating iterators?
22:27:18filwitzahary: have you already started a typetraits lib?
22:27:38zaharyyep, I posted an answer for you
22:27:43gradhaso I can't use db_sqlite at compile time, but if I reimplemented sqlite in nimrod I could? Doesn't that mean you can't use disk IO since that maps to fopen?
22:27:50filwitah right, i closed that link on accident
22:28:40gradhaI guess I could use slurp/gorge, since they were meant for static compilation
22:29:32zaharygradha, yes, but you are better of with enabling FFI (which is going to become the default at some point)
22:30:11zaharythere is also staticExec, which will allow you to have your sqlite code as an external program that the compiler will just call
22:32:14gradhaI like the idea of implementing a dsl in a separate file, then slurp it with a macro at compile time
22:32:55zaharyhow is your DSL going to look like?
22:32:59gradhaso you could have "insert_table_a.sql" files, and their extension is recognized by the editor, but still are slurped and parsed at compiletime
22:33:24gradhazahary: at some point I'll do argument parsing, no definite DSL there, there are several options
22:33:50zaharyif you have some ideas already, I'll be interested to see a gist
22:34:19gradhaSteve Donovan already implemented something nice at https://gist.github.com/stevedonovan/6409900 but it is all runtime
22:34:33gradhathat's some nimrod implementation of lapp, which seems to be a lua dsl
22:34:53freezerburnvI'm getting a compiler error, can someone tell me what it means?
22:34:54freezerburnvhello.nim(14, 7) Info: instantiation from here
22:34:54freezerburnvdebug.nim(18, 7) Error: expression 'debug' has no type (or is ambiguous)
22:35:00freezerburnvCode which causes it is here: https://gist.github.com/Freezerburn/7457726
22:35:11gradhazahary: I'll also be taking ideas from https://github.com/docopt/docopt if valuable
22:35:40gradhaone thing I dislike from all these dsl is that they leave no room for i18n
22:35:41zaharyfreezerburnv: for nimrod debug (lowercase) and DEBUG (uppercase) are the same
22:36:07zaharyso I guess your error results from having the module name and the constant inside it with the same name
22:36:25freezerburnvAaah
22:36:50gradharecently an issue was rejected like that too
22:36:52freezerburnvIs there complete case-insensitivity for all vars? Or just consts? Or what?
22:37:29fowlfreezerburnv, all identifiers
22:37:35zaharygradha: but these are for command-line options, weren't you talking about SQL bindings?
22:37:36fowlvars, const, functions, modules
22:38:08freezerburnvfowl: That's an interesting choice to have in a language. Any idea why?
22:38:11gradhazahary: I want to implement sqlite parsing at least, no ideas for ORM yet
22:38:35gradhaAraq tends to say that sql compile time parsing is possible, so I want to do it
22:39:05fowlfreezerburnv, because you may not like camelCase so you can use camel_case
22:39:11gradhaand looking from sqlite website, they have these fancy bnf-whatever-you-compiler-gods-call-it
22:39:16zaharywell, we already have a pure nimrod parser I think - this one should work at compile time
22:39:27fowlfreezerburnv, also _'s can be added
22:39:33gradhazahary: where? I was looking but didn't find it, at least in the sqlite related code
22:39:42fowlfreezerburnv, so not only case-insensitive, its style-insensitive
22:39:49freezerburnvfowl: So basically, case and _'s are ignored? Interesting
22:40:07gradhafreezerburnv: but for 1.0 release some of these may change, so beware
22:41:40zaharylib/pure/parsesql - I have only seen the name tho, I'm not sure what SQL dialect is targeted
22:42:26gradhalooks pretty scary
22:44:24gradhaindeed, what is parsesql doing there all alone instead of being integrated with the other modules?
22:45:32zaharydunno, it's quite old
22:46:26*gradha wonders if Araq has negative skills in marketing
22:51:04gradhais there a compiler switch which "preprocesses" a source file expanding all macros/templates just to see the output=
22:51:08gradhaarr?
22:51:11Araqno
22:51:26Araqand yeah, I suck at marketing, you should know that by now
22:51:42Araqand parsesql works at compile time in theory ;-)
22:52:21Araqthough I guess I should ensure it works in practice since I'm working on the new compile time engine anyway
22:53:22gradhaaren't you doing too much stuff without commiting to master? or did you decide master is "stable"
22:58:59gradhaso I have this fancy macro I've written but nimrod says "cannot evaluate" and leaves it at that
22:59:40gradhathe code inside the macro compiles as a proc, so at least it has valid syntax
23:00:29gradhamaybe I'm using something not available at compile time? https://gist.github.com/gradha/7458065
23:01:26*CarpNet quit (Quit: Leaving)
23:01:37gradhaah, so the problem is the map line
23:03:49gradhaok, map works, the proc works, but lambdas don't
23:06:49BitPuffinAraq: maybe we need a mascot :p
23:07:07gradhaBitPuffin: bold move for volunteering!
23:07:15filwitlol
23:07:22BitPuffingradha: you mean I have to make one? ;_;
23:07:28BitPuffinI'll draw a penis
23:07:42gradhanah, pythonistas will claim prior art
23:07:56BitPuffinand I shall call it the tower of babel
23:08:16filwithaha
23:08:32filwitgenius
23:10:05AraqBitPuffin: we have a mascot
23:10:11*freezerburnv quit (Quit: freezerburnv)
23:10:28filwitoh yeah... did i see that a long time ago
23:10:38filwitit's in the repo or something
23:10:41gradhadon't tell me, a pink unicorn?
23:10:48filwitlol
23:11:17BitPuffinAraq: is it a golden crown? Because that's not really a mascot
23:12:29filwitBitPuffing, i think there's actually a mascot in the repo somewhere.. i forget, but kinda remember seeing it before
23:12:49BitPuffinfilwit: who is this BitPuffing you speak of
23:13:01filwitlol
23:13:14Araqwell the mascot is filwit's crown now
23:13:15OrionPKi like that name better
23:13:24OrionPKmascots are typically not inanimate
23:13:29filwit^
23:13:37filwitthe crown is more of a "logo"
23:13:39OrionPKthe crown is a logo
23:13:40OrionPKeyah
23:13:52BitPuffinOrionPK: Is Puffing even a thing. Puffin is a kind of bird/penguin thing
23:14:04filwitone is the playful things you put on mugs and shit, the other is your advertisement face
23:14:04OrionPKpuffing is a thing
23:14:11OrionPKas in huffing and puffing
23:15:24filwitnot that nimrod really needs a mascot though guys.. it's not like anyone's having t-shirts made or anything right now.
23:15:29BitPuffinOrionPK: lol
23:15:43BitPuffinwell I want a nimrod t-shirt god damn it
23:15:46Araqalright well we have a logo and hell freezes over before we get that golang bunny
23:15:59BitPuffinthat's kind of what made me thing of it HAHA
23:16:01filwithahaha
23:17:21BitPuffinmaybe we should have something that eats bunnies or something
23:17:32OrionPKI agree, mascots are silly
23:17:52gradhaI like BitPuffin's babel mascot
23:17:56dom96Do other languages have mascots?
23:18:03OrionPKgo has a gopher thing
23:18:05dom96(except go)
23:18:13filwitbabel has a mascot?
23:18:26BitPuffinOrionPK: But look at all the big languages. Java has that guy guy, python has a snake probable, go has gopher
23:18:32BitPuffinC has unix (lol)
23:18:46filwitidk, D doesn't have a mascot
23:18:48BitPuffinperl has that bird thing
23:18:52filwiteither does C#
23:18:52BitPuffinbut D isn't big
23:18:59filwit^ see bove
23:19:01filwitabove*
23:19:05dom96yeah, we're not big either :P
23:19:08BitPuffinno
23:19:12BitPuffinand we and D do not have mascots
23:19:15BitPuffinit all makes sense
23:19:15filwitJava has a mascot?
23:19:18BitPuffinyes
23:19:19BitPuffinfilwit: that guy
23:19:22BitPuffinwtf is his name
23:19:26BitPuffinthe black and white thing
23:19:31BitPuffinwith a ball as a nose
23:19:36filwitahh, right
23:19:38BitPuffinDuke
23:19:39filwitthat jester dude
23:19:46filwitright
23:19:56BitPuffinDuke nukem
23:20:23BitPuffinthanks gradha btw :P
23:20:37BitPuffinI knew you'd be on board
23:20:41filwitscrew mascots though. I'm just going to make a obama "hope" style pic of Araq's strangloop pic and start posting it everywhere
23:21:05BitPuffinHAHAHA
23:21:08BitPuffinthat would be nice
23:21:10filwitthe images wont have captions, they'll just like to the nimrod site
23:21:34BitPuffinI vote that Araq becomes our new mascot
23:21:46filwitlol
23:23:29BitPuffinhe does have a pretty friendly face
23:24:31*MFlamer joined #nimrod
23:24:55BitPuffinfilwit: I expect hope pictures by tomorrow morning
23:25:01BitPuffinwe need to make Araq famous!
23:25:10filwitlol
23:25:43BitPuffinhmm, but maybe we shouldn't look like some kind of cult either
23:25:46BitPuffinthat wouldn't be good
23:25:52filwitnah, i wont embarrass him that much, haha
23:27:32Araqgood. thanks
23:29:10BitPuffinspeaking of strange loop. Araq we really want the recordings of the talk :( any chance you can shoot them an email? or can we send an email demanding it somewhere?
23:31:23dom96I for one would love Araq's face on a t-shirt with the caption "I <3 the Nimrod BDFL" :P
23:31:46BitPuffindom96: BDFL?
23:31:51BitPuffinah
23:31:56BitPuffinbenevouarc h 4lyf
23:31:58gradhablunt dictator for life
23:32:01filwitBelovid Dictartor for life
23:32:11filwitgradha's is better
23:32:22dom96Bra Developer For Life.
23:32:32BitPuffinyeah that would be awesome
23:32:37filwito.O
23:32:39BitPuffinI would buy 20
23:32:43BitPuffinthousand
23:32:54BitPuffintoothpicks
23:32:59BitPuffinto whoever put that together
23:33:32fowl<epitron> golang binaries are so big... i made a hello world. it's 1.3 megs.
23:33:50reactormonknot bad
23:33:51BitPuffinfowl: how big is nimrod's?
23:33:59filwitfowl: same with D
23:34:26fowlBitPuffin, 156k
23:34:31BitPuffinare you sure that's the same with D? I mean you can import std.io: writeln or whatever
23:34:35gradhadon't worry, with ouroboros you can embed an mp4 into your binary, so your size won't be smaller than that from those lesser languages
23:34:46BitPuffinwhereas in nirmod you get system.nim
23:34:52gradhabecause size matters
23:35:02BitPuffinanyways
23:35:05BitPuffintime to sleep
23:35:11fowlBitPuffin, the trick is deadCodeElim
23:35:11gradhagood night
23:35:11BitPuffinfilwit, remember, change
23:35:15BitPuffinfowl: yup
23:35:18filwitBitPuffin: problem is usually 'writeln' depends one another module that imports a bunch of stuff
23:35:21BitPuffinfowl: but doesn't D have those too?
23:35:26fowlidk
23:35:27BitPuffinthose dead codes
23:35:30BitPuffinthat are eliminated
23:35:33BitPuffinby the terminator
23:35:36fowlD to me is an abbreviation for dick
23:35:37MFlamergoodnight Bitpuffin
23:35:49BitPuffinsee you guys
23:35:58filwitbye!
23:36:07BitPuffinyou guys are gonna have to get up earlier. It's so lonely during the day at my internship in this irc
23:36:10BitPuffinbai!
23:36:14filwitfowl, lol
23:40:33*BitPuffin quit (Ping timeout: 246 seconds)
23:42:19MFlamerin ast.nim I see "nkDerefExpr, # a^" is `^ ` an operatorI dont know about?
23:43:46fowlMFlamer, its old
23:43:53fowlderef is now ptr[]
23:44:30*EXetoC joined #nimrod
23:44:57MFlamerthanks
23:45:31*freezerburnv joined #nimrod
23:50:34gradhaGood night
23:50:49*gradha quit (Quit: bbl, need to watch https://www.youtube.com/watch?v=2IzR_ClTE8Y again)
23:51:16Araqsame here, good night
23:51:29filwitlater guys
23:51:58MFlameris there a way to render the entire AST or a piece of it?
23:52:18MFlamerI use debug alot, but would like to see more at once
23:52:31filwitdumpTree: <nimcode> ... OR pnode.treeRepr
23:52:41fowlfrom a macro repr(node) will show it in nimrod codes
23:53:00MFlamerthat'll show more than one node?
23:53:05filwittreeRepr(node) will
23:53:11MFlamerok, cool
23:53:36AraqMFlamer: renderTree(ast)
23:53:53MFlamersweet
23:54:07MFlamergoodnight guys
23:54:13filwitnight!
23:55:01MFlamerThink about my web meeting idea Araq
23:56:22Araqwell don't we do that already?
23:57:00filwitit's a lot easy to convey ideas in person
23:57:12MFlameryeah, but it seems like you could cover alot of ground on the compiler quickly
23:57:18filwitbut then, it's only productive if you have a team actually working on stuff a ton
23:57:33*freezerburnv quit (Quit: freezerburnv)
23:57:52MFlamerSure.
23:58:24MFlamerWhy ever meet in person then?
23:58:45filwitwell i agree meeting online would be good
23:59:04filwitbut i don't have time to put towards compilers bugs or anything right now
23:59:04MFlamerAnyway, only worth it if it saves Araq time
23:59:19filwitso it wouldn't really help if i showed up just to chat, lol
23:59:29MFlamermaybe after 1.0 or something
23:59:41filwitmaybe others are working on the compiler more, but it seems like it's mostly casual right now