<< 20-07-2013 >>

00:22:22dom96bye
00:32:14SmaehtinAny documentation on the v2 GC?
00:32:18SmaehtinOr notes? Anyting?
00:32:20SmaehtinAnything*
00:35:02DAddYEbye dom96
00:36:09DAddYEquick question any clue how to create a template that accepts: (int, varargs[string], proc (varargs[expr]))
00:36:10DAddYE?
00:50:50*DAddYE quit (Remote host closed the connection)
01:00:42*q66 quit (Quit: Leaving)
01:31:09*Smaehtin quit (Quit: Page closed)
01:54:15*DAddYE joined #nimrod
02:00:46*DAddYE quit (Ping timeout: 240 seconds)
02:57:34*DAddYE joined #nimrod
03:01:08*DAddYE quit (Read error: No route to host)
03:01:30*DAddYE joined #nimrod
07:25:23*xilo quit (Ping timeout: 264 seconds)
08:25:40*zahary__ joined #nimrod
08:30:26*zahary_ quit (*.net *.split)
08:46:02*Roin quit (*.net *.split)
08:54:07*mal``` joined #nimrod
08:54:48*mal`` quit (*.net *.split)
09:06:24*tumak quit (*.net *.split)
09:06:24*nihathrael quit (*.net *.split)
09:06:24*silven quit (*.net *.split)
09:06:26*Zor quit (*.net *.split)
09:06:26*JStoker quit (*.net *.split)
09:06:26*Araq quit (*.net *.split)
09:06:26*Araq_ quit (*.net *.split)
09:06:26*comex quit (*.net *.split)
09:06:29*Reisen quit (*.net *.split)
09:06:30*zahary1 quit (*.net *.split)
09:06:30*mal``` quit (*.net *.split)
09:06:30*zahary__ quit (*.net *.split)
09:06:31*reactormonk quit (*.net *.split)
09:07:54*mal``` joined #nimrod
09:07:54*zahary__ joined #nimrod
09:07:54*Araq_ joined #nimrod
09:07:54*nihathrael joined #nimrod
09:07:54*zahary1 joined #nimrod
09:07:54*silven joined #nimrod
09:07:54*comex joined #nimrod
09:07:54*Zor joined #nimrod
09:07:54*Araq joined #nimrod
09:07:54*JStoker joined #nimrod
09:07:54*Reisen joined #nimrod
09:07:54*tumak joined #nimrod
09:07:54*reactormonk joined #nimrod
09:08:53*fowl quit (*.net *.split)
09:08:53*Amrykid quit (*.net *.split)
09:08:54*dom96 quit (*.net *.split)
09:10:32*fowl joined #nimrod
09:10:32*Amrykid joined #nimrod
09:10:32*dom96 joined #nimrod
09:13:09DAddYEHi Nimguys
09:13:54DAddYEis https://github.com/DAddYE/node.nim/blob/master/tcp.nim#L49-L50 the "best" way to avoid evaluation ?
09:17:00*DAddYE_ joined #nimrod
09:19:29AraqI think so
09:21:39DAddYE_Araq: thanks!
09:22:08DAddYE_in order to support this: https://github.com/DAddYE/node.nim/blob/master/timers.nim#L107-L112
09:22:14DAddYE_aka varargs
09:22:34DAddYE_I think I need a macro, correct?
09:23:12Araqvarargs don't require a macro but you have a callback after them ... so yeah a macro can patch over it
09:23:41*EXetoC joined #nimrod
09:24:27DAddYE_Araq: yea was my feel
09:24:44*DAddYE quit (*.net *.split)
09:36:03AraqEXetoC: case objects are comparable to sum types
09:37:19EXetoCoh right
09:55:36*q66 joined #nimrod
10:04:57DAddYE_Araq: qq are regex case insensitive by default?
10:04:58DAddYE_:D
10:05:08DAddYE_not sure were I can put the /i
10:05:09Araqno
10:05:31Araqthere are some regex options for that I think
10:08:49Araqgah ... thanks to feature requests the semantic checking now depends on the documentation generator ...
10:09:55Araqwhy is it that feature requests always say "fuck you" to modularity?
10:10:08EXetoCwut
10:10:45Araqwell the semantic checker suggests symbol descriptions for idetools
10:10:59DAddYE_Araq: you need from xx import nil as the default
10:11:00DAddYE_:D
10:11:12Araqand symbol descriptions of course include their doc comments
10:12:01AraqDAddYE_: no because that screws up x.f(y) syntax
10:12:25DAddYE_:*
10:12:51DAddYE_real example?
10:13:01DAddYE_(not sure if I understood)
10:13:14Araqfrom tables import nil
10:13:20DAddYE_yes
10:13:27Araqvar t: Ttables.TTable[int, int]
10:13:42Araqt[23] = 34 # gah []= not imported
10:14:21DAddYE_need to check that
10:15:57Araqtables.`[]=`(t, 23, 34) # fu from import nil
10:16:11DAddYE_mmmmmmm
10:16:15DAddYE_but
10:16:20DAddYE_in this case
10:16:37DAddYE_you need a real import all, I mean use
10:16:54DAddYE_use tables
10:17:00DAddYE_btw
10:17:07DAddYE_your example makes sense
10:17:13DAddYE_the only thing
10:17:20DAddYE_that I can say is that
10:17:27DAddYE_since ` ` templates
10:17:31DAddYE_are cheap
10:17:38DAddYE_and special
10:17:48DAddYE_they should be aways imported
10:18:14Araqmyset.incl("abc")
10:18:19Araq# same
10:18:33Araqoperators are not at all special in nimrod
10:19:54DAddYE_I should check how clojure does that
10:20:01DAddYE_they have super awesome macros
10:20:17DAddYE_but not special operators
10:20:55Araqlast time I checked I couldn't find any spec about clojure's macro system
10:21:18Araqin fact, hardly any docs about them
10:21:43Araqexcept some propaganda about them
10:21:54DAddYE_look at example code
10:21:57DAddYE_or read the source
10:22:53DAddYE_ot but Araq https://github.com/clojure/core.async
10:22:56DAddYE_this is awesome
10:24:14DAddYE_and why I didn't saw that before!!!!!!!!
10:24:14DAddYE_https://github.com/clojure/tools.reader
10:25:30AraqIPushbackReader # what's that? a prefix?
10:26:06Araqwhat do you mean "increase the number of entities and prefixes always come back"?
10:26:23Araq;-)
10:26:32DAddYE_I java thing only for interfaces
10:26:45DAddYE_whose 2/3 guys that still use it
10:27:01Araqactually it comes from C#, not Java
10:27:14Araqdunno if Java took over that convention
10:27:31DAddYE_ha
10:27:35DAddYE_Araq: https://github.com/clojure/core.async/blob/master/examples/walkthrough.clj
10:28:21DAddYE_night
10:28:28DAddYE_3.30 am
10:28:30DAddYE_:d
10:28:37DAddYE_too much nim coding
10:28:38DAddYE_hahah
10:29:21DAddYE_Araq: remember about the seeeensible case problem
10:29:53DAddYE_10 hugs for an pragma and 8 for scoped vars
10:34:37Araqbbl
10:36:50*DAddYE_ quit (Remote host closed the connection)
10:37:17*DAddYE joined #nimrod
10:42:10*DAddYE quit (Ping timeout: 276 seconds)
10:51:46*Roin joined #nimrod
10:54:47dom96'morning
10:59:58EXetoC'lo
11:00:33dom96h'
11:31:00EXetoCsup
11:31:48dom96nm
11:33:11EXetoCokok
11:34:06dom96what about you?
11:35:37EXetoCwriting Nimrod code ofc
11:38:01*DAddYE joined #nimrod
11:39:54dom96awesome
11:40:34dom96!repos
11:40:34NimBotAnnounced repos: Araq/Nimrod, nimrod-code/nimbuild, nimrod-code/aporia, nimrod-code/nimforum, nimrod-code/babel, nimrod-code/packages, dom96/jester
11:40:41dom96!addrepo nimrod-code csources
11:40:41NimBotDone.
11:43:19dom96grr, why is github's test hook failing
11:46:58EXetoCdoes anyone think that implicit conversion of each individual tuple field should be allowed?
11:49:25dom96IIRC Araq said there was a reason as to why that is not allowed.
11:51:26EXetoCfair enough. sometimes explicit is better than implicit
12:17:06EXetoCit just feels a little redundant when the fields are ranges, that's all
12:17:33dom96oh, that's a bug: https://github.com/Araq/Nimrod/issues/500
12:18:31EXetoCyeah? ok
13:28:24dom96ok, this new 'field not initialized: x' is a bit irritating
13:29:55dom96Araq: is there a way to override this?
13:33:07dom96I used to be able to just do PAsyncSocket(), now it complains that 'proto' is not initialised.
14:30:49*Smaehtin joined #nimrod
14:31:48dom96hello Smaehtin
14:32:26SmaehtinHi :D
14:34:00SmaehtinAnyone here got any info on what the v2 GC does? Compared to the ref counting or mark/sweep one
14:34:23dom96the v2?
14:34:40dom96you mean the default one?
14:34:45dom96http://build.nimrod-code.org/docs/gc.html
14:35:12SmaehtinIt doesn't say anything about the v2 one. Not sure if it's the default one
14:35:19SmaehtinFrom the compiler user guide:
14:35:20Smaehtin--gc:refc|v2|markAndSweep|boehm|none select the GC to use; default is 'refc'
14:37:08dom96hrm, not sure. That may be zahary's slightly modified version of the default GC.
14:37:47dom96Araq might be able to tell you the real differences when he's around, or zahary1 (or zahary__)
14:38:07SmaehtinAlright, thanks :)
15:15:51*Roin quit (Quit: WeeChat 0.4.1)
15:16:02*Roin joined #nimrod
15:16:02*Roin quit (Changing host)
15:16:02*Roin joined #nimrod
16:30:31dom96zsh is still sharing history... -.-
16:37:15EXetoC:E
16:38:47EXetoCdom96: do you see that option if you type setopt?
16:39:03dom96yeah
16:39:35dom96maybe oh-my-zsh is overriding it
16:40:52EXetoCoh
17:51:47AraqSmaehtin: the v2 is a slight variation of the standard GC that's still unstable iirc
17:52:10dom96Araq: yo.
17:52:17Araqhi dom96
17:52:21dom96How do I deal with variable name collisions in my macros?
17:52:38Araqno idea what you mean
17:52:52Araquse clean macros?
17:52:58Araqaka not 'dirty'
17:53:20dom96Say I want to transform every 'foo' call into a 'var test = 56'
17:53:33dom96if the user has multiple 'foo' calls I have a problem
17:53:38Araqnope
17:53:48Araqthat's what clean templates is all about
17:54:53dom96I don't understand how that helps me.
17:56:02dom96I NEED to use a macro.
17:56:07dom96I'm working on the async stuff.
17:56:48Araqcool
17:57:09comexare macros less weird now than they were some years ago? :)
17:57:27Araqcomex: no ;-)
17:57:40Araqthey are more complex now and still feature incomplete and buggy
17:57:55Araqbut we're getting there
17:58:24dom96Would be cool if I could stick it all into a 'block' and then {.inject.} from within it :P
17:59:29Araqyou can try macros.quote, dom96
18:00:03Araqcomex: ok they are less weird now, the parameter lists now work
18:00:06dom96er, how does that help?
18:00:23Araqsymbols in macros.quote are clean
18:00:40Araqand there have been bug reports about it of course
18:00:47dom96yeah :P
18:00:49Araqbut it seems to do what you have in mind
18:00:57dom96I could never get it working.
18:02:04dom96I still don't think you understand my problem.
18:02:31Araqquite possible
18:02:57dom96var line = await readLine
18:02:59dom96->
18:03:07dom96var lineReq = PRequest(socket: client, kind: reqReadLine, line: "")
18:03:11dom96yield lineReq
18:03:17dom96var line = lineReq.line
18:03:32dom96Now what happens if the user has two of these calls?
18:03:42dom96error: redefinition of 'lineReq'
18:03:57Araqnot if you gensym the lineReq properly
18:04:06dom96ok, there we go.
18:04:09dom96How do I do that?
18:05:05dom96bindSym?
18:05:14Araqlet decl = macros.quote"""var lineReq: PRequest"""
18:05:23Araqlet lineReqSym = decl[0]
18:05:47Araq(I think and hope)
18:06:09dom96won't that generate the same code?
18:06:13dom96causing the same error?
18:06:25AraqI don't think so
18:08:29dom96internal error: (filename: compiler/semexprs.nim, line: 1355)
18:09:52Araqok, try getAst for a template declaration then instead
18:10:53dom96quote just fails with everything...
18:11:58Araqit's 'quote do'
18:12:12Araqnot quote"""string""", I misremembered
18:12:29dom96internal error: (filename: compiler/sempass2.nim, line: 452)
18:12:32dom96lol
18:12:37dom96in any case
18:12:41AraqI fixed that
18:12:42dom96I submitted an issue on gh
18:12:50Araqlet me push ...
18:13:12dom96ok
18:20:16NimBotAraq/Nimrod master 13e1130 Araq [+0 ±10 -0]: refactorings for the eval engine; bugfix: clean templates as accessors
18:20:16NimBotAraq/Nimrod master 8f58608 Araq [+1 ±5 -0]: 'modules' module from 'main'; minor bugfixes
18:20:16NimBotAraq/Nimrod master f706e36 Araq [+7 ±23 -3]: Merge branch 'master' of github.com:Araq/Nimrod
18:27:05*DAddYE quit (Remote host closed the connection)
18:27:18*DAddYE joined #nimrod
18:28:46dom96yeah, it crashes with a different error now
18:29:08dom96https://gist.github.com/dom96/e9b17c5ef05c0a94a325
18:30:51Araqdo you contruct wrong procs in your macro?
18:31:52dom96it works if I use parseExpr
18:33:46AraqparseExpr for what?
18:37:32dom96https://gist.github.com/dom96/313279a22d47f45af6df
18:40:33SmaehtinAraq: Alright, I see, thanks :p
18:41:12Araqdom96: alright make a bug report with that lattest error message please
18:47:12dom96I'll update the issue I already created.
18:47:43Araqdom96: does nimbuild know about csources already?
18:47:49dom96nope
18:47:57Araqk
18:50:21dom96so, what should I do?
18:52:49Araqyou said parseExpr work for you? so I dunno what you mean
18:53:16dom96it works as in the compiler doesn't crash
18:53:27dom96it doesn't do what I want, i.e. the variables clash.
19:02:14dom96so, what should I do?
19:02:37Araqignore the problem for now
19:02:46dom96sure
19:02:49Araqan API is planned and easy to do
19:02:59Araq'gensym' for constructing the AST
19:03:21dom96good
19:03:25dom96how's the VM going?
19:03:56AraqI dunno
19:04:54dom96brb
19:26:06*DAddYE quit (Read error: Connection reset by peer)
19:32:06dom96back
19:41:26*gradha joined #nimrod
20:00:47*EXetoC quit (Read error: Connection reset by peer)
20:04:23dom96hey gradha
20:04:29*DAddYE joined #nimrod
20:05:04gradhahey dom96
20:05:18dom96is your internet this laggy, or are you just torrenting?
20:05:30*EXetoC joined #nimrod
20:05:37gradhaalways torrenting
20:06:20gradhaI'll stop the torrenting, see for 8 hours if it makes any difference for reconnections
20:06:55gradhayou may check my lag now
20:06:59dom96I wonder if there is a way you could give nimbuild priority heh
20:07:47gradhahaven't fiddled with the router yet, maybe there are QoS settings, though it would be weird to increas priority to pings
20:08:32*dom96 waits patiently for nimbuild to ping you
20:09:37EXetoCseems a bit weird, unless your router can't handle the capacity or something
20:10:14dom96now it's 14 seconds
20:10:20gradhathere are three routers between my laptop and the network, plus one is wireless
20:10:29gradhaI guess pings just suck
20:10:42dom96lol, well that explains it I guess
20:10:49gradhaeverything else feels speedy
20:11:38gradhaI wonder if the 14s ping is now due to time machine kicking in backups, that degrades overall performance
20:11:46dom96I remember your ping used to be very small.
20:11:54dom96so maybe
20:12:06dom96down to 12 seconds now
20:12:20gradhamaybe I'm a host of malware
20:13:08dom96yeah, maybe you're running a massive botnet
20:13:09EXetoCwoah, time machine?
20:13:58gradhait's the Apple Branded TM name for differential backups
20:14:20gradhardiff with a really sucky lame interface, usefull nonetheless
20:15:09gradhaactually http://www.nongnu.org/rdiff-backup/, not the plain rdiff
20:15:18comexbut the stars
20:15:35gradhadom96: check me now
20:16:29EXetoCI thought maybe you were bending space and shit
20:16:35EXetoCdoesn't seem too complicated actually
20:16:35gradhahaha, just disconnected, man, this connection sucks
20:16:59gradhadon't understand why it affects nimbuild, when I ping a server it's in the 5ms range
20:17:55gradhapinging nimrod-code.org gives me 60ms
20:18:11dom96* Ping reply from gradha: ? second(s)
20:18:15dom96hrm
20:18:21gradha? seconds?
20:18:26gradhathat's new
20:18:33dom96Nimbuild says 10 seconds
20:18:50dom96Also I accidentally CTCP GRADHA'd a guy called ping.
20:19:19dom96I always get the order of /ctcp wrong :P
20:19:37EXetoCyeah, the other way seems more natural
20:19:44gradhamaybe the nimbuild thing is a problem with signals under macosx, which I still have to look at
20:19:45EXetoC+around
20:20:38dom96gradha: perhaps
20:21:37dom96nooo EXetoC, stop trying to haxor me
20:21:57EXetoCit wasn't on purpose
20:22:32dom96sureee
20:29:52dom96Araq: btw I figured out how to pass arguments to my await procs :P
20:30:21dom96Perhaps you suggested to do it this way, but I don't remember your suggestions anyway so lets just say I came up with it ;)
20:30:29Araqsure why not
20:30:44dom96It uses a cast though
20:30:52dom96So you will probably tell me I shouldn't do it.
20:31:23Araqwhat do you cast?
20:31:29dom96A PObject
20:31:38dom96into it's concrete type
20:31:45Araqwhy not convert it then?
20:31:54dom96conversion fails at runtime
20:32:09Araqwell ... you know ...
20:32:19Araqthat means it's a pretty bad idea
20:32:19dom96dunno, maybe I can save the type desc as well
20:32:38AraqI don't think so, a type desc is no runtime entity
20:32:54dom96oh well. It's better than nothing :P
20:33:13Araqchances are high it only works until you push it a little
20:33:30dom96yeah, well i'll see.
20:33:37gradhadoes somebody have a nice usage case for arrays' negative indices?
20:33:45dom96maybe you will be able to suggest a way to improve it
20:34:14Araqgradha: a[-3 .. -1] # picks last 3 items
20:34:31gradhathat's a slice
20:34:42gradhaI mean: why would you define an array with negative indices?
20:34:53gradhaTArray = array[-10..10, int]
20:35:22gradhanimrod is the first language I know supporting them, so I haven't felt the lack of them for my usual coding
20:35:22Araqenum x = -1, ...
20:36:07AraqTArray[TMyEnum, int]
20:36:25gradhathe usage case I've had for negative enums is precisely to force out of bounds exceptions
20:36:55Araqnegative enums come up when wrapping C
20:37:25gradhabut in C they are not used as array indices
20:37:40Araqtrue
20:37:44gradhaso it's cool that nimrod supports that but... is it useful?
20:37:56Araqnot very but it's consistent
20:38:18dom96people are creative, i'm sure someone will find a use for this feature.
20:38:46gradhaconsistent at the const of disallowing negative slices for arrays
20:39:15Araqah now you're talking about the real thing
20:39:20gradhasince it seems we are in feature suggestion moonphase I was about to request negative array indices to be dropped
20:39:34Araqno need to drop them
20:40:06Araqwe could have ordinary slices for them anyway
20:40:31EXetoCsome unused local closures generates internal errors
20:40:43AraqEXetoC: still?
20:40:54AraqI fixed that ...
20:41:02EXetoCok, when?
20:41:14Araqbefore the release of 0.9.2 ...
20:41:43EXetoCright
20:42:06DAddYEhttps://github.com/Araq/Nimrod/issues/535
20:42:22DAddYEjust because i've few haters
20:42:23DAddYEhahaha
20:42:48AraqDAddYE: closed it already
20:42:51dom96"That's crazy talk."
20:42:55dom96I absolutely agree.
20:43:08EXetoCha
20:43:48EXetoCgotta reproduce it then... I'm not going to bother with another huge test case :>
20:44:15DAddYEdom96: hehe why?
20:44:37dom96Because this isn't C.
20:44:55DAddYEhaaaaaaaa
20:44:58DAddYEyep
20:45:09EXetoCI don't care if it looks like C, but yeah it's kinda minor
20:45:36DAddYEEXetoC: indeed
20:45:50DAddYEwas just a try to prevent (for those who want)
20:45:52EXetoCactually, nevermind that
20:45:55DAddYEthe use of prefixes
20:46:16EXetoCmuch of C's syntax is brackets and what have you
20:46:55EXetoCprefixes, as in type declarations? that's fine
20:47:16EXetoCespecially since it often doesn't make sense to have a non-reference variation of something, so you might as well go with PFoo anyway
20:47:21dom96Another reason is that `&` is string concatenation!
20:47:25AraqDAddYE: explicitness comes with a tax. it's called verbosity.
20:47:27EXetoCunless I'm talking about something else here
20:48:24Araqif you prefer 'ref T' that's fine but then you better live with the verbosity
20:48:43DAddYEor add a template myself
20:48:44DAddYEbut
20:48:45dom96In a language where you use 'not' instead of `!` and 'and' instead of `&&` etc. `&` instead of 'ref' doesn't make sense.
20:48:59Araqotherwise we already have PT, no need for &T
20:49:20DAddYEwrite PT is up to the devel
20:49:31DAddYEI can write it RT => ref T
20:49:37gradhadom96: didn't Araq regret using not/and instead of `!`/`&&`?
20:49:37DAddYEor PT => ref T
20:49:44DAddYEor use foo = ref object
20:49:46EXetoCyep, a conscious choice made by you
20:49:54Araqgradha: nope
20:50:08DAddYEand source will be less readable
20:50:16dom96I love not/and btw
20:50:38EXetoCit's very easy for me to parse it
20:50:38dom96it just makes sense. It's also how Python does it.
20:50:49gradhaAraq: so maybe it was ! being a template? not that it's important anyway
20:51:07Araqgradha: it was ! for identifier construction
20:51:09gradhaAll hail the dongle!
20:51:37EXetoCT is type, P is ref or ptr. everyone is different of course, but that is very intuitive to me
20:52:03AraqEXetoC: yeah but people hate it
20:52:23EXetoC:o
20:52:29DAddYEEXetoC: hand have no choice
20:52:35DAddYEEXetoC: and have no choice
20:52:49DAddYEsources looks less readable
20:52:55DAddYEapi docs looks scary
20:53:05DAddYE(I'm not saying that's for me)
20:53:11dom96To be fair, I haven't seen people complain about the prefixes (except DAddYE)
20:53:21*gradha opens a bottle of liquor and pours 1/3 of a glass
20:53:21dom96They only complain about style insensitivity.
20:53:28EXetoCso people who don't know the language? in that case, then it's an invalid argument imo
20:53:39Araqdom96: filwit complained about them heavily too
20:53:53Araqand so did people whose name I can't remember
20:53:56DAddYEdom96: the thing is simple
20:53:59DAddYEmostly
20:54:02dom96I've learned to love them...
20:54:16DAddYElike my some of my friends after seeing
20:54:30DAddYEprefixes + sensitive case issue
20:54:39DAddYEdon't ever try it or give a chance
20:54:41DAddYEI did
20:54:54DAddYEbut after like 1 year that I'm checking the language
20:55:06DAddYE1 year ago I was too scared too
20:55:27DAddYEand if now I'm here is because I tried to broke the giant
20:55:28DAddYEwall
20:55:43gradhaDAddYE: you should try perl
20:55:46DAddYEbetween me and my "conventions"
20:56:10DAddYEgradha: I'had to use ruby, clojure, python (few), scala (few) and many others
20:56:14DAddYEso perl no thanks
20:56:15DAddYE:D
20:57:08DAddYEruby for hi-level shit, clojure when I need java vm and now after many years I'm looking for some (missing) for low level / c interface
20:57:09dom96This, quite simply, sucks. From what I can tell the only reason this is a problem is because people have never used languages which impose this prefix convention.
20:57:31dom96There is absolutely no disadvantage to using these prefixes, and there may be advantages.
20:57:48DAddYEdom96: indeed
20:57:48EXetoCdom96: yeah, I care more about early adopters that are actually open-minded
20:58:06dom96EXetoC: Sadly there are not many out there.
20:58:32EXetoCunsurprisingly
20:58:43dom96It's human nature to fear change I guess.
20:58:50DAddYEdom96: I agree with you
20:59:00DAddYEbut I'm fucking sad
20:59:03EXetoCperhaps
20:59:29Araqwell you know ... there IS a forum topic about this very issue
20:59:48DAddYEthat when I talk to people with it they first: scared about community (a language should have a giant community), if you sum the prefix issue + sensitive case
20:59:56dom96I am aware. It's nice to give some love to this IRC channel too though.
20:59:57DAddYEwill be super hard that they will give a chance
21:00:05DAddYEfor the reasons you perfectly wrote
21:00:09dom96Talking on the forum takes too much thinking :P
21:00:54dom96DAddYE: indeed. The biggest problem we have is that we have no large company supporting us and therefore many people don't see the point in investing time in something which could potentially die.
21:01:34EXetoCthose people are probably happy with some well-established industry language then, so whatever
21:01:51DAddYEdom96: nimrod is so awesome, that day will happen
21:01:57Araqhowever this "you can use any style except you need to use T/P prefixes everywhere" is annoying from a philosophical point of view
21:02:04dom96If we had Google or Mozilla using Nimrod then people would still use it even if Nimrod had no if statements.
21:02:20Araqdom96: yeah or no generics ;-)
21:02:26dom96yes!
21:02:43dom96or no exceptions.
21:02:44dom96:P
21:02:48DAddYEbut IMHO we should smooth the edges to make it good for mostly everyone
21:03:31DAddYEor no metaprogramming
21:03:39gradhaAFAICS a T/P prefix allows having a TArray and an array variable, otherwise you have an Array type and have to use a prefix for every single instance of variable you want to name array, like aArray or something like that
21:04:09DAddYEgradha: mmm not super true but yep
21:04:19gradhahaving seen the horror of aWhatever in other languages I prefer prefixes
21:04:21DAddYEyou should do that at least in order to avoid your confusion
21:04:29Araqyeah but I consider 'var array: Array' or 'var array: TArray' equally bad
21:04:31dom96gradha: If the language is case sensitive you can just use an upper case first letter to mean 'this is a type'
21:04:46AraqI prefer 'var a: array'
21:04:52dom96Which isn't bad.
21:05:01DAddYEindeed
21:05:05gradhaOr 'var l: array'
21:05:07Araquse the type system to introduce shortcuts
21:05:37dom96I have used Haskell before using Nimrod and liked the 'capital first letter means this is a type' convention.
21:06:13dom96perhaps we should make Nimrod dynamically typed and then we wouldn't need to worry :P
21:06:23Araqbtw as soon as you have 'proc copy(dest: var TX, source: TX)'
21:06:36Araqpeople strangely stop to name their parameters after the type
21:06:41Araq*stop naming
21:06:46gradhadom96: and make nimrod run on the java vm too
21:06:55DAddYEhere https://github.com/DAddYE/node.nim/blob/master/uv.nim
21:07:06dom96gradha: yes!
21:07:10DAddYEa big big number of types
21:07:14DAddYEbut mostly enums
21:07:19DAddYEfor a lot of coders
21:07:26DAddYE(good or bad reasons)
21:07:34dom96gradha: I can't wait to spend money on more RAM!
21:07:41DAddYEsounds crazy that they can't use
21:07:43DAddYEfor procs
21:07:52DAddYEthe same name
21:08:04gradhadom96: I heard Sun sells these java hardware accelerated cards for mainframes, they are speedy!
21:08:37DAddYEor that they should pay attention if GET is an enum or a var because GET or get (var)
21:08:37dom96DAddYE: Those aligned : look really odd heh
21:08:57AraqDAddYE: well ALLCAPS are stupid anyway and the compiler should forbid them IMO
21:09:08DAddYEAraq: talk with c2nim
21:09:09DAddYE:D
21:09:42DAddYEdom96: reason for : aligns is that it's more simple to edit (column editing)
21:09:44Araqconstants are nullary functions anyway
21:10:06dom96DAddYE: what editor do you use?
21:10:11DAddYEdom96: vim
21:10:14EXetoCI'm not sure what there is to edit
21:10:42DAddYEdom96: http://vimcasts.org/episodes/selecting-columns-with-visual-block-mode/
21:10:56EXetoCanyway, I use an align plugin for vim, but it's still kinda annoying at times, if you change names a lot
21:11:01DAddYEEXetoC: in some parts I've tried to uint remove u to cast to a int etc
21:11:10DAddYEyep
21:11:14DAddYEindeed I don't like it
21:11:20DAddYEI'll remove soon
21:11:38DAddYEis only useful for column editing and also
21:11:42DAddYEto reason about
21:11:44DAddYEtypes
21:11:52dom96DAddYE: Why would you edit all of those types simultaneously?
21:11:52DAddYEsince I c2nim it
21:12:15DAddYEdom96: if I want to remove prefixes :D
21:12:33DAddYEdom96: https://github.com/DAddYE/node.nim/blob/master/uv.nim#L309-L314
21:12:44*dom96 looks at all those types without a prefix :P
21:12:46DAddYEI can remove T and c
21:12:54DAddYEdom96: did
21:12:56DAddYESCARY
21:12:57DAddYE:D
21:13:22DAddYEespecially with the giant amount of enums
21:13:25dom96I would just find & replace the prefixes.
21:13:32dom96simple.
21:13:45EXetoCDAddYE: cast, why? if you need unsigned, then you need unsigned. I mostly need them for C stuff
21:13:49dom96With my lovely Aporia!
21:14:19AraqEXetoC: often I map C's unsigned madness to signed
21:14:19DAddYEEXetoC: yea wrong example
21:14:24dom96but yeah, I would like the look of the code a lot more without all that aligning.
21:14:45DAddYEbut as araq said I usually do the same (in few circumstances)
21:14:55dom96I do align var assignments occasionally though
21:14:58DAddYEto avoid foo.bar = 12.uint8
21:15:23DAddYEbut I removed the header and use only dlib
21:15:27DAddYEso I reverted back
21:15:30DAddYEsome of them
21:15:48EXetoC12'i8
21:16:05DAddYE12'ui8
21:16:12DAddYEunsigned
21:16:18DAddYEbut not sure we have 'ui8
21:16:25EXetoCoops
21:16:32DAddYEand my editor doesn't play nice with '
21:16:42DAddYEso I don't use it that much
21:16:53DAddYEbbl
21:16:58*DAddYE quit (Remote host closed the connection)
21:17:25*DAddYE joined #nimrod
21:17:53EXetoCI mean 'u8
21:17:57EXetoCmeant
21:20:10EXetoCAraq: well yeah, whenever possible
21:21:43*DAddYE quit (Ping timeout: 252 seconds)
21:32:24gradhaAraq: is it expected that the gc SIGSEGVs when I try to iterate over an array with a slice like obj[2.. -2]?
21:33:25AraqI don't think so ...
21:33:46gradhawhat would be the expected behaviour? nop?
21:33:46Araqhowever it depends on 'obj'
21:34:03Araqno idea what you mean
21:34:22gradhait's a slice for an array with only positive indices
21:34:47gradhaarray[0..6, int] and later for i in mirror[2.. -2]:
21:38:47Araqwell make a bug report then
21:40:10gradhanop == no operation, as in the array would not run due to the start index being bigger than the end limit, but I guess there's first a temporal object construction which is what's failing
21:41:28*gradha wonders if an awesome static language could detect that case and avoid even generating the whole for block
21:42:02Araqsure and it's easy to do
21:42:15AraqI got quite close to implement that
21:43:48dom96argh, macros really mess up line numbers
21:44:10gradhait would be more useful to flag that as an error, since it's unlikely that the programmer wanted that at static time
21:44:47Araqdom96: the problem is that there 2 different line numbers
21:45:02Araqthe line number it came from if it's copied node
21:45:16Araqplus the line number from the code that produced the node
21:45:25Araqwhat do you want?
21:45:32dom96no idea
21:45:48gradhafor some reason macros invoking macros reminds me of c++ inexcrutable nested template errors
21:46:09gradhahow about nested line numbers?
21:46:19gradhaa line number like 23-1255-23
21:46:23Araqtoo expensive to implement
21:46:55dom96how do I get the other line number?
21:46:57gradhaok, I'm starting a quickstarter
21:47:13gradhaerr... kickstarter
21:47:30dom96for what?
21:47:37Araqah so now kickstarter can reduce the compiler's memory usage?
21:47:51gradhadom96: to raise money for the implementation of nested line numbers
21:48:02dom96hah
21:48:05dom96i see
21:48:54dom96We can surely use the kickstarter money to buy every nimrod user some more memory
21:49:09dom96Araq: how do I get the other line number?
21:49:18gradhahaven't actually measured compiler memory usage, is it that bad? like java bad? like openoffice bad?
21:49:45Araqgradha: it's much better than java but constantly getting worse
21:50:23Araqdom96: I don't know
21:50:43AraqnewNimNode takes a line number for a reason
21:51:27Araqoh wait
21:51:33Araqnobody use it
21:52:25Araqso it's the line info of the code that creates that node
21:52:42Araqwhich is always macros.newNimNode ...
21:52:49Araqvery useful
21:54:30*gradha smells nested line numbers
21:55:17Araqdom96: edit evals.nim:1240
21:55:42Araqmake it callsite.info instead of n.info
21:55:52Araqc.callsite.info
21:56:05Araqand check if it improves anything
21:57:59dom96ok
21:59:07Araqgradha: I think nested line numbers are commonly known as "stack traces" ;-)
22:00:22gradhaif a compiler barks an error involving a macro like "blah not found at line x.y.z" that's more compact than a stack trace
22:00:30dom96well that didn't change anything
22:00:46gradhathough I guess you would also need filenames other than line numbers, meh, bad idea
22:01:07Araqplus nobody knows what line x.y.z means
22:01:33gradhayeah, we would want to scare new programmers to weird compiler errors
22:01:50gradhait worked for c++ after all
22:02:23dom96meh, I guess the line number kinda makes sense
22:02:39Araqwhat worked for C++ will hopefully never work again ...
22:04:10gradhamonetization idea: compiler spits out integers, a paid "compiler error pack" translates them to friendly user errors
22:05:24EXetoCI like that
22:18:58*DAddYE joined #nimrod
22:21:22*gradha quit (Quit: bbl, need to watch https://www.youtube.com/watch?v=1ZZC82dgJr8 again)
22:23:33*DAddYE quit (Ping timeout: 264 seconds)
22:25:42*Reisen quit (Quit: Goodbye)
22:26:29*Reisen joined #nimrod
22:42:43NimBotAraq/Nimrod asyncmacro 9f29712 Dominik Picheta [+2 ±1 -0]: First implementation of the async/await-like system with macros.
22:43:52dom96Now isn't that sexy? https://github.com/Araq/Nimrod/blob/9f297120d1622dd9f6b08ec7cab582419bb811d2/tests/compile/tasyncitermacro.nim
22:49:21dom96Araq: This is how I do the arg passing: https://github.com/Araq/Nimrod/blob/9f297120d1622dd9f6b08ec7cab582419bb811d2/tests/compile/tasynciterraw.nim#L35
22:49:23dom96Thoughts?
23:03:11*Araq__ joined #nimrod
23:04:23*Araq_ quit (Ping timeout: 264 seconds)
23:19:34*DAddYE joined #nimrod
23:28:58*Smaehtin quit (Quit: Page closed)
23:38:13dom96good night
23:44:46*DAddYE_ joined #nimrod
23:44:47*DAddYE quit (Read error: Connection reset by peer)
23:49:35*EXetoC quit (Quit: WeeChat 0.4.1)