<< 05-04-2016 >>

00:15:58*vendethiel quit (Ping timeout: 248 seconds)
00:17:17*desophos quit ()
00:17:47*enthus1ast quit (Read error: No route to host)
00:19:13*enthus1ast joined #nim
00:58:36*desophos joined #nim
01:03:47*alexsystemf_ quit (Quit: Connection closed for inactivity)
01:21:30*vendethiel joined #nim
01:31:42*brson quit (Quit: leaving)
01:42:54*vendethiel quit (Ping timeout: 248 seconds)
01:54:04*oceanpollen quit (Ping timeout: 244 seconds)
01:55:03*oceanpollen joined #nim
02:11:40*vendethiel joined #nim
02:27:11*veganskaway is now known as vegansk
02:33:34*vendethiel quit (Ping timeout: 240 seconds)
02:44:08*ephja quit (Ping timeout: 244 seconds)
03:03:59*chrisheller quit (Remote host closed the connection)
03:11:12*chrisheller joined #nim
03:32:23*Jesin quit (Quit: Leaving)
04:02:47*vendethiel joined #nim
04:24:03*vendethiel quit (Ping timeout: 246 seconds)
04:33:56*endragor joined #nim
04:43:29*vendethiel joined #nim
05:05:11*vendethiel quit (Ping timeout: 250 seconds)
05:21:22*desophos quit (Read error: Connection reset by peer)
06:03:06*gokr joined #nim
06:22:30*endragor_ joined #nim
06:26:45*endragor quit (Ping timeout: 276 seconds)
06:43:01*endragor_ quit (Remote host closed the connection)
06:43:30*endragor joined #nim
06:43:59*vendethiel joined #nim
07:12:22*Trustable joined #nim
07:18:22*vendethiel quit (Ping timeout: 248 seconds)
07:37:51*PMunch joined #nim
07:44:31*Demon_Fox quit (Quit: Leaving)
07:45:37*yglukhov joined #nim
07:46:37*dorei joined #nim
08:15:12cheatfatewe have troubles with atomic operations on bsd
08:15:18cheatfatewe have troubles with atomic operations on openbsd
08:16:22cheatfatehttps://gist.github.com/cheatfate/390ec948a29525543b3ddb71122fb204
08:18:23cheatfateany compilation with "--threads:on" on openbsd results in an error
08:22:13cheatfategithub is down?
08:31:31*wuehlmaus quit (Read error: Connection reset by peer)
08:32:19cheatfategithub is down: We are experiencing connectivity issues and are currently investigating.
08:48:19veganskcheatfate, hi. you are not alone :-)
08:54:46cheatfategithub:
08:54:46cheatfate11:48 FLE Standard Time
08:54:46cheatfateMajor service outage.
08:59:59gokrhum
09:12:10*ephja joined #nim
09:16:46*yglukhov quit (Ping timeout: 248 seconds)
09:17:23cheatfategithub is fine now
09:18:34*yglukhov joined #nim
09:19:01*yglukhov quit (Remote host closed the connection)
09:31:36veganskcheatfate, please check this comment: https://github.com/nim-lang/Nim/pull/4000#issuecomment-205639867
09:31:39*elrood joined #nim
09:32:23cheatfatevegansk, i think github is down again
09:33:20veganskcheatfate, the PR #4000 is too hard for github :-)
09:33:36veganskgithub works for me
09:34:03veganskbut so slooooow
09:34:07gokrYup
09:35:09cheatfatevegansk, the main problem of 4000 is that some code used in program stub
09:35:17cheatfateso it was included...
09:36:08cheatfatebut in program stub used only simple acquire/release SystemLock
09:36:22cheatfateso all other staff can be moved out
09:39:55cheatfatebut you dont want to do this :(
09:42:01*enthus1ast quit (Read error: No route to host)
09:44:34*enthus1ast joined #nim
09:45:28*baff1e quit (Ping timeout: 252 seconds)
09:46:59veganskfor now, stub uses only small parts of syslocks. what if it will need another parts of it? so we will move the parts from syslocks to locks and back. i think it's a bad idea. it's not a public API, it's an internal part of stdlib and i think that here we can apply hints hiding
09:48:08cheatfatevegansk, for what reason stub will need more?
09:49:14cheatfatei dont think stub will be modified in future
09:49:40cheatfatebut i dont want dispute on that, because its Araq's area...
09:50:10*gokr1 joined #nim
09:50:31cheatfatei'm just propose to move out all staff not needed for current stub code to avoid this annoying warnings
09:51:06Araqjust disable the warning and move on. work on something more important please.
09:52:41elroodhm, interestingly dom chose to update nimble's version in the changelog but not in its source
09:53:36cheatfateAraq, could you please check https://github.com/nim-lang/Nim/issues/4046
09:55:23Araqhttps://people.freebsd.org/~emaste/stdatomic.h ?
09:55:46Araqmaybe it's in some different header.
09:55:57*pandada8 quit (Ping timeout: 260 seconds)
09:58:45cheatfateAraq, i did searching for ATOMIC_RELAXED on all headers and there nothing found...
09:58:57dom96hello guys
09:59:16cheatfatedom96, ahoy
10:00:07cheatfateAraq, it looks like you are using g++ staff... for ATOMIC_RELAXED
10:00:18dom96elrood: Not so much "chose" as forgot.
10:01:03dom96elrood: 0.7.0 and 0.7.2 are practically the same anyway
10:02:16*yglukhov joined #nim
10:02:17*yglukhov quit (Remote host closed the connection)
10:03:48cheatfateAraq, only staff for atomic operation on openbsd is here [sys/atomic.h] https://github.com/lattera/openbsd/blob/master/sys/sys/atomic.h
10:05:44*gokr1 left #nim (#nim)
10:05:44Araqcheatfate: please check what the C and C++ standards say and try to use that
10:05:56*gokr quit (Remote host closed the connection)
10:07:37cheatfateAraq, while googling i found only information that openbsd using old libstdc++ so there no atomic staff you using in atomic.nim... other opensource projects just adding [not defined(openbsd)]
10:08:22Araqtime to upgrade your OpenBSD?
10:10:24*yglukhov joined #nim
10:10:29*irrequietus joined #nim
10:10:53dom96yglukhov: replied to your comments on github
10:12:08*enthus1ast quit (Read error: No route to host)
10:12:49cheatfateAraq, https://bugzilla.mozilla.org/show_bug.cgi?id=876156 [libc++ is not ported to openbsd yet]
10:16:22*fredrik92 joined #nim
10:17:28*arnetheduck joined #nim
10:20:43Araqcheatfate: can you use clang on BSD?
10:22:10cheatfateAraq, i dont think i can use clang because its "OPEN"bsd
10:23:54*pandada8 joined #nim
10:25:58yglukhovdom96: i really can't see the reasoning in #3107. The problem is mostly in echo + len i would say. Also there's no ambiguity in Json[], since it returns Json ref only, it can't return 0 or string(nil) or anything that table returns. Anyways, even if you feel like changing this behavior, you could easily add "when not defined(preserveObsoleteJsonBehavior): echo "WARNING! Returning nil in case of missing field is deprecated!" else: do_th
10:25:58yglukhove_new_behavior_and_raise
10:27:05yglukhovto give some time to migrate, and provide some way to catch the remaining bugs
10:27:40dom96Sure, I can do that.
10:28:18dom96And yes, you're right. There is no ambiguity with Json's `[]`, but I still think we should make it consistent with table's `[]`
10:31:22veganskyglukhov, hi. jnim exports imported classes and doesn't export imported methods. i want to create one more ``jnimport`` macro, so one of them will import without reexport, and another with. what do you think?
10:31:26*pandada8 quit (Ping timeout: 248 seconds)
10:37:47*ephja quit (Quit: WeeChat 1.4)
10:40:03Araqdom96: not sure I agree with that consistency requirement. tables.[] mostly raises an exception because of the 'var T' requirement
10:40:34Araqthis way we could get rid of 'mget' which was a constant gotcha
10:41:14Araqwhat does Python's Json module do?
10:41:29dom96pretty sure it raises an exception
10:42:01dom96I think it's also more user-friendly to raise an exception.
10:47:58yglukhovvegansk: I'm not sure what you mean. Wouldn't it be enough just to handle * appropriately in proc defs? Also i'm a bit concerned with the fact that current class import syntax doesn't account for generated visibility.
10:49:20*fredrik92 quit (Quit: Moving around between university Wi-Fi Hotspots... :P)
10:51:11yglukhovAraq, dom96: I don't think python is a good example in our case. Afaik, python uses builtin arrays/dicts to work with json, and all json does is python_obj_to_string_and_back. So the reasoning in obj[] throwing is not dictated only json, but rather the overall language semantics.
10:51:17veganskyglukhov, i thought about it. the problem is that in that case (* for procs) i must use something like ``export`` for classes. Wait, i'll create a gist for example
10:53:29*girvo quit (Ping timeout: 260 seconds)
10:56:05yglukhovbut in nim json is a distinct entity that has nothing to do with tables/arrays. And nim is more typed then python as well. So the only reasoning i can see really is consistency with tables, but here's the thing. Tables are a general purpose data structure, that in many cases may imply existance of a key. While json is not! normally jsons are generated from external (malicious) input, and when working with them you should always(!) acco
10:56:05yglukhovunt for missing fields.
10:56:11*girvo joined #nim
10:58:34veganskyglukhov, here it is: https://gist.github.com/vegansk/68af805063e50f0d673caa00efbce2d0 . There is a problem for the first option: it's not that fast to refactor all of the imports to export them :-)
10:58:54yglukhovwhile key lookup is done more naturally and intuitively with [] operator and not {} or 'getOrDefault', it should be the common pattern as well to account for missing field right after you get it with [] operator
11:00:07*pandada8 joined #nim
11:01:18yglukhovvegansk, btw fyi, one of my dreams is doing another jnimportAll (or alike) directive to provide just the qualified class name, and it would automatically import the proc defs in compile time =)
11:02:59*girvo quit (Ping timeout: 248 seconds)
11:03:48Araqyglukhov: raising an exception seems to be more convenient than having to handle 'if x != nil' everywhere though.
11:04:21*fredrik92 joined #nim
11:04:39Araqand since JSON is the foundation for most REST APIs that are not as dynamic as people think they are, I think I favor raising an exception.
11:05:36veganskyglukhov, it's a good idea, and i think that i'll do it. i have some pojos that has dozens of properties and i don't want to write imports manually :-)
11:08:07*fredrik92 quit (Client Quit)
11:08:30*fredrik92 joined #nim
11:08:33veganskyglukhov, and what about the exports syntax?
11:08:44yglukhovvegansk, just pushed some of my experiments, maybe take a look when you have some time.
11:08:55yglukhov2 mins, commenting your gist
11:12:50yglukhovcommented
11:13:23dom96Just added some nice new things into the readme on Github: https://github.com/nim-lang/Nim#readme :)
11:13:45*girvo joined #nim
11:16:25dom96That crown should be an emoji
11:16:51yglukhovAraq: ok i will not argue a lot about that. I'm fine as long as there remains some short syntax to get nils in case of missing. And thats because most of my code will use it + check for nil, because in most of my cases missing field is a perfectly valid case, and if not, i would like to handle the case right in my deserialization code, and not upstairs through exception.
11:17:38Araqyglukhov: I agree we need a decent migration strategy though.
11:17:48dom96yglukhov: You should be able to just replace `[]` with `{}`.
11:18:14yglukhovbtw, nil dereference exception is one of the killer features im eagerly waiting for ;)
11:18:39yglukhovit should be optional compilation flag, of course =)
11:19:00yglukhovthen we can do truly unbreakable servers in nim.
11:19:01dom96wouldn't better 'not nil' checking be better?
11:19:30yglukhovdom96: maybe. cant say for sure. have to play with it to understand =)
11:20:03dom96yay, a crown emoji exists. This is our official emoji guys: http://emojipedia.org/crown/
11:22:08Araqyglukhov: patch the C codegen then. it's not hard (tm)
11:22:24Araq--nilChecks:on|off used to exist
11:25:39dom96Araq: Want me to add what yglukhov suggested (the `when not defined(preserveObsoleteJsonBehavior)`)?
11:33:33*fredrik92 quit (Read error: Connection reset by peer)
11:34:21endragorAraq: have you considered allowing {.this.} pragma in proc scope? either as proc pragma or statement in a proc. that probably is not convenient for end-users, but that would allow writing macros such as OO macro without spoiling global scope.
11:37:13*ozra joined #nim
11:37:29*ozra left #nim (#nim)
11:38:22Araqendragor: the current plan is to make .this: self the *default* and .this can only be used to override the default (and may disappear in the longer run)
11:38:58dom96hah, I love gratipay https://twitter.com/Gratipay/status/717315428045991936
11:39:07endragorAraq: oh, interesting. thanks
11:48:45*krux02 joined #nim
11:49:35*enthus1ast joined #nim
11:53:31Araqdom96: I think it should be done the same way we did for the tables upgrade
11:53:41dom96how was that done?
11:53:55Araqvia a .deprecated in a 'when' iirc
11:54:11Araqgit log -p tables.nim
11:55:48Araqthe idea is that the compiler lists every usage of the [] operator and so the programmer can easily review these code sections
12:08:36*irrequietus quit (Read error: Connection reset by peer)
12:11:19arnetheduckAraq, any ideas for why https://github.com/nim-lang/Nim/pull/4015 is failing? initallocator is needed for nogc to avoid sysAssert, but tests fail when it's enabled
12:17:57*BitPuffin joined #nim
12:18:17krux02I just would like to ask, if there is effort or at least interest for nim to have move semantics at some point in the language?
12:19:11BitPuffinkrux02: the idea is that you'll overload = to implement moves or something
12:19:45krux02ButPuffin, but an assignemnt is not a move
12:20:11BitPuffinhmm usually in rust an assignment is a move
12:20:15BitPuffiniirc
12:20:18BitPuffinunless it has the copy trait
12:20:25dom96hey BitPuffin, how's things?
12:20:31BitPuffinhey dom96!
12:20:34krux02in rust, but nim is not rust, and in c++ an assignment is not a move
12:20:45krux02it's only a move, when the object, that is used to assign from is disposable
12:21:00BitPuffinkrux02: I don't think they'll add rvalue overloading to nim
12:21:16BitPuffindom96: I'm doing ok I guess, how are you? I saw you published more chapters, haven't gotten around to reading them yet
12:21:52dom96BitPuffin: Good. Been working on lots of Nim stuff lately, mainly got Aporia working on OS X.
12:21:53krux02can you pleas not use rvalue, I hate that name, it's just a bad name.
12:22:17dom96(Which was a bitch to figure out)
12:22:20krux02move semantic don't need c++ like rvalues
12:22:21BitPuffinkrux02: xvalue? :P
12:22:35BitPuffinkrux02: just make a macro then that explicitly moves
12:22:43krux02it just needs a distinction between a copy assignment and a move assignment, and deterministic destructors.
12:22:51BitPuffindom96: I saw you tweet about that!
12:23:02dom96BitPuffin: :D
12:23:11BitPuffindid you do write objective c code, or did you use wrappers around the native code
12:23:14BitPuffinnative api
12:23:15BitPuffinwhatever
12:23:16BitPuffinobj-c backend
12:23:29dom96BitPuffin: I used the gtk-mac-integration library.
12:23:41dom96BitPuffin: But the annoying thing was compiling GTK+ on OS X
12:24:31BitPuffindom96: ah, I thought you used cocoa
12:24:59BitPuffinbelieve gtk+ is pretty easy to install with brew, but it's a little fucked or something unless I remember wrong
12:25:19dom96BitPuffin: It is, but I wanted an easy to install Bundle :)
12:25:43BitPuffinI guess you could have copied the libs from where brew installs them :P
12:27:46dom96BitPuffin: nope
12:27:52dom96BitPuffin: first thing I tried ;)
12:28:13BitPuffinah okay lol
12:28:50BitPuffinkrux02: you can implement a move really easily if you have already declared the variable first
12:28:51dom96it worked on my Mac, and on my girlfriend's but failed on flyx's Mac
12:29:01BitPuffinbut you'd probably want a macro that declares and moves
12:29:20BitPuffinmoveTo a: b
12:29:52BitPuffinthough I guess it should only declare it if it isn't already
12:29:54BitPuffinor something like that
12:30:02BitPuffinit's implementable, if you want it that way
12:30:06Araqarnetheduck: I don't know. don't enable the allocator for nimscript
12:30:19BitPuffinand then you can just create a moveImpl for the types you wanna move
12:32:26Araqkrux02: I am looking into memory regions instead. Free your stuff in O(1) rather than micromanaging every single allocation with "move semantics, copying, RCs and destructors"
12:36:02BitPuffinAraq: you mean like jai?
12:36:36Araqnot sure what jai's current take on it is, but yes I can imagine it uses that.
12:36:41arnetheduckhey dom96, any luck with LD_LIBRARY_PATH?
12:36:56krux02I was hoping, that I could bind resorces to an object, and when the object get's freed, the resources get freed, too.
12:37:15dom96arnetheduck: haven't tried it yet, will do later :)
12:37:44AraqBitPuffin: I copied the design from GCC's deprecated obstacks though ;-)
12:38:16Araqkrux02: that's already possible and done with a finalizer.
12:38:24arnetheduckany easy way to create a set with all values from an enum?
12:39:31Araq{low(e)..high(e)}
12:39:40BitPuffinAraq: I believe it worked something like you allocate a big chunk of memory and push a sort of allocator for that memory in a pointer that gets passed to every function, and when you call the allocation function it will allocate from there, and then you batch-free the shit later
12:40:29arnetheduckthanks
12:40:46AraqBitPuffin: yeah but you don't need to pass it to "every function", you can use thread local storage instead ;-)
12:42:38BitPuffinkrux02: last time I asked about this I think there was a static destructor thing that wasn't implemented fully yet
12:43:06BitPuffinAraq: nah that's true, I'm not even sure if that's how he'll implement it, it was just an example of how it could be implemented
12:43:13krux02am am reading about the finalizer at the moment
12:43:43BitPuffinfinalizer runs when the gc collects I think
12:44:59krux02yes of course
12:45:38BitPuffinah so you weren't actually looking for move semantics, just finalizers
12:45:47krux02but according to the documantation it sounds, that I only need to pass the finalizer once to `new` afterwards I can just use `new` without the finalizer argument
12:45:51krux02but I am not sure about that
12:49:39Araqkrux02: you should use a constructor proc anyway.
12:54:11krux02ok, that's true
12:55:02krux02I wonder what the best solution is to wrap a c pointer with a destructor function
12:55:47krux02having a gc-ed object, which is itself just a pointer seems not right
12:59:23krux02btw, I tried to write some better gdb support for nim, and while I was trying to get help I accidentially motivated someone of the official qt-creator team to write some nim support for nim debugging
13:07:42*irrequietus joined #nim
13:12:37Araqyay. that's impressive.
13:13:20Araqyou inspired me to write a nimgdb module that simply translates C-ish output to Nim-ish output and can be used by every editor
13:13:41Araqunfortunately for us "inspired" here means that I didn't write a single line of code for it.
13:13:46Araq:-)
13:20:45*gokr joined #nim
13:22:04*elrood quit (*.net *.split)
13:22:05*lqdc quit (*.net *.split)
13:22:05*flyx quit (*.net *.split)
13:22:07*JStoker quit (*.net *.split)
13:22:07*kier quit (*.net *.split)
13:22:08*StarBrilliant quit (*.net *.split)
13:22:08*Guest67762 quit (*.net *.split)
13:24:10*flyx joined #nim
13:24:11*JStoker joined #nim
13:24:11*kier joined #nim
13:24:11*StarBrilliant joined #nim
13:24:11*Guest67762 joined #nim
13:24:28*saml quit (Remote host closed the connection)
13:26:32*M-max quit (Ping timeout: 258 seconds)
13:26:50*M-max joined #nim
13:27:36*lqdc joined #nim
13:28:00*elrood joined #nim
13:28:30*darkf quit (Quit: Leaving)
13:28:31*saml joined #nim
13:37:25*krux02 quit (Quit: Verlassend)
13:37:40*krux02 joined #nim
13:40:52*silven quit (Ping timeout: 244 seconds)
13:41:56*silven joined #nim
14:23:42*pregressive quit (Remote host closed the connection)
14:25:13*enthus1ast1 joined #nim
14:25:42*enthus1ast quit (Ping timeout: 246 seconds)
14:26:55*pregressive joined #nim
14:48:07*pregressive quit (Read error: Connection reset by peer)
14:48:23*pregressive joined #nim
14:49:52*pregressive quit (Client Quit)
14:54:10yglukhovvegansk, so what do you think about my coment in your gist? ugly?
14:58:30*wuehlmaus joined #nim
15:01:46yglukhovAraq, dom96: I'm concerned about the json.{} op. It seems more complex than i need. What do you think about term rewriting to do the trivial stuff in case when i pass one key to `{}`?
15:01:48*fredrik92 joined #nim
15:02:20Araqyglukhov: fine with me, it's high time the stdlib uses some term rewriting
15:02:37yglukhovnice
15:02:41dom96Yeah, go for it.
15:02:50yglukhovkk
15:03:51*dorei quit (Quit: Page closed)
15:03:53yglukhovdo i call the trivial proc 'getOrDefault*' to be consistent with tables?
15:04:26Araqyes
15:15:55*irrequietus quit (Remote host closed the connection)
15:16:37*irrequietus joined #nim
15:27:48*PaulDj joined #nim
15:28:48*PaulDj quit (Client Quit)
15:29:34*vendethiel joined #nim
15:32:53yglukhovAraq: strange, but i can't get term rewriting to work for some reason. can anyone see the mistake? https://gist.github.com/yglukhov/ea40a8dbe495ce8fd84d36a69f5815b1
15:42:54*krux02 quit (Quit: Verlassend)
15:50:52*Jesin joined #nim
15:52:54*vendethiel quit (Ping timeout: 276 seconds)
15:57:23yglukhovAraq: so it seems somwhow related to vararg thing. How can i write the correct pattern. kinda single vararg or smth?
15:57:55Araquse f([x]) in the pattern
15:58:08Araqas varargs constructs an array
16:09:09*yglukhov quit (Ping timeout: 276 seconds)
16:20:12*silven quit (Ping timeout: 276 seconds)
16:20:44*silven joined #nim
16:25:34*arnetheduck quit (Ping timeout: 248 seconds)
16:25:38*federico3 quit (Ping timeout: 260 seconds)
16:25:56*pleiosaur quit (Remote host closed the connection)
16:26:05*pleiosaur joined #nim
16:28:06*federico3 joined #nim
17:01:10*yglukhov joined #nim
17:05:39*yglukhov quit (Ping timeout: 248 seconds)
17:10:10*Demon_Fox joined #nim
17:23:26*endragor_ joined #nim
17:25:03*desophos joined #nim
17:26:39*endragor quit (Ping timeout: 244 seconds)
17:27:42*endragor_ quit (Ping timeout: 246 seconds)
17:34:57nivdom96: playing around with jester, attempting to write a json api. two thoughts: a) possible to install a global exception handler for requests? b) possible to auto-handle content-type application/json and attempt to parse body as such?
17:36:00dom96a) is on my todo list
17:36:08dom96(https://github.com/dom96/jester/issues/27)
17:36:14dom96not entirely sure what you mean by b)
17:36:27nivoo, right. the issue for a would be exactly my usecase
17:37:40nivb) is easily explained by example. other api frameworks, like ruby-grape (since you're modelling after sinatra) allows to pre-specify content-type parsers/generators. so if the client sends header "content-type: app/json", the framework parses the body as a json and gives the user a hash, instead of string/binary. same goes the other way, returning a hash from your handler auto-generates json and sends that to the client
17:38:27nivthis is traditionally done through some kind of middleware layer, i guess
17:39:36dom96hrm. I think I know what you mean. Might implement it some day, but it really doesn't sound like a priority I'm afraid.
17:40:40nivi understand, just throwing out ideas. some kind of middleware/transform framework would allow stuff like content transforms, but also parameter validation, request validation, throttling, etc
17:41:11nivsinatra gets that stuff for "free" since it builds on rack, which has middlewares
17:44:44dom96I'm not sure how middlewares work in the likes of Sinatra, but can't you simply call some libraries procedure in your route to perform those tasks?
17:46:20dom96Araq: Why is this {.deprecatedGet.} pragma defined in system/inclrtl?
17:47:26Araqdom96: no idea.
17:47:46Araqbecause many stdlib modules include it.
17:47:50*enthus1ast1 quit (Ping timeout: 244 seconds)
17:47:59Araqand it can savely be included by the stdlib.
17:48:06Araqso that's what JSON should use too.
17:48:13*Matthias247 joined #nim
17:48:18dom96yeah, but why can't it just be defined in the tables module?
17:48:43Araqit could be.
17:48:47nivdom96: yes, you can call it in the routes. the point of the middleware is to reduce boilerplate, since it runs automatically for all requests
17:48:47fredrik92When I write my makefile (or visual studio project template) for Nim, do you think I should just call nim for the code generation (with the -c flag) and then use Visual Studio makefiles / projects to set the C compiler flags?
17:48:58Araqdom96: fyi you broke the testsuite. please fix it.
17:49:08dom96Araq: Yeah. I know.
17:49:36dom96Araq: Not sure how this pragma works, where does nimTableGet get defined?
17:50:58dom96niv: I see. Make an issue for it :)
17:51:18Araqdom96: nowhere, you compile via -d:nimTableGet to activate it
17:51:38Araqbut yeah we should name it -d:nimOldJson ?
17:51:47Araqor something like that.
17:52:41*yglukhov joined #nim
17:52:54dom96right, and then by compiling with the define you get the old behaviour back?
17:53:17cheatfatedom96, middlewares made some complex tasks like session handling, json handling to be under the hood...
17:54:44nivyeah, auth & auth is another. you can keep your logic in one place that way; it prevents overlooking routes and similar mistakes, apart from reducing boilerplate
18:00:41yglukhovAraq: still no match with [key]. Gist updated: https://gist.github.com/yglukhov/ea40a8dbe495ce8fd84d36a69f5815b1
18:01:47Araqyglukhov: educated guess: you need to do a skipConv in the pattern matching process
18:02:10Araqin other words some internal conversion is produced that prevents it from matching
18:02:55nivdom96: https://github.com/dom96/jester/issues/60 as requested, made an issue. hope its clear what it should do. please let me know if there's more you need from me
18:03:01yglukhovTo put it in other words. Can we revert the breaking change for now until we have an adequate alternative?
18:03:32yglukhovcc dom96
18:04:29dom96niv: looks good
18:05:14dom96yglukhov: I'd rather leave the change in, this is just an optimisation right?
18:05:50yglukhovyup
18:08:22Araqyglukhov: patterns.nim, line 131 let n = skipConv n
18:08:32Araqor something like that, please fix it
18:09:13yglukhovcool. i feel like i'm an oldschool lucasarts quest game hero! :D
18:16:22*boopsiesisaway is now known as boopsies
18:25:05*Demon_Fox quit (Quit: Leaving)
18:34:28*wade_ joined #nim
18:34:31fredrik92why does nimsuggest look exactly like the nim executable??
18:37:56Araqbecause it uses the whole compiler to do its work?
18:38:55fredrik92ok, but `nimsuggest --help` outputs the same as `nim --help`
18:39:06*vendethiel joined #nim
18:39:35Araqyeah. kind of unfortunate :P
18:39:48Araqit outputs something different without the --help
18:39:58fredrik92ah! :D
18:47:26*wade_ quit (Quit: Leaving)
19:31:48yglukhovAraq: are there any tests for term rewriting? Your suggestion works, but a test would be nice right?
19:32:15*brson joined #nim
19:35:53yglukhovah ok found some.
19:39:08Araqif you enjoy it, you can think about what nkStmtListExpr implies for TR matchings
19:39:52Araqfoo((x; y; a), b) matches foo(a, b) ?
19:40:13Araqbut then this opt would remove the (x; y) part?
19:40:39Araqso you need to write it to (x; y; foo(a, b))
19:45:19*brson quit (Quit: leaving)
19:50:17*enthus1ast joined #nim
19:50:25Araq*rewrite
19:55:35*BitPuffin quit (Read error: Connection reset by peer)
20:05:40*yglukhov quit (Remote host closed the connection)
20:19:09*brson joined #nim
20:19:25*yglukhov joined #nim
20:19:45*yglukhov quit (Remote host closed the connection)
20:28:30*yglukhov joined #nim
20:33:34*chrisheller quit (Remote host closed the connection)
20:45:09*Trustable quit (Remote host closed the connection)
20:53:25dom96github is having some serious issues today
20:58:36*McSpiros joined #nim
20:59:18dom96hello McSpiros
20:59:37McSpirosHello Dominic!
21:03:35dom96McSpiros: what brings you to #nim? :)
21:04:00McSpirosI started looking at Nim
21:04:09McSpirosreally liked it
21:04:09gokrOk, idiotic question: I should be able to define -d:release in the .cfg file, right? No matter what I do it keeps making me a fat file.
21:04:29McSpirosactually i was just reading nim in action :)
21:06:20McSpirosand i decided to come take a look at the irc channel, say hello
21:08:13gokrOoohhh... perhaps... ok, so... nim seems to read the global cfg first (and in it, it sets various things depending on the value of "release") - and its after that it reads my local cfg (too late!).
21:08:46gokrThat's why it behaves differently if I give it -d:release on the command line, or in the cfg. Hmmm.
21:09:10gokrIs this universally known? Am I daft?
21:10:22dom96McSpiros: That's brilliant. What are your thoughts about the book so far?
21:10:46dom96gokr: it's a common gotcha ;)
21:10:46McSpirosIt's really nice
21:11:05gokrdom96: Ok, "good" ;)
21:11:15dom96gokr: so much so that it may just be worth creating an issue for on Github to discuss it.
21:11:38dom96McSpiros: Glad you like it :D
21:11:39McSpirosit's got a nice learning curve
21:12:04McSpiroskeeps things challenging (for my level at least :) )
21:12:48dom96That's nice to hear. I'm currently working on corrections based on reader feedback from chapter 1 to 3, so I will hopefully make it even better :)
21:13:21McSpiroslooking forward to it
21:13:28McSpirosI am still at chapter 3
21:13:40*boopsies is now known as boopsiesisaway
21:14:39McSpirostrying to wrap my head around async stuff
21:21:09*thotypous quit (Ping timeout: 276 seconds)
21:22:44dom96Yeah, it is a bit tough to understand at first. Of course the best way is to write some software using it, hence the large-ish example in the book.
21:28:46McSpirosI really appreaciate that you used a real, working example
21:29:14McSpirosmaybe taka a little more time to get all the ins and outs of the example
21:29:34McSpirosbut i believe you learn more this way
21:32:04dom96yeah, I mainly picked it because I thought it would be fun. Before I learned how sockets work I always wanted to be able to write something like that for fun.
21:36:42McSpiroslearning more about sockets is a bonus in that example too
21:41:44*Demon_Fox joined #nim
21:42:06*krux02 joined #nim
21:42:39*krux02 quit (Read error: Connection reset by peer)
21:43:27*krux02 joined #nim
21:44:13*krux02 quit (Read error: Connection reset by peer)
21:44:57*krux02 joined #nim
21:45:43*krux02 quit (Read error: Connection reset by peer)
21:46:44*krux02 joined #nim
21:46:47*krux02 quit (Read error: Connection reset by peer)
21:47:40*krux02 joined #nim
21:47:48McSpirosGotta go
21:48:01McSpirosHey Dom, nice talking to you!
21:48:27dom96See you McSpiros!
21:48:27*krux02 quit (Read error: Connection reset by peer)
21:48:47*McSpiros quit (Quit: Page closed)
21:49:19*irrequietus quit ()
21:49:45*krux02 joined #nim
21:49:57*krux02 quit (Read error: Connection reset by peer)
21:50:45*krux02 joined #nim
21:51:08*krux02 quit (Read error: Connection reset by peer)
21:52:25*krux02 joined #nim
21:52:36*krux02 quit (Remote host closed the connection)
21:53:47Araqgokr: yeah the config system should REALLY catch that.
21:53:54Araqit's hard to fix but easy to report
21:54:19gokryeah
22:07:21cheatfateAraq, i think there some problems in exception handling on windows when "threads:on"
22:08:44cheatfateAraq, https://gist.github.com/cheatfate/66eec463b8f286288d41ea4988bdf823
22:12:09dom96Araq: Happy with this? https://github.com/nim-lang/Nim/compare/tester_ignore_output
22:13:35cheatfateAraq, and this error only happens with gcc, vcc is working good
22:15:18Araqdom96: no because I don't understand it.
22:15:48Araqcheatfate: didn't we fix thread local storage with GCC?
22:16:01Araqtried with --tlsEmulation:off ?
22:16:12cheatfatewait a moment i will try
22:16:53cheatfateAraq, it helps
22:17:05AraqactionRunNoSpec ... hmmm I guess your code is fine, dom96
22:17:25cheatfateAraq, with --tlsEmulation:off it works without any exceptions
22:17:29dom96ok :P
22:24:48cheatfateAraq, do i need to make an Issue on this?
22:27:04Araqcheatfate: yes.
22:27:29Araqwould be nice if --tlsEmulation can default to 'off' on win/Gcc now.
22:27:39Araqthis would make this a "minor issue".
22:28:17*chrisheller joined #nim
22:39:27*elrood quit (Quit: Leaving)
22:43:34*yglukhov quit (Remote host closed the connection)
22:45:19*yglukhov joined #nim
22:45:43*yglukhov quit (Remote host closed the connection)
22:53:27*vendethiel quit (Ping timeout: 276 seconds)
23:01:34*BitPuffin|osx joined #nim
23:06:50*Matthias247 quit (Read error: Connection reset by peer)
23:09:23*darkf joined #nim
23:10:30*saml_ joined #nim
23:17:56*PMunch quit (Read error: Connection reset by peer)
23:48:06*Jesin quit (Quit: Leaving)
23:52:53*Jesin joined #nim