| 00:00:33 | dom96 | In case anybody missed it: http://nim-lang.org/news/2016_06_23_launching_the_2016_nim_community_survey.html | 
| 00:02:35 | * | saml_ joined #nim | 
| 00:03:26 | vktec | def-: Thanks, but my regex uses a _lot_ of double quotes, so """ is easier. I'll use raw strings for my other regexes though | 
| 00:06:07 | vktec | def-: Also, does the `re"foo""bar"` rather than `re(r"foo""bar")` syntax work with nre? | 
| 00:14:24 | def- | vktec: yes | 
| 00:14:35 | edub4rt | I know that manually canceling futures is not supported yet, however if I close an async socket, will it cancel all IO futures related to the socket? | 
| 00:18:47 | dom96 | edub4rt: I don't think so. For example, if you've got a pending recv() you might get an empty string back. | 
| 00:22:05 | edub4rt | dom96: I'm dealing with a case where the pending recv() never returns, even after I close the socket | 
| 00:22:16 | vktec | def-: Thanks | 
| 00:22:31 | * | zodiak joined #nim | 
| 00:23:16 | edub4rt | dom96: for the current implementation is this behavior correct or is something wrong? | 
| 00:24:57 | dom96 | edub4rt: good question, i'm not sure. | 
| 00:27:10 | dom96 | I think it's fair to assume that any pending socket operation should finish eventually with either an exception or a result. | 
| 00:28:45 | * | GangstaCat quit (Quit: Leaving) | 
| 00:34:58 | edub4rt | dom96: I've create a simple async UDP server, call an await recvFrom in an async routine, then closed the socket, the await never finished, waited more than 300 seconds, I'll investigate further | 
| 00:37:12 | * | fredrik92 quit (Ping timeout: 276 seconds) | 
| 00:51:48 | * | ddl_smurf quit (Quit: ddl_smurf) | 
| 01:09:18 | * | ddl_smurf joined #nim | 
| 01:12:01 | * | ddl_smurf quit (Remote host closed the connection) | 
| 01:15:40 | * | FreezerburnV_ joined #nim | 
| 01:18:09 | * | brson quit (Quit: leaving) | 
| 01:30:45 | * | yglukhov joined #nim | 
| 01:33:35 | * | abruanese quit (Ping timeout: 240 seconds) | 
| 01:33:45 | * | FreezerburnV_ quit (Ping timeout: 246 seconds) | 
| 01:35:03 | * | yglukhov quit (Ping timeout: 244 seconds) | 
| 01:43:09 | * | FreezerburnV_ joined #nim | 
| 01:43:39 | * | zds joined #nim | 
| 01:43:48 | * | brson joined #nim | 
| 01:46:24 | * | chemist69 quit (Ping timeout: 272 seconds) | 
| 01:52:41 | * | FreezerburnV_ quit (Remote host closed the connection) | 
| 01:59:32 | * | chemist69 joined #nim | 
| 02:00:05 | * | fredrik92 joined #nim | 
| 02:00:06 | zds | Is there a way to echo the type of a value? | 
| 02:03:18 | kier | type(x) gives you a typedesc representing the type of the value x | 
| 02:03:36 | kier | i think i've seen somewhere you can do type(x).name, can't see it in the docs though | 
| 02:06:15 | * | fredrik92 quit (Ping timeout: 276 seconds) | 
| 02:10:09 | zds | I know about the typedescs, but I can't echo the damn things. | 
| 02:12:26 | zds | ah - `name` comes from typetraits. | 
| 02:12:45 | zds | then you can echo it. | 
| 02:18:14 | edub4rt | dom96: I could not find the root cause of the problem, I've created issue #4405 regarding that, pending recv/accept futures don't fail after closing a socket | 
| 02:28:10 | * | zodiak_ joined #nim | 
| 02:32:12 | * | zodiak quit (Ping timeout: 260 seconds) | 
| 02:33:04 | * | yglukhov joined #nim | 
| 02:33:24 | * | brson quit (Quit: leaving) | 
| 02:37:11 | * | yglukhov quit (Ping timeout: 240 seconds) | 
| 02:53:02 | * | saml_ quit (Remote host closed the connection) | 
| 02:56:42 | * | freezerburnV quit (Ping timeout: 260 seconds) | 
| 03:01:05 | * | freezerburnV joined #nim | 
| 03:09:35 | * | veganskaway is now known as vegansk | 
| 03:38:32 | * | Demon_Fox quit (Ping timeout: 244 seconds) | 
| 03:43:11 | * | Demon_Fox joined #nim | 
| 03:56:44 | * | fvs quit (Quit: Leaving) | 
| 04:07:53 | * | zodiak joined #nim | 
| 04:12:21 | * | zodiak_ quit (Ping timeout: 276 seconds) | 
| 04:28:36 | * | freezerburnV quit (Ping timeout: 276 seconds) | 
| 04:35:27 | * | Demon_Fox quit (Quit: Leaving) | 
| 04:43:15 | * | edub4rt quit (Remote host closed the connection) | 
| 05:33:30 | * | zds quit (Quit: Connection closed for inactivity) | 
| 05:35:13 | * | yglukhov joined #nim | 
| 05:38:56 | * | vqrs_ quit (Ping timeout: 244 seconds) | 
| 05:39:27 | * | yglukhov quit (Ping timeout: 244 seconds) | 
| 05:40:07 | * | vqrs joined #nim | 
| 05:40:59 | * | Varriount quit (Disconnected by services) | 
| 05:40:59 | * | Varriount_ joined #nim | 
| 05:53:22 | * | endragor joined #nim | 
| 06:19:00 | * | endragor_ joined #nim | 
| 06:22:03 | * | akamaus quit (Ping timeout: 264 seconds) | 
| 06:22:33 | * | endragor quit (Ping timeout: 240 seconds) | 
| 06:38:45 | * | arnetheduck joined #nim | 
| 06:49:57 | * | endragor_ quit (Remote host closed the connection) | 
| 06:50:27 | * | endragor joined #nim | 
| 06:50:32 | * | endragor quit (Remote host closed the connection) | 
| 06:51:01 | * | endragor joined #nim | 
| 06:51:04 | * | endragor quit (Remote host closed the connection) | 
| 06:51:33 | * | endragor joined #nim | 
| 07:01:31 | * | endragor quit (Remote host closed the connection) | 
| 07:02:39 | * | endragor joined #nim | 
| 07:06:19 | * | zodiak_ joined #nim | 
| 07:09:33 | * | zodiak quit (Ping timeout: 258 seconds) | 
| 07:12:30 | * | endragor quit (Remote host closed the connection) | 
| 07:20:20 | * | endragor joined #nim | 
| 07:20:44 | * | arnetheduck quit (Ping timeout: 250 seconds) | 
| 07:22:07 | vegansk | Araq, hi! Can you look at this PR please: https://github.com/nim-lang/Nim/pull/4398. | 
| 07:29:25 | * | yglukhov joined #nim | 
| 07:32:01 | * | Trustable joined #nim | 
| 07:33:59 | * | yglukhov quit (Ping timeout: 244 seconds) | 
| 07:34:15 | * | arnetheduck joined #nim | 
| 07:35:29 | * | PMunch joined #nim | 
| 07:45:16 | vegansk | Araq, thanks. Updated the comments. Also I have a question. Why compareTypes uses sameTypeAux and not typeRel? I think that's why it can't find matching in the issue 88 | 
| 07:46:05 | * | ldleworker is now known as ldlework | 
| 07:48:43 | * | euantor joined #nim | 
| 07:48:44 | * | euant joined #nim | 
| 07:52:25 | * | brechtm joined #nim | 
| 07:58:04 | Araq | typeRel deals with type variables | 
| 07:58:10 | Araq | compareTypes doesn't. | 
| 08:01:04 | vegansk | Araq, so can I add custom logic for generics to compareTypes? | 
| 08:01:26 | vegansk | using isGenericSubtype | 
| 08:01:50 | Araq | why is that required? compareTypes should deal with concrete types | 
| 08:03:19 | vegansk | Because now test from issue 88 fails with "Error: conversion from ref TGen[system.string] to Ty is invalid" | 
| 08:03:56 | Araq | type conversions already call typeRel | 
| 08:06:25 | * | desophos quit (Read error: Connection reset by peer) | 
| 08:07:03 | vegansk | I can't find it in proc semConv(c: PContext, n: PNode): PNode :-( Ok, need to dig deeper. And what do you think about PR. Can it be merged? | 
| 08:11:09 | * | bjz joined #nim | 
| 08:17:41 | Araq | semConv needs to call typeRel then, but don't touch compareTypes | 
| 08:19:00 | vegansk | Ok! | 
| 08:21:37 | * | bjz quit (Ping timeout: 260 seconds) | 
| 08:27:09 | * | bjz joined #nim | 
| 08:38:11 | * | bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) | 
| 08:46:40 | * | bjz joined #nim | 
| 08:49:24 | * | yglukhov joined #nim | 
| 08:54:41 | Araq | vegansk: I will merge the PR tonight, ok? need to do some tests on my own | 
| 08:56:15 | vegansk | Araq, Ok! Thanks. Meanwhile I'll try to resolve the rest of issue 88 in another PR because it's another problem | 
| 09:02:45 | Araq | nice. | 
| 09:05:42 | * | bjz_ joined #nim | 
| 09:07:08 | * | bjz quit (Ping timeout: 244 seconds) | 
| 09:20:11 | euantor | Araq, I finally got round to making that PR with the modified strutils isNilorEMpty and strutils.isNilOrWhitespace methods. I also edited strutils.isSpace slightly, hopefully that's acceptable. I wasn't 100% sure on how you do tests in the stdlib, so I added a couple of asserts in strutils and some in tstrutil.nim. Hopefully that's correct | 
| 09:33:40 | * | endragor quit (Remote host closed the connection) | 
| 09:33:52 | * | endragor joined #nim | 
| 09:36:47 | * | chemist69 quit (Ping timeout: 250 seconds) | 
| 09:37:08 | * | chemist69 joined #nim | 
| 09:51:29 | * | filcuc joined #nim | 
| 09:51:56 | * | GangstaCat joined #nim | 
| 09:52:46 | chemist69 | Hi, I am still getting started with Nim (coming mainly from Python) and liking it more and more. | 
| 09:52:57 | chemist69 | I am using it only on Linux, but want to write some programs that slso my Windows-using colleagues should be able to run. So I used the cross-compilation example from def- in his excellent blog post on Writing a 2D Platform Game in Nim to compile one of my scripts on Linux for Windows and it worked flawlessly. I was even able to cross-compile the controllgallery libui example from Araq. I am duely impressed and | 
| 09:52:59 | chemist69 | just wanted to share my excitement. | 
| 09:53:16 | dom96 | chemist69: awesome :D | 
| 09:54:22 | cheatfate | dom96, i think https://github.com/nim-lang/Nim/issues/4405 this will be hard bug... | 
| 10:00:58 | chemist69 | dom96: yes, I am really impressed. It looks like Nim is really one of nicest options for cross-platform devlopment. I love Python, but using it would mean to install the interpreter on every machine where a script should be run, and this is often difficult (for us, it at least requires a call to IT). I even looked into Kotlin, which is a nicer alternative to Java and the JVM is installed on all Windows machines | 
| 10:01:00 | chemist69 | here, but I really would rather avoid using it (The syntax is quite nice, though and very Swift-like). | 
| 10:01:48 | PMunch | chemist69, that's great! Another great thing is that if you even have something you want to package to a source-based distro you can compile to C so your package won't even depend on Nim :) | 
| 10:02:19 | chemist69 | Yes, that's true! | 
| 10:02:51 | dom96 | cheatfate: indeed. | 
| 10:03:15 | dom96 | chemist69: That's precisely why I stopped using Python and started using Nim in the first place :) | 
| 10:03:37 | dom96 | 236 responses for the Nim community survey so far! | 
| 10:03:44 | chemist69 | dom96: I am starting to understand... :-) | 
| 10:03:49 | PMunch | chemist69, I wrote a Gtk program in Python once by accident (didn't really think it through) and when it came to deploy time I ended up creating a portable python install with a portable Gtk install and drop my script in a folder.. The program was a couple kilobytes, the end-product was a couple megabytes because of all the portable dependencies.. | 
| 10:03:52 | dom96 | For anyone that missed it: http://nim-lang.org/news/2016_06_23_launching_the_2016_nim_community_survey.html | 
| 10:04:02 | PMunch | dom96, oh nice! | 
| 10:04:17 | PMunch | It seems like Nim has gained some interest lately | 
| 10:04:47 | PMunch | My post on TinyWM got ~1500 page visits after I posted it on r/programming | 
| 10:05:53 | chemist69 | PMunch: Yeah, this is another thing. For Python cross-platform GUI apps, I have used Tk so far, because it is the easiest option on Windows, but man, it is ugly on Linux (even with the new Ttk). | 
| 10:06:41 | PMunch | Gtk is actually pretty nice cross platform, but it does require the end user to install Gtj | 
| 10:06:44 | PMunch | Gtk* | 
| 10:07:38 | PMunch | Which isn't a problem in the Linux world (package managers for the win) but on Windows this means that you need to bundle an installer or write a script that goes and downloads the latest version requiring an internet connection.. | 
| 10:07:45 | chemist69 | Therefore I really see the potential in libui. It looks native on every platform, because it Is native. | 
| 10:08:00 | vegansk | chemist69. Did you try IUP. It's nice, small, crossplatform and native. See: https://github.com/vegansk/nimtests/blob/master/stdlib/iup/tutorial/ex3_4.nim | 
| 10:09:09 | chemist69 | vegansk: no, but I definitely will have a look. Thanks. | 
| 10:09:18 | PMunch | Oh wow, didn't know of libui. It looks great! | 
| 10:09:52 | chemist69 | PMunch: and Araq already wrote a Nim wrapper! | 
| 10:10:06 | PMunch | Yeah I saw it listed in the wrapper section :) | 
| 10:10:20 | PMunch | vegansk, what's the benefit of iup? | 
| 10:11:42 | vegansk | PMunch. Native controls, small - 900Kb overhead on windows. | 
| 10:12:08 | vegansk | Where is libui wrapper? | 
| 10:12:11 | PMunch | Got this on reddit: "As an aside: any idea on how Nim metaprogramming features fare when compared against D lang?" Anyone has anything to pitch in or a good article? | 
| 10:12:46 | chemist69 | vegansk: https://github.com/nim-lang/ui | 
| 10:13:00 | PMunch | https://github.com/nim-lang/ui | 
| 10:13:30 | chemist69 | I was faster, yes! ((fistpump)) | 
| 10:13:46 | * | arnetheduck quit (Ping timeout: 252 seconds) | 
| 10:13:56 | PMunch | Damn it! | 
| 10:14:00 | vegansk | PMunch. Look at the benefits of Nim metaprogramming for java connection :-) https://github.com/vegansk/jbridge/blob/master/src/javaapi/containers.nim. and https://github.com/vegansk/jbridge/blob/master/tests/test_javaapi_containers.nim#L11-L25 | 
| 10:14:11 | vegansk | Thanks | 
| 10:14:41 | * | brechtm__ joined #nim | 
| 10:15:25 | PMunch | vegansk, what kind of sorcery is that! | 
| 10:15:26 | dom96 | PMunch: Awesome to see two Nim-related submissions on r/programming at the same time :D | 
| 10:16:15 | PMunch | And so far up as well :) | 
| 10:16:23 | vegansk | PMunch, very dark magic :-) I wish i saw something like that in D | 
| 10:16:54 | * | brechtm quit (Ping timeout: 260 seconds) | 
| 10:17:04 | PMunch | vegansk, but how does it work? Does it run a JVM and interface with it? | 
| 10:17:24 | * | arnetheduck joined #nim | 
| 10:17:29 | vegansk | PMunch, it uses JNI to connect to JVM | 
| 10:18:13 | vegansk | Here is the low level: https://github.com/vegansk/jbridge/blob/master/tests/test_jni_api.nim | 
| 10:19:20 | vegansk | Btw, don't use it until Araq merges https://github.com/nim-lang/Nim/pull/4398 | 
| 10:23:21 | vegansk | dom96, how many peoples already participated in survey? :-) | 
| 10:23:38 | dom96 | 242 | 
| 10:23:45 | dom96 | Trying to submit to HN again | 
| 10:24:02 | dom96 | *hint hint* :P | 
| 10:24:44 | * | vegansk is now known as veganskaway | 
| 10:29:32 | * | fredrik92 joined #nim | 
| 10:32:55 | * | arnetheduck quit (Ping timeout: 244 seconds) | 
| 10:39:56 | * | coffeepot joined #nim | 
| 10:55:31 | * | euant quit (Ping timeout: 240 seconds) | 
| 10:55:31 | * | euantor quit (Ping timeout: 240 seconds) | 
| 10:56:40 | * | Senketsu quit (Remote host closed the connection) | 
| 11:05:42 | * | euantor joined #nim | 
| 11:05:43 | * | euant joined #nim | 
| 11:26:33 | * | zama quit (Ping timeout: 276 seconds) | 
| 11:27:21 | * | zama joined #nim | 
| 11:30:02 | * | yglukhov_ joined #nim | 
| 11:31:05 | * | ephja joined #nim | 
| 11:32:15 | * | yglukhov quit (Ping timeout: 264 seconds) | 
| 11:33:50 | * | yglukhov_ quit (Remote host closed the connection) | 
| 11:34:26 | * | yglukhov joined #nim | 
| 11:46:18 | * | xet7 quit (Quit: Leaving) | 
| 12:01:22 | * | GangstaCat quit (Quit: Leaving) | 
| 12:19:49 | * | elrood joined #nim | 
| 13:06:58 | * | brechtm__ quit (Read error: Connection reset by peer) | 
| 13:07:04 | * | brechtm joined #nim | 
| 13:11:21 | dom96 | Araq: Ever heard of this? https://docs.google.com/document/d/1gCsFxXamW8RRvOe5hECz98Ftk-tcRRJcDFANj2VwCB0/edit | 
| 13:18:52 | * | couven92 joined #nim | 
| 13:23:33 | * | fredrik92 quit (Ping timeout: 276 seconds) | 
| 13:24:39 | * | PMunch quit (Remote host closed the connection) | 
| 13:30:55 | * | nsf quit (Quit: WeeChat 1.5) | 
| 13:31:11 | * | nsf joined #nim | 
| 13:46:02 | * | BitPuffin joined #nim | 
| 13:46:31 | Sembei | dom96: still no solution for this? https://github.com/nim-lang/nimble/issues/203 | 
| 13:47:32 | dom96 | Sembei: sorry, will reopen the issue | 
| 13:47:53 | Sembei | ok | 
| 13:48:09 | dom96 | Sembei: I suggest you try to work around it by not installing Nim via brew | 
| 13:48:31 | Sembei | git cloning and so? | 
| 13:48:35 | dom96 | yes | 
| 13:49:23 | Sembei | or maybe homebrew team can fix it? | 
| 13:57:41 | dom96 | Sembei: I don't think so | 
| 14:00:07 | * | edub4rt joined #nim | 
| 14:00:59 | * | PMunch joined #nim | 
| 14:01:25 | edub4rt | cheatfate: I commented on issue #4405 an example with recvFromInto | 
| 14:02:53 | edub4rt | I am currently stuck with the problem on that issue, I need some kind of workaround, I could not find any yet | 
| 14:04:01 | * | Varriount joined #nim | 
| 14:04:51 | euantor | @Sembei I somehow managed to get Nim + Nimble installed on my mac using Homebrew. It was a while back though (pre-0.13.0 if I remember correctly) | 
| 14:05:51 | * | Varriount_ quit (Ping timeout: 264 seconds) | 
| 14:06:31 | Sembei | euantor: if you remember how or if you can with current version let me know it | 
| 14:06:55 | euantor | I'll try installing it on my other mac tonight and write up some details | 
| 14:07:05 | Sembei | ok tyvm | 
| 14:11:03 | dom96 | edub4rt: I gave a possible solution in the comments, don't have time right now to attempt it sorry. | 
| 14:16:42 | edub4rt | dom96: okay, thanks I will try to implement it | 
| 14:24:17 | * | euant quit (Quit: Leaving) | 
| 14:24:17 | * | euantor quit (Quit: Leaving) | 
| 14:34:11 | * | nsf quit (Quit: WeeChat 1.5) | 
| 14:43:30 | * | couven92 quit (Ping timeout: 276 seconds) | 
| 14:46:09 | * | endragor quit (Ping timeout: 246 seconds) | 
| 14:47:30 | * | abruanese joined #nim | 
| 14:48:49 | * | Olixir joined #nim | 
| 14:56:36 | Olixir | Hi guys! What does Nim have for parallelism computing? | 
| 14:57:47 | PMunch | Threads! | 
| 14:58:39 | * | euantor joined #nim | 
| 14:59:48 | PMunch | hookrace.net/blog/writing-an-async-logger-in-nim/#adding-a-thread | 
| 14:59:54 | PMunch | Olixir ^ | 
| 15:00:02 | PMunch | There's some example threading in Nim for you | 
| 15:00:51 | * | Olixir left #nim (#nim) | 
| 15:10:46 | cheatfate | edub4rt, check github... | 
| 15:10:51 | cheatfate | i have found your problem | 
| 15:12:25 | cheatfate | but this is mostly selectors.nim problem not yours | 
| 15:12:43 | * | J3RN left #nim ("WeeChat 1.5") | 
| 15:14:34 | PMunch | Hmm, it says in the docs that channels are slow. How slow are they? | 
| 15:22:04 | * | Demon_Fox joined #nim | 
| 15:29:27 | * | PMunch quit (Quit: leaving) | 
| 15:30:09 | * | i9B joined #nim | 
| 15:35:07 | * | GangstaCat joined #nim | 
| 15:35:11 | edub4rt | cheatfate: regarding that issue did you get the message "got exception" or "received"? | 
| 15:35:46 | edub4rt | on windows | 
| 15:40:59 | cheatfate | Error: unhandled exception: No handles or timers registered in dispatcher. [ValueError] | 
| 15:43:29 | euantor | Regarding my earlier comment about Nim/Nimble on Homebrew, it's also now broken for me when installing | 
| 15:43:39 | euantor | My already installed version works, a fresh install does not | 
| 15:44:47 | euantor | Though making a symbolic link works | 
| 15:49:31 | euantor | sudo ln -s /usr/local/Cellar/nim/0.14.2/nim/lib /usr/local/lib/nim | 
| 15:49:46 | * | tautologico joined #nim | 
| 15:59:05 | * | coffeepot quit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client) | 
| 16:11:22 | cheatfate | dom96, you need to clear "High Priority" for https://github.com/nim-lang/Nim/issues/4405 | 
| 16:12:10 | cheatfate | because with current limits of asyncdispatch.nim for supplied sources, it works as expected... | 
| 16:19:08 | * | heretobang joined #nim | 
| 16:19:59 | * | yglukhov_ joined #nim | 
| 16:20:04 | * | michael_campbell joined #nim | 
| 16:23:14 | * | yglukhov quit (Ping timeout: 260 seconds) | 
| 16:24:28 | * | yglukhov_ quit (Ping timeout: 264 seconds) | 
| 16:24:44 | * | sp33der89 joined #nim | 
| 16:28:42 | * | pregressive joined #nim | 
| 16:30:43 | * | filcuc quit (Read error: Connection reset by peer) | 
| 16:31:58 | * | michael_campbell quit (Quit: michael_campbell) | 
| 16:32:15 | * | elrood quit (Quit: Leaving) | 
| 16:34:59 | * | brson joined #nim | 
| 16:41:09 | * | BitPuffin quit (Ping timeout: 276 seconds) | 
| 16:43:04 | * | BitPuffin joined #nim | 
| 16:45:37 | * | xet7 joined #nim | 
| 17:00:34 | * | brechtm quit (Read error: Connection reset by peer) | 
| 17:01:01 | * | brechtm joined #nim | 
| 17:03:45 | * | euantor quit (Remote host closed the connection) | 
| 17:05:23 | * | yglukhov joined #nim | 
| 17:06:34 | * | michael_campbell joined #nim | 
| 17:10:14 | * | ephja quit (Quit: WeeChat 1.5) | 
| 17:11:09 | * | euantor joined #nim | 
| 17:17:44 | * | nsf joined #nim | 
| 17:29:57 | * | BitPuffin quit (Ping timeout: 260 seconds) | 
| 17:35:17 | * | euantor quit (Remote host closed the connection) | 
| 17:40:55 | * | michael_campbell quit (Remote host closed the connection) | 
| 17:42:22 | * | michael_campbell joined #nim | 
| 17:44:51 | * | BitPuffin joined #nim | 
| 17:48:18 | * | EastByte quit (Quit: WeeChat 1.5) | 
| 17:50:03 | * | EastByte joined #nim | 
| 17:51:25 | * | TheLemonMan joined #nim | 
| 17:52:09 | * | mostworst joined #nim | 
| 17:53:28 | * | sp33der89 left #nim (#nim) | 
| 17:54:55 | * | EastByte_ joined #nim | 
| 17:54:55 | * | EastByte quit (Read error: Connection reset by peer) | 
| 17:57:04 | * | euantor joined #nim | 
| 18:09:31 | * | mostworst quit (Ping timeout: 240 seconds) | 
| 18:13:20 | * | brson quit (Quit: leaving) | 
| 18:13:33 | * | brson joined #nim | 
| 18:19:48 | Sembei | euantor: that worked for me as well | 
| 18:20:59 | euantor | It's a little bit hacky, but it works | 
| 18:22:38 | * | Senketsu joined #nim | 
| 18:28:42 | * | mostworst joined #nim | 
| 18:30:24 | * | yglukhov quit (Remote host closed the connection) | 
| 18:41:55 | * | BitPuffin quit (Remote host closed the connection) | 
| 18:57:54 | * | euantor quit () | 
| 19:03:09 | * | mostworst quit (Ping timeout: 250 seconds) | 
| 19:09:14 | * | miere joined #nim | 
| 19:10:28 | miere | sup, people, quick question: is stuff like this valid in Nim? | 
| 19:10:30 | miere | seq[tuple[genre: string, match: range[1..100]]] | 
| 19:14:34 | * | michael_campbell quit (Quit: My Mac has gone to sleep. ZZZzzz…) | 
| 19:19:00 | Araq | miere: why wouldn't it? | 
| 19:20:05 | miere | getting weird error when trying to add tuple to sequence | 
| 19:21:16 | miere | Araq: about type mismatch | 
| 19:21:38 | Araq | pass the seq by 'var' | 
| 19:24:00 | miere | Araq: please take a look: https://gist.github.com/miere43/70a785331130224bf57516ff400f3f77 | 
| 19:25:16 | miere | for some reason value of '50' is not in range of 1..100 | 
| 19:25:58 | * | gmpreussner quit (Ping timeout: 252 seconds) | 
| 19:26:48 | * | gmpreussner joined #nim | 
| 19:28:22 | miere | Araq: works if manually cast to range[1..100] --- result.add((genre: "abcd", match: cast[range[1..100]](50))) | 
| 19:28:50 | Araq | oh yeah, the type conversion relation doesn't list to tuples in general | 
| 19:29:08 | Araq | btw use a type conversion, not a cast | 
| 19:29:19 | miere | how? ._. | 
| 19:29:33 | miere | range[1..100](50) ? | 
| 19:31:46 | * | michael_campbell joined #nim | 
| 19:33:09 | michael_campbell | Have you tried it and it failed, or haven't tried it? | 
| 19:34:12 | miere | michael_campbell: failed | 
| 19:34:36 | michael_campbell | =\   Seems like it should be valid.  I assume the tuple by itself is ok? | 
| 19:35:00 | miere | getting invalid indentation error, lol | 
| 19:35:23 | michael_campbell | in that one line? | 
| 19:35:32 | miere | oh no, everything works, thats just me being stupid | 
| 19:35:41 | miere | forget about some bracket | 
| 19:35:44 | miere | forgot* | 
| 19:36:10 | michael_campbell | I love, and hate, those types of errors. | 
| 19:46:30 | * | yglukhov joined #nim | 
| 19:54:28 | * | michael_campbell quit (Quit: My Mac has gone to sleep. ZZZzzz…) | 
| 19:58:10 | * | michael_campbell joined #nim | 
| 19:59:11 | * | mostworst joined #nim | 
| 20:03:22 | * | heretobang quit (Ping timeout: 250 seconds) | 
| 20:14:27 | * | gmpreussner quit (Read error: Connection reset by peer) | 
| 20:17:20 | * | gmpreussner joined #nim | 
| 20:21:06 | * | brson quit (Read error: Connection reset by peer) | 
| 20:21:40 | * | brson joined #nim | 
| 20:34:52 | * | couven92 joined #nim | 
| 20:50:34 | * | PMunch joined #nim | 
| 21:03:50 | * | euantor joined #nim | 
| 21:04:08 | * | enquora joined #nim | 
| 21:08:55 | * | brson quit (Read error: Connection reset by peer) | 
| 21:14:24 | * | brson joined #nim | 
| 21:16:34 | * | euantor quit (Remote host closed the connection) | 
| 21:30:13 | * | TheLemonMan quit (Quit: "It's now safe to turn off your computer.") | 
| 21:31:39 | * | mostworst quit (Ping timeout: 264 seconds) | 
| 21:31:45 | * | disconnected joined #nim | 
| 21:31:51 | disconnected | hello, does nimdoc support html entities somehow? | 
| 21:40:38 | * | freevryheid joined #nim | 
| 21:41:45 | freevryheid | tgif | 
| 21:41:47 | * | saml quit (Quit: Leaving) | 
| 21:41:55 | * | freevryheid is now known as fvs | 
| 21:45:32 | cheatfate | Araq, hi, how about my brand new ioselectors.nim pr? | 
| 21:47:42 | * | couven92 is now known as fredrik92 | 
| 21:55:57 | * | yglukhov quit (Read error: Connection reset by peer) | 
| 21:56:29 | * | yglukhov joined #nim | 
| 21:56:33 | * | regtools joined #nim | 
| 22:01:16 | dom96 | disconnected: possibly, try `.. html::` then put the HTML below indented by two spaces. | 
| 22:11:03 | * | miere quit (Read error: Connection reset by peer) | 
| 22:17:38 | * | akamaus joined #nim | 
| 22:17:53 | * | akaisora joined #nim | 
| 22:25:39 | * | benwbooth joined #nim | 
| 22:28:51 | * | benwbooth quit (Client Quit) | 
| 22:42:11 | * | enquora quit (Quit: enquora) | 
| 22:44:54 | * | codye joined #nim | 
| 22:52:07 | * | lucus16 joined #nim | 
| 22:53:11 | * | lucus16 quit (Client Quit) | 
| 22:58:13 | * | namnguyen quit (Remote host closed the connection) | 
| 22:59:40 | * | brson quit (Read error: Connection reset by peer) | 
| 23:03:45 | * | brson joined #nim | 
| 23:06:14 | PMunch | Hmm, I've got a *char which I've passed to a c function to get something back. How can I print the contents knowing the length? | 
| 23:19:28 | * | Demos joined #nim | 
| 23:24:47 | Araq | PMunch: good question, I don't think it gets simpler than: | 
| 23:24:56 | Araq | var x = newString(len) | 
| 23:25:15 | Araq | copyMem(addr(x[0]), thecstring, len) | 
| 23:25:18 | Araq | echo x | 
| 23:26:39 | PMunch | Hmm, that's fair | 
| 23:27:31 | Araq | PRs welcome | 
| 23:27:53 | * | pregressive quit (Remote host closed the connection) | 
| 23:28:47 | PMunch | Araq, by the way. I have other kinds of data as well. Right now an array of clong | 
| 23:28:54 | PMunch | I'm passing in a double pointer | 
| 23:29:24 | PMunch | Which points to unknown data. This data is defined by another field passed in as a pointer | 
| 23:29:38 | PMunch | Along with a length that's passed in as a pointer | 
| 23:30:11 | PMunch | So using the length, the type (inferred from the return of the argument), and the pointer to some kind of data. How would you access that? | 
| 23:30:40 | PMunch | arrays can't be created on runtime, so they are ruled out | 
| 23:31:25 | PMunch | I guess some pointer magic is possible by creating a seq and in a loop over the length do some pointer magic (how?) to access the fields and adding it to the seq | 
| 23:36:03 | PMunch | Hmm, I tried this: | 
| 23:36:15 | PMunch | for i in 0..<cast[int](len): | 
| 23:36:16 | PMunch |   echo cast[ptr int](cast[int](list.addr)+i*4)[] | 
| 23:36:27 | PMunch | But it seems to give me bogus data.. | 
| 23:37:29 | PMunch | (It's an array of c longs by the way, that's why I do i*4) | 
| 23:45:40 | Araq | arrays are possible:   ptr array[10_000_000, clong] | 
| 23:45:44 | * | Trustable quit (Remote host closed the connection) | 
| 23:45:57 | Araq | that's what I use. you can also use .unchecked arrays but meh | 
| 23:48:51 | Demos | it seems {.push cdecl.} does not work on procedural types | 
| 23:49:04 | Demos | is {.callconv: cdecl.} still a thing? | 
| 23:50:00 | PMunch | Araq, allocating room for 10,000,000 clong on the heap isn't a bad idea? | 
| 23:50:33 | Araq | it's a pointer to an array | 
| 23:50:40 | Araq | it doesn't allocate anything | 
| 23:50:53 | Araq | the array size is a lie to make the bounds checking shut up | 
| 23:51:03 | Araq | .unchecked does something similar | 
| 23:51:27 | Araq | Demos: that's actually a feature, push only affects routines | 
| 23:51:44 | Araq | {.callconv: cdecl.}  is indeed what should be used instead | 
| 23:52:20 | Demos | sqlite3ext.nim(47, 11) Error: invalid pragma: callconv: cdecl | 
| 23:57:36 | PMunch | Oooh | 
| 23:57:41 | PMunch | That makes sense :P |