<< 26-06-2017 >>

00:06:28*bahtiyar quit (Ping timeout: 260 seconds)
00:32:08*chemist69 quit (Ping timeout: 240 seconds)
00:34:48*chemist69 joined #nim
00:37:44*ipjk quit (Read error: Connection reset by peer)
00:41:45*jinshil joined #nim
00:48:10*daaf joined #nim
01:21:20*daaf quit (Ping timeout: 246 seconds)
01:33:10*aerx_ joined #nim
01:34:56*aerx quit (Ping timeout: 240 seconds)
01:35:55*chemist69 quit (Ping timeout: 246 seconds)
01:36:33*user0_ joined #nim
01:38:32*jsgrant quit (Quit: Peace Peeps. o/ If you need me asap, message me at msg([at])jsgrant.io & I'll try to get back to you within 24-36 hours.)
01:48:31*chemist69 joined #nim
01:54:41*bahtiyar joined #nim
02:40:00*dddddd quit (Remote host closed the connection)
02:40:17*pilne quit (Quit: Quitting!)
02:57:38*girvo joined #nim
02:58:22girvoHey all
03:01:28girvoQ: for a generated header file for some Objects that are {.exportc.}-ed, are those structs opaque? I can't seem to access their properties from C, so I'm guessing that's the case
03:02:16*bahtiyar quit (Ping timeout: 260 seconds)
03:24:17*bahtiyar joined #nim
03:31:55girvoAraq: https://github.com/nim-lang/Nim/issues/1189 "The header switch will be removed" -- so will we need to write our own headers instead? Any good examples for it anywhere?
03:41:35*jackkv is now known as jackv
03:51:45*NotSpooky quit (Quit: Leaving)
04:40:29*jsgrant joined #nim
04:40:38*jszymanski joined #nim
04:47:36*user0_ quit (Read error: Connection reset by peer)
04:49:05*girvo quit (Ping timeout: 240 seconds)
04:51:55*jsgrant quit (Ping timeout: 246 seconds)
04:58:32*vlad1777d joined #nim
04:58:36*user0_ joined #nim
05:49:51*aerx_ quit (Quit: WeeChat 1.8)
05:56:39*yglukhov joined #nim
06:01:45*yglukhov quit (Ping timeout: 276 seconds)
06:11:27*Vladar joined #nim
06:13:34*bahtiyar quit (Ping timeout: 268 seconds)
06:13:55*Arrrr joined #nim
06:15:38*girvo joined #nim
06:21:41*Snircle quit (Quit: Textual IRC Client: www.textualapp.com)
06:23:26*user0_ quit (Ping timeout: 268 seconds)
06:27:14*girvo quit (Quit: leaving)
06:27:42*arecacea1 quit (Remote host closed the connection)
06:28:19*arecacea1 joined #nim
06:37:39*couven92 joined #nim
06:41:56*nsf joined #nim
06:52:53*xet7 joined #nim
07:08:46*bahtiyar joined #nim
07:22:55*bahtiyar quit (Ping timeout: 240 seconds)
07:26:31*yglukhov joined #nim
07:36:57*bahtiyar joined #nim
07:37:02*bahtiyar quit (Read error: Connection reset by peer)
07:41:57*bahtiyar joined #nim
07:42:20*bahtiyar quit (Read error: Connection reset by peer)
07:46:58*bahtiyar joined #nim
07:46:59*bahtiyar quit (Read error: Connection reset by peer)
07:47:10*tankfeeder joined #nim
07:48:43*pontus joined #nim
07:49:53pontusHello!
07:51:02*tankfeeder quit (Client Quit)
07:52:04*bahtiyar joined #nim
07:52:13ArrrrWellcome pontus, we are glad you are back.
07:52:31*bahtiyar quit (Read error: Connection reset by peer)
07:57:37ArrrrIs it wise, in order to avoid cyclic import errors, to have a single gigantic module with dependant types? I'd like to know how people avoid this issue.
08:05:14pontusSorry Arrrr, I've never been here before. Someone probably got the same nick :P
08:06:20couven92Happy to oblige... pontus is sitting next to me in my office here... I am working hard in recruiting people around me to be part of Nim! :D
08:06:48couven92Now he only needs to be using Nim! :)
08:07:49ArrrrDo not worry, it was my generic response. Has more chances to success than to fail.
08:12:55*manjaro-kde5-- joined #nim
08:28:29*bahtiyar joined #nim
09:00:58*rokups joined #nim
09:02:56*jinshil quit (Quit: Good-bye!)
09:39:39*yglukhov quit (Remote host closed the connection)
09:45:36*yglukhov joined #nim
09:45:52*yglukhov quit (Remote host closed the connection)
09:46:26*yglukhov joined #nim
09:48:17*bahtiyar quit (Ping timeout: 255 seconds)
09:51:15*yglukhov quit (Ping timeout: 268 seconds)
09:54:57*bahtiyar joined #nim
09:55:34*vlad1777d quit (Ping timeout: 268 seconds)
09:56:28*yglukhov joined #nim
10:11:53*yglukhov quit (Remote host closed the connection)
10:13:17FromGitter<andreaferretti> @Arrrr you can either import a core module with types only or use include
10:13:24euantorI'll ask this again since there are usually more people here during the day. I asked on Saturday night but we never worked it out :)
10:13:33euantorhttps://www.irccloud.com/pastebin/XhRP9PmP/
10:14:26couven92euantor, isn't this becuase the fully qualified path for getTempDir is osproc.getTempDir ?
10:14:47couven92try that, does the error still persist? alternatively os.osproc.getTempDir?
10:14:53euantorShouldn't be: https://nim-lang.org/docs/os.html#getTempDir,
10:15:18euantorAnd it's a proper proc in `os`, not some magic export: https://github.com/nim-lang/Nim/blob/master/lib/pure/ospaths.nim#L531
10:15:39euantorAnd since it doesn't fail in `doc` but does in `doc2`, I think there's something more odd at play
10:15:48couven92oh... right, I meant ospaths!
10:16:10euantoroh, hm. Yeah that might be the problem
10:16:26euantorThe code itself works, it only fails when running doc2 which is weird
10:16:31couven92euantor, yeah, I think nim doc2 gets maximum confused since it documents recursively by imports
10:16:52couven92what happens if you omit the full qualification and just write getTempDir?
10:16:59euantorGet the same error
10:17:10euantorThe full qualification was an attempt to get aorund the error
10:17:25couven92I supposed as much...
10:17:34euantorYou're not meant to import ospaths as far as i know, but I might have to in this case
10:17:48euantorPerhaps I can wrap the import in a `when defined(doc)`
10:18:02couven92What if you don't import ospaths, but write: `os.ospaths.getTempDir`?
10:18:11euantorI'll try that now
10:18:13couven92Yeah, very ugly, but hey...
10:19:08*yglukhov joined #nim
10:19:54couven92Hmm, I get undeclared identifier: 'ospaths'
10:20:30euantorYeah, my system is failing before that, looks like Git has done something odd to my working copy
10:21:31euantorBut yeah, now I get that same error
10:23:31Arrrrandreaferreti yes, but i wonder if people actually deal with this or not. My core module would take many lines. I is hard to avoid type dependencies
10:27:48FromGitter<andreaferretti> I do it sometimes, never had a problem https://github.com/unicredit/linear-algebra/blob/master/linalg/private/types.nim https://github.com/unicredit/neurotic/blob/master/neurotic/core.nim
10:30:37*yglukhov quit (Remote host closed the connection)
10:31:54*yglukhov joined #nim
11:16:35Trioxinif given a choice to wrap a C library or a C implementation, I'm guessing I should choose the lib
11:17:27Trioxinhttps://github.com/BLAKE2/
11:17:53Trioxinso many .h files
11:20:39*rokups quit (Quit: Connection closed for inactivity)
11:25:43Trioxinhttps://github.com/BLAKE2/libb2/blob/master/src/blake2.h
11:25:52Trioxinblake2.h(131, 30) Error: ';' expected
11:37:14*Snircle joined #nim
11:50:47*arnetheduck joined #nim
12:17:28*bahtiyar quit (Ping timeout: 240 seconds)
12:23:25*bahtiyar joined #nim
12:41:05*bahtiyar quit (Ping timeout: 240 seconds)
12:50:31*Arrrr quit (Read error: Connection reset by peer)
12:50:49FromGitter<Varriount> Trioxin: Are you using c2nim?
12:57:21couven92Guys, config question: I have the following in my config: https://github.com/couven92/Nim/blob/niminst-android/config/nim.cfg#L99 But $HOME does not expand to the path to the home directory. Any suggestions how to rewrite this?
13:09:09*couven92 quit (Quit: Client disconnecting)
13:17:56*tankfeeder joined #nim
13:21:53*PMunch joined #nim
13:21:54*user0 quit (Read error: Connection reset by peer)
13:30:37*nightmared quit (Ping timeout: 246 seconds)
13:32:41*nightmared joined #nim
13:34:50*user02 joined #nim
13:40:12tankfeederhi
13:40:37tankfeederi'm looking library with multiple modules and files in it
13:40:45tankfeederwant to check nimble file for that
13:40:49tankfeederany hints ?
13:41:47tankfeedereverywhere is one file :)
13:45:05Vladarwhat do you mean by multiple modules and how nimble file would differ? E.g. does this counts? https://github.com/Vladar4/nimgame2
13:45:32tankfeederperfect, thanks
13:45:51*ofelas joined #nim
14:03:53*ipjk joined #nim
14:03:54*yglukhov quit (Read error: Connection reset by peer)
14:04:14*yglukhov joined #nim
14:12:08*krux02 joined #nim
14:12:25*couven92 joined #nim
14:29:28*PMunch quit (Quit: leaving)
14:52:54SentreenStupid question, but I can't seem to find any documentation on this. How does nimble interact with a `config.nims` file? e.g. if I define a version in `config.nims`, can nimble import this somehow?
14:53:19SentreenOr better put, can I import this in my `project.nimble` file?
15:10:34*couven92 quit (Ping timeout: 255 seconds)
15:20:44*yglukhov_ joined #nim
15:20:44*yglukhov quit (Read error: Connection reset by peer)
15:21:27*kunev quit (Ping timeout: 240 seconds)
15:22:06*kunev joined #nim
15:22:35subsetparkHow am I miswriting my test?
15:23:28subsetparkIt fails type checking on `let received` because it thinks that resp.body is a future... But I have it awaited https://www.irccloud.com/pastebin/K6TI4mhA/
15:24:02subsetparkUnless - is that a future in a future?
15:31:29*chemist69 quit (Ping timeout: 246 seconds)
15:32:39euantorYes, `resp.body` needs to be awaited itself
15:32:57euantor`let received = parseFloat(await resp.body)
15:33:58*Trustable joined #nim
15:39:34*tankfeeder quit (Quit: Leaving)
15:57:40*chrisheller quit (Remote host closed the connection)
15:58:24*chrisheller joined #nim
15:58:45*chemist69 joined #nim
15:59:17*yglukhov_ quit (Remote host closed the connection)
16:03:08subsetparkweird.
16:03:27subsetparkthat's just because getting the body of a response is another IO op?
16:06:23*yglukhov joined #nim
16:06:32euantorYeah, it was patched into a recent version
16:10:30*yglukhov quit (Ping timeout: 240 seconds)
16:23:11shmupis sortByIt not in the docs?
16:23:34shmupsortedByIt, ok
16:38:41*Jesin quit (Quit: Leaving)
16:53:20*yglukhov joined #nim
16:56:37*krux02 quit (Remote host closed the connection)
16:57:25*yglukhov quit (Ping timeout: 240 seconds)
17:09:07*gokr joined #nim
17:23:06*Demos joined #nim
17:29:27*aerx joined #nim
17:44:16*Trioxin quit (Ping timeout: 260 seconds)
17:52:23*Matthias247 joined #nim
17:58:53*pilne joined #nim
18:13:22*yglukhov joined #nim
18:21:59*adeohluwa joined #nim
18:25:40*ipjk quit (Quit: Leaving)
18:27:42*vlad1777d joined #nim
18:31:08*couven92 joined #nim
18:38:32*yglukhov quit (Remote host closed the connection)
18:44:10*nsf quit (Quit: WeeChat 1.7.1)
18:46:16*yglukhov joined #nim
18:50:31FromGitter<ephja> shouldn't verbosity:3 show the stack trace?
18:54:34*yglukhov quit (Remote host closed the connection)
19:14:53*yglukhov joined #nim
19:19:57*jszymanski quit (Quit: computer sleeps...)
19:26:06FromGitter<moigagoo> Hi! I'm using Nim with JS backend to manipulate datetimes. Part of it is parsing a string like 2017-06-26T18:18:18+04:00 into Time objects. ⏎ ⏎ I'm facing a very weird error, hope someone could help me with it. ⏎ ⏎ Parsing of this string fails with `invalid integer: 2017 [ValueError]`. I've dug into `times` module to see what's happening. The trace points to times.nim L848: ...
19:26:06FromGitter... [https://gitter.im/nim-lang/Nim?at=59515fcd76a757f808aaa96f]
19:29:06FromGitter<Varriount> @moigagoo Have you looked at the generated code? What character is is s[i]?
19:30:32FromGitter<Araq> @moigagoo seems to be a JS codegen bug then?
19:32:26FromGitter<moigagoo> @Varriount No, I haven't. I feel quite stupid now, seems like the most obvious starting point...
19:32:53FromGitter<moigagoo> @Araq I'll check he generated code and report back.
19:33:10Araqthank you
19:35:00yglukhovAraq: one more please: https://github.com/nim-lang/Nim/pull/6015 =)
19:35:36*ipjk joined #nim
19:36:54Araqyglukhov: why no fallback for windows?
19:37:46yglukhovAraq: there was no fallback initially. moveFileW does everything needed
19:37:54Araqok
19:38:21yglukhovoh no
19:38:30yglukhovjust went through msdn
19:38:34yglukhovgive me a sec
19:38:45yglukhovAraq
19:39:23yglukhovThe one caveat is that the MoveFile function will fail on directory moves when the destination is on a different volume.
19:39:28yglukhovso yeah, let me fix it
19:42:24Araqyeah I had something like this in the back of my head
19:43:25yglukhovAraq: can you help me find out the error code for this case? %)
19:43:48yglukhovcan anyone with windows here help?
19:45:42Araqhttps://msdn.microsoft.com/de-de/library/windows/desktop/aa365240(v=vs.85).aspx
19:45:51Araq use MOVEFILE_COPY_ALLOWED
19:46:03Araqand then you don't have to implement this logic
19:46:38yglukhovoh nice
19:58:02*ofelas quit (Remote host closed the connection)
19:58:05*couven92 quit (Ping timeout: 240 seconds)
19:58:41yglukhovdone
20:16:46*bjz joined #nim
20:19:48*nsf joined #nim
20:23:03*couven92 joined #nim
20:27:37*bjz_ joined #nim
20:29:08*bjz quit (Ping timeout: 260 seconds)
20:33:48*bjz_ quit (Ping timeout: 260 seconds)
20:34:32*bjz joined #nim
20:41:11*adeohluwa quit (Quit: Connection closed for inactivity)
20:41:39*vendethiel joined #nim
20:46:58*Ven joined #nim
20:47:21*Ven is now known as Guest27801
20:56:21*Vladar quit (Quit: Leaving)
20:56:42*Guest27801 is now known as Ven```
20:57:16*Ven``` quit (Read error: Connection reset by peer)
20:57:45*Ven_ joined #nim
20:57:57*bjz quit (Ping timeout: 240 seconds)
20:58:13*bjz_ joined #nim
21:16:41*Ven_ quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
21:16:53*xet7 quit (Quit: Leaving)
21:32:44*arnetheduck quit (Remote host closed the connection)
21:34:00*gokr quit (Ping timeout: 255 seconds)
21:36:44*nsf quit (Quit: WeeChat 1.7.1)
21:43:48*Demos quit (Ping timeout: 260 seconds)
21:44:13*Trustable quit (Remote host closed the connection)
21:57:57subsetparkAraq: is there any objection to implementing a version of `getEnv` that takes a default value?
21:58:19*adeohluwa joined #nim
22:00:07Araqsubsetpark: meh, getEnv returns "" if not exists, right? what's wrong with it
22:01:21subsetparkNothing at all - I just mean syntactic sugar over `if existsEnv: getEnv else: default`
22:01:51subsetparkVery often, environment variables will be used as runtime configuration, and it's good for such configs to have default values if the environment variable is not present
22:02:20subsetparkOne wouldn't have to change getEnv; just implement a version that takes two arguments
22:02:29yglukhovAraq: can you restart appveyor pls? https://github.com/nim-lang/Nim/pull/6015
22:03:59FromGitter<ephja> I'm thinking about how to allow access to variables at both compile time and run time, but I probably won't get anywhere with that lol
22:04:38Araqyglukhov: done
22:04:49yglukhovephja: https://github.com/yglukhov/nimx/blob/master/nimx/resource_cache.nim#L133
22:05:26Araqsubsetpark: why not patch getEnv then?
22:06:17subsetparkWhat do you mean?
22:06:51FromGitter<ephja> it's not quite the same thing, but yes I did consider file reading/writing as a workaround for certain things
22:07:37subsetparkephja - not sure if this is what you're talking about, but you can declare variables in a static block and then bind them to a constant in your runtime
22:07:48subsetparkhttp://blog.zdsmith.com/posts/compiletime-sort-in-nim.html
22:08:55FromGitter<ephja> I see. I didn't bother to read it before
22:09:34subsetparkAraq: do you mean, "Override getEnv in your own application code" or "Submit a PR changing the signature of getEnv to accept an optional default value"? If it's the first: because I think it would be useful in the stdlib; if it's the second: because I thought it would be less invasive/more backwards compatible. But I'm happy to do that too
22:10:26Araqproc getEnv*(key: string; ifMissing = ""): string
22:10:32Araq^ patch for stdlib.
22:11:03Araqit's 100% backwards compatible except for proc pointer usages, the old story
22:11:35subsetparkyeah, definitely. I would be more than happy to submit that patch
22:12:38subsetparkI'll even call it ifMissing :)
22:14:09Araqok thanks
22:14:24FromGitter<ephja> subsetpark: doesn't work with compile time procs though
22:18:23*vendethiel- joined #nim
22:18:57*vendethiel quit (Ping timeout: 240 seconds)
22:19:25*vlad1777d quit (Ping timeout: 240 seconds)
22:27:21FromGitter<ephja> calling foo at run time while also registering the invocation (writing to a var) at compile time might be tricky
22:28:36*Matthias247 quit (Read error: Connection reset by peer)
22:29:01subsetparkjust out of curiosity, what are you trying to do?
22:29:15FromGitter<ephja> it would actually be better to use proc vars for opengl though, right? provided that we have mechanism that allows for this transition
22:40:21FromGitter<ephja> subsetpark: More flexible opengl extension loading. A library implementation of importc would be neat
22:45:03*bjz joined #nim
22:46:00*Jesin joined #nim
22:47:08*bjz_ quit (Ping timeout: 260 seconds)
22:47:18*chemist69 quit (Ping timeout: 276 seconds)
23:04:25*chemist69 joined #nim
23:40:56*bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
23:44:39*couven92 quit (Quit: Client Disconnecting)