<< 14-05-2017 >>

00:26:52*Guest93089 quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
00:30:48*hcorion quit (Quit: Konversation terminated!)
00:40:24*nsf quit (Quit: WeeChat 1.7.1)
00:41:48*Sentreen quit (Ping timeout: 260 seconds)
00:50:55*jsgrant_om joined #nim
00:51:07*bjz joined #nim
00:54:27*Sentreen joined #nim
00:59:55*bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
01:02:41TrioxinI wonder if I it would be trivial to make a proxy server
01:03:04Trioxinjust forwarding web requests I think
01:08:27Trioxinasyncdispatch
01:09:42Trioxinhttpserver would have been easier for this
01:10:03*yglukhov quit (Remote host closed the connection)
01:10:35Trioxinah, asyncnet
01:25:28Trioxintrying to find a client proc that parses and executes a request given an http header
01:27:55Trioxinmaybe I'm overthinking it
01:32:53*krux02 quit (Remote host closed the connection)
01:34:30*krux02 joined #nim
01:51:12*niomix joined #nim
01:51:34*jsgrant_om 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 hours.)
01:51:52niomixi installed nimble successfully :)
01:52:43niomixim gonna install aporia now
01:54:48Trioxinniomix, VS Code is better for nim
01:55:25niomixwell i am on ArchLinux, isn't VS for windows?
01:55:33Trioxinno, it's cross-platform
01:55:45TrioxinVS Code, not VS
01:55:49ftsfyay editor wars time
01:56:10Trioxinno need for war, just try them both out. you'll see.
01:57:21niomixXD ok i will try both
01:57:27Trioxinif we could get Jetbrains to make a Nim IDE, it would greatly increase Nim community
01:57:40Trioxinthey did one for Go
01:57:58*chemist69 quit (Ping timeout: 264 seconds)
01:58:06Trioxinwould probably fall under CLion though
02:07:42*PMunch joined #nim
02:11:11*chemist69 joined #nim
02:20:10FromGitter<zacharycarter> All of a sudden it seems symbols aren't being exposed correctly on my DLLs in windows or Nim is failing to load them
02:20:39FromGitter<zacharycarter> any idea where to start troubleshooting?
02:41:25*niomix quit (Remote host closed the connection)
02:41:29ftsfhttp://static.impbox.net/nicojs/nicojs.html start of nim javascript port of my game library
02:41:37ftsfusing html5_canvas
02:43:18*sz0 joined #nim
02:45:13*PMunch quit (Quit: leaving)
03:00:55*niomix joined #nim
03:10:36*yglukhov joined #nim
03:14:35*yglukhov quit (Ping timeout: 240 seconds)
03:24:56FromGitter<zacharycarter> I need to get frag on the web
03:25:00FromGitter<zacharycarter> very cool ftsf
03:25:31ftsfmuch more pleasant than writing JS
03:26:10FromGitter<zacharycarter> I bet
03:28:35ftsfhmm although you can't seem to use closures as event handlers =\
03:29:41*arnetheduck joined #nim
03:38:13*smt_ quit (Ping timeout: 240 seconds)
03:58:38*chemist69 quit (Ping timeout: 255 seconds)
04:04:37*krux02 quit (Remote host closed the connection)
04:04:58*chemist69 joined #nim
04:51:37*BennyElg_ quit (Remote host closed the connection)
05:08:59*GustavoLapasta joined #nim
05:20:25Trioxinhttps://www.youtube.com/watch?v=XCTt07AnqD0
05:26:53*user0 joined #nim
05:28:41*user0 quit (Client Quit)
05:53:14*gangstacat quit (Ping timeout: 245 seconds)
06:12:16*niomix quit (Ping timeout: 272 seconds)
06:17:10*miningold joined #nim
06:19:23*GustavoLapasta quit (Quit: Leaving)
06:34:47*miningold quit (Quit: leaving)
06:39:18*BennyElg joined #nim
07:05:49ftsf\o/ got my ludum dare Nim game ported to JS backend
07:05:53ftsfexcept for audio
07:10:08*Arrrr joined #nim
07:26:01*adeohluwa joined #nim
07:38:04*bjz joined #nim
07:52:11*sz0 quit (Quit: Connection closed for inactivity)
07:52:25*Tiberium joined #nim
07:52:31*Trioxin quit (Read error: Connection reset by peer)
07:52:36*Trioxin2 joined #nim
07:53:33*Trioxin2 is now known as Trioxin
07:55:53ftsfhttp://static.impbox.net/smalltrek/nicojs.html all working nicely in JS backend!
07:57:37*BennyElg quit (Remote host closed the connection)
08:13:09*gokr joined #nim
08:37:11*Trioxin2 joined #nim
08:37:57*Trioxin quit (Ping timeout: 240 seconds)
08:38:35*bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
08:40:12*bjz joined #nim
08:40:58dom96ftsf: nice! Although it's rather blurry in Firefox.
08:41:23ftsfdom96, ohh it must not support the pixelated css
08:47:18*yglukhov joined #nim
08:54:49*BennyElg joined #nim
09:42:55*nsf joined #nim
09:43:43*gokr quit (Ping timeout: 260 seconds)
09:49:24*vlad1777d joined #nim
10:00:58*lenstr quit (Ping timeout: 264 seconds)
10:03:39*yglukhov quit (Read error: Connection reset by peer)
10:04:17*yglukhov joined #nim
10:04:30*Trioxin2 is now known as Trioxin
10:30:09FromGitter<zacharycarter> ftsf - looks to me like firefox is antialiasing your pixel art
10:30:35ftsfzacharycarter yeah =( gonna try ff now
10:31:38FromGitter<zacharycarter> also now you've emboldened me and I've decided to give another go at getting frag on the web
10:32:11ftsf\o/
10:32:18ftsfemscripten or js backend?
10:32:31FromGitter<zacharycarter> emscripten
10:32:35FromGitter<zacharycarter> web assembly
10:32:42ftsfahh
10:34:59ftsfI had a lot of pain with emscripten and the GC
10:35:10ftsfJS backend has been good to me so far
10:36:43FromGitter<zacharycarter> interesting
10:37:29FromGitter<zacharycarter> how are you handling sdl2 with javascript?
10:37:35FromGitter<zacharycarter> or did you re-write your framework completely
10:37:38FromGitter<zacharycarter> without sdl2?
10:37:44ftsfyep, no more SDL
10:37:55ftsfjust using canvas for output and javascript events for input
10:38:07FromGitter<zacharycarter> wow okay
10:38:23FromGitter<zacharycarter> I should give something similar a try
10:38:40FromGitter<zacharycarter> although I don't think it will work
10:38:45FromGitter<zacharycarter> bgfx does support webgl
10:39:03FromGitter<zacharycarter> but I'm not going to be able to interop with it with js as the target
10:39:09FromGitter<zacharycarter> so I guess I'm stuck with emscripten
10:49:51ftsf\o/ sound is starting to happen, although it sounds wrong
10:49:55dom96indeed the JS backend is really good
10:51:11FromGitter<zacharycarter> I'd love to use it, but I don't see how I could interop with the C++ code I need to
10:51:18FromGitter<zacharycarter> or the C code rather
11:02:05dom96maybe you can find a JS library that does the same thing?
11:02:23*BennyElg quit (Remote host closed the connection)
11:03:19FromGitter<zacharycarter> Unfortunately I think the framework would behave / look totally different when targeting thin vs thick client if I took that approach dom96
11:03:43*BennyElg joined #nim
11:03:43FromGitter<zacharycarter> plus all the integrations I've added - Spine, NanoVG, Nuklear, etc... would not function
11:03:48FromGitter<zacharycarter> since they're all C code
11:04:38FromGitter<zacharycarter> although spine does have a webgl backend
11:04:39FromGitter<zacharycarter> hrm
11:04:56FromGitter<zacharycarter> maybe this is the right route and I just use three.js
11:12:23*yglukhov quit (Remote host closed the connection)
11:12:56*bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
11:18:09FromGitter<zacharycarter> can the js backend interop with typescript?
11:18:57Tiberiumyeah
11:19:04Tiberiumsince typescript is compiled to js anyway
11:19:24*user0 joined #nim
11:19:56FromGitter<zacharycarter> but let's say I have a library written in TS
11:20:06FromGitter<zacharycarter> Nim will be able to call TS functions etc
11:20:16FromGitter<zacharycarter> Tiberium?
11:21:02FromGitter<zacharycarter> if that's the case then I think making a js backend with three.js makes some sense maybe
11:28:08*Trioxin quit (Ping timeout: 260 seconds)
11:31:26*bjz joined #nim
11:32:11ftsfnow to figure out how to make external JS interact with my Nim JS...
11:34:42*user0 quit (Quit: user0)
12:10:28*nsf quit (Quit: WeeChat 1.7.1)
12:45:45*vlad1777d quit (Quit: Leaving)
12:46:12*chemist69 quit (Ping timeout: 272 seconds)
12:47:48enthus1astzacharycarter it seems that alot of current game engines etc use emscripten
12:47:58*Trustable joined #nim
12:48:01enthus1astgodot does
12:50:11*chemist69 joined #nim
12:51:01ftsfhttp://static.impbox.net/smalltrek/nicojs.html \o/ audio all working nicely now
12:54:59FromGitter<zacharycarter> hrm
12:55:13FromGitter<zacharycarter> I'm following this thread: https://forum.nim-lang.org/t/2838
12:55:19FromGitter<zacharycarter> just trying to compile echo "hello world"
12:55:47FromGitter<zacharycarter> I keep getting this error:
12:56:26FromGitter<zacharycarter> https://gist.github.com/zacharycarter/b0c2bcac3435e72224df26ba973a6d8a
12:56:30FromGitter<zacharycarter> anyone have any idea what I'm doing wrong?
12:56:50FromGitter<zacharycarter> no idea why mach/mach.h is being included
12:56:50ftsfhmm osx?
12:57:15FromGitter<zacharycarter> yup, I am compiling on osx
12:58:25ftsfhmm wrong OS being set perhaps
12:58:38ftsfI guess for emscripten builds it shouldn't use your host os
12:58:46FromGitter<zacharycarter> yeah
12:58:52FromGitter<zacharycarter> that makes sense
12:59:07Araqfor emscripten use --os:linux
12:59:20FromGitter<zacharycarter> thanks @Araq
12:59:48AraqPmunch: https://github.com/nim-lang/sdl2/pull/71
13:12:53*yglukhov joined #nim
13:16:57*yglukhov quit (Ping timeout: 240 seconds)
13:39:41*yglukhov joined #nim
13:41:39enthus1astcan the sourcecode filter generate '#' ?
13:43:55enthus1ast## nor \# nor \\# let me generate just an '#' (for css rules)
13:44:51*adeohluwa quit (Quit: Connection closed for inactivity)
13:45:38Araqenthus1ast can you give an example? incidentically I'm looking at fixing this
13:48:58enthus1astsec
13:49:35enthus1astworkaround http://ch4t.code0.xyz/code/w9inHHSzLvzr6JnzHsyQ9pmBOHh8ZO84B8h1N2RTfDHIiVq7VtH06ccmsBgqeO6YzB0O1G7NkuizbfhdY0X4qw==/5918601aff34073a0000008c/ace
13:52:06enthus1astand this is not working (or a combination of other escape sequences)
13:52:19enthus1asthttp://ch4t.code0.xyz/code/A3AB7SSAcLG421qN49+EbnEgF8RyeA9+65rVD8j5eceN0@WgUkoS3bIY3aUrsXxOy3t6ZoAVbxsY96lX3NgU@g==/591860deff34073a0000008f/ace
13:52:49*bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
13:54:19Araqwhat's wrong with that? why would \# work? that's not documented anywhere
13:54:37Araqleading # (ignoring whitespace) causes it to be interpreted as Nim code
13:56:45enthus1astit generates \#code
13:57:42enthus1astor better: how can i let it eat css rules?
13:59:01Araq#result.add("code {\n")
13:59:10AraqI admit it kind of sucks ;-)
13:59:31Araqbut if the filter fails, you can always switch into Nim mode
14:00:21enthus1astsuper thanks Araq i can live with this for now : )
14:05:18*smt joined #nim
14:07:51enthus1astAraq: think i got another
14:08:28enthus1astthe "{" breaks it again
14:11:30enthus1asthttp://ch4t.code0.xyz/code/jnT99fj+AfpfQVr6SdtwDTjQdwUe67kZJsFxDZgzIUWddJ0mGClvFgYOTUVzNXSMFjrlT8Ccqw03WarFac2G6Q==/59186577ff34073a00000097/ace
14:14:18enthus1astah then its unbalanced. nevermind
14:34:24*BennyElg quit (Remote host closed the connection)
14:39:33*user0 joined #nim
14:41:45FromGitter<almynic> os.getFileSize() returns file size in bits or what?
14:43:45Araqbytes.
14:44:09FromGitter<almynic> ok thanks
14:44:41FromGitter<almynic> maybe that should be declared in the doc
14:45:36Araq*shrug*. it's the natural unit for file sizes.
14:45:59Araqyou can't have a file size of 12 bits.
14:48:05FromGitter<almynic> fair point
15:12:30*user0 quit (Quit: user0)
15:29:52*yglukhov quit (Remote host closed the connection)
15:38:28*m712 quit (Ping timeout: 255 seconds)
15:42:24*m712 joined #nim
16:23:26FromGitter<almynic> how can I speed this up ? https://pastebin.com/gDCgWdks
16:27:33FromGitter<almynic> I'm running the program on roughly 50'000 files ...
16:33:19*gangstacat joined #nim
16:40:28Tiberiumalmynic: a side note - "var fileName: string = os.extractFilename(file) # works now" for example there you don't need to write ":string"
16:40:50Tiberiumnim has a great type inference
16:42:12Tiberiumyou can make benchmarks via nimbench
16:42:31*def-pri-pub joined #nim
16:43:51ArrrrI don't understand why you define getFileContent when you have readFile. To remove new line chars?
16:44:18Tiberiumah, maybe it's because you're using methods?
16:44:26TiberiumAFAIK they're slower than proc's
16:44:41Tiberiumalso you don't need method in your code
16:44:48ArrrrYou don't need countChars, use instead len(fileContent)
16:46:30ArrrrAnother suggestion, every proc implicitly defines a "result" var. You can use "inc result" instead of defining your own variables
16:48:33ArrrrStrip returns a new string, you might want to find a more efficient way to count different words
16:48:45TiberiumWhen I switched to Nim I realised that I don't need methods :)
16:48:55TiberiumIn most of places
16:49:19ArrrrIn this case method is called only once, so is not a big deal.
16:49:31Tiberiumyeah
16:49:46Tiberiumbut in my case some of my procs are called many many times
16:52:50ArrrrAlso, you might want to compile with --d:release. Is this a port?
16:53:22*chemist69 quit (Ping timeout: 246 seconds)
16:53:46*chemist69 joined #nim
16:57:55*BennyElg joined #nim
17:30:27*tyler569 quit (Ping timeout: 240 seconds)
17:34:04FromGitter<almynic> ok thanks for the suggestions
17:34:19*kunev quit (Quit: е те!)
17:37:24*jsgrant_om joined #nim
17:38:47*kunev joined #nim
17:40:22*adeohluwa joined #nim
17:52:44*jsgrant_om quit (Ping timeout: 272 seconds)
17:56:43*rauss joined #nim
18:00:43*BennyElg_ joined #nim
18:07:12*yglukhov joined #nim
18:07:54*huonw_ joined #nim
18:07:59*qwertfisch_ joined #nim
18:08:33*yaiyan joined #nim
18:09:17*BennyElg quit (*.net *.split)
18:09:17*gangstacat quit (*.net *.split)
18:09:18*Ieuan quit (*.net *.split)
18:09:18*peted quit (*.net *.split)
18:09:20*MrAxilus[m] quit (*.net *.split)
18:09:20*dyce[m] quit (*.net *.split)
18:09:21*huonw quit (*.net *.split)
18:09:22*qwertfisch quit (*.net *.split)
18:09:24*qwertfisch_ is now known as qwertfisch
18:10:15*Ven joined #nim
18:10:58*Ven is now known as Guest3385
18:12:11*rauss quit (Quit: WeeChat 1.7.1)
18:15:54*peted joined #nim
18:16:25*gangstacat joined #nim
18:18:34*MrAxilus[m] joined #nim
18:19:43FromGitter<almynic> @Arrrr what do you mean with port?
18:20:01*dyce[m] joined #nim
18:20:27FromGitter<almynic> and --d:release was a massive speedup thanks
18:21:37ArrrrMaybe you were translating this code to nim from python/java or something
18:22:29FromGitter<almynic> ah no wrote it on my own but i'm not well versed in nim, i come from a java, c and python background
18:24:15*jsgrant_om joined #nim
18:24:18FromGitter<almynic> btw how do i use inc instead of implicitly defining a "result" var
18:26:54Arrrrinc + varname
18:27:08Arrrror `inc myVar, 1`
18:27:29FromGitter<almynic> ok thanks
18:33:48FromGitter<Varriount> @nimit95 Strings and sequences copy on assignment too. Read up on shallow and shallowCopy in the standard library
18:37:39*libman joined #nim
18:42:10*Guest3385 quit (Ping timeout: 240 seconds)
18:43:23*Ven_ joined #nim
19:00:01*jsgrant_om quit (Ping timeout: 258 seconds)
19:01:17*yglukhov quit (Remote host closed the connection)
19:05:19*vlad1777d joined #nim
19:19:37Tiberiumhttps://github.com/nim-lang/Nim/commit/bf0ac2bd72e446b1499adaa408b41f76b853c04b wow, araq is a coding beast
19:20:04Tiberiumgithub even said that "large diffs are not rendered by default"
19:20:13*gokr joined #nim
19:27:39*yglukhov joined #nim
19:29:04*nsf joined #nim
19:31:50*smt quit (Ping timeout: 258 seconds)
19:32:26libmanAraq is superhuman. Or a team of very talented people posing as one person. ;-)
19:40:14*rauss joined #nim
19:46:53*jsgrant_om joined #nim
19:52:33*smt joined #nim
19:54:36AraqTiberium: I copied upcoming/asyncdispatch to lib/pure ;-) in fact, it's a small patch
19:55:01*Arrrr quit (Quit: Leaving.)
19:55:32Araqgains us 30K more requests per second or something
19:55:45Araqbut also crashes most of the time
19:56:05*Ven_ quit (Ping timeout: 268 seconds)
20:02:13*Tiberium quit (Remote host closed the connection)
20:04:52*yglukhov quit (Remote host closed the connection)
20:06:39*rauss quit (Quit: WeeChat 1.7.1)
20:06:52*Ven joined #nim
20:07:16*Ven is now known as Guest28311
20:15:17*Guest28311 quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
20:31:42FromGitter<almynic> in the unittest doc there is a small error ⏎ ⏎ ```teardown: echo "run after each test":``` [https://gitter.im/nim-lang/Nim?at=5918bead2b926f8a67557bc9]
20:52:45*bjz joined #nim
20:54:53gangstacatI tested with both nim 0.16.0 and master but I don't see any difference on a hello world jester, I got around 30k requests/second
20:55:10dom960.16.0 == master
20:55:19gangstacatI mean head?
20:55:31dom96Araq's commit is in another branch
20:55:35gangstacatoh..
20:56:06gangstacatsorry I didn't see
21:00:31*vlad1777d quit (Quit: Leaving)
21:03:07*rauss joined #nim
21:03:49*BennyElg_ quit (Remote host closed the connection)
21:10:32*Trustable quit (Remote host closed the connection)
21:18:37*jsgrant_om 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 hours.)
21:19:58*adeohluwa quit (Quit: Connection closed for inactivity)
21:37:47*PMunch joined #nim
21:39:04*smt_ joined #nim
21:39:26*aziz_ joined #nim
21:41:16*aziz_ is now known as aziz
21:41:30*samdm joined #nim
21:41:45*aziz quit (Client Quit)
21:42:18*Calinou_ joined #nim
21:42:18*bozaloshtsh_ joined #nim
21:42:56*demi- quit (Ping timeout: 268 seconds)
21:42:56*niv quit (Ping timeout: 268 seconds)
21:42:56*samdm is now known as demi-
21:42:57*Calinou quit (Remote host closed the connection)
21:42:58*smt quit (Ping timeout: 268 seconds)
21:42:58*bozaloshtsh quit (Ping timeout: 268 seconds)
21:43:19*bozaloshtsh_ is now known as bozaloshtsh
21:43:19*bozaloshtsh quit (Changing host)
21:43:19*bozaloshtsh joined #nim
21:44:00*Calinou_ is now known as Calinou
21:46:42*Matthias247 joined #nim
21:47:08*bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
22:01:48*bjz joined #nim
22:12:15*beatmox quit (Remote host closed the connection)
22:12:27*beatmox joined #nim
22:12:41*bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
22:27:11*Trioxin joined #nim
22:35:24*Matthias247 quit (Read error: Connection reset by peer)
22:37:00*Matthias247 joined #nim
22:42:10*ftsf_ joined #nim
22:52:38*Matthias247 quit (Read error: Connection reset by peer)
22:56:43*libman quit (Quit: Connection closed for inactivity)
23:01:52*nsf quit (Quit: WeeChat 1.7.1)
23:18:50TrioxinNim about to make me a lot of $
23:22:08*PMunch quit (Quit: leaving)
23:23:38*Trioxin2 joined #nim
23:23:58*Trioxin quit (Ping timeout: 272 seconds)
23:25:05*arnetheduck quit (Ping timeout: 240 seconds)
23:25:49FromGitter<ephja> tell us more
23:27:02FromGitter<ephja>
23:31:01Trioxin2any sufficiently helpful marketing software can be sold for a lot
23:31:09*Trioxin2 is now known as Trioxin
23:37:45*Trioxin2 joined #nim
23:40:42*Trioxin quit (Ping timeout: 240 seconds)
23:49:02FromGitter<ephja> sure. go nuts my friend
23:54:25*chemist69 quit (Ping timeout: 258 seconds)
23:57:31*Jesin joined #nim
23:57:36*chemist69 joined #nim