<< 02-04-2015 >>

00:00:27*irrequietus quit ()
00:00:31*fizzbooze quit (Ping timeout: 250 seconds)
00:00:36*reem quit (Remote host closed the connection)
00:03:56*hellonico joined #nim
00:04:38*fizzbooze joined #nim
00:10:05*vezzy quit (Quit: vezzy)
00:10:27*quasinoxen joined #nim
00:10:37*Jehan_ quit (Quit: Leaving)
00:12:44*reem joined #nim
00:21:14*askatasuna quit (Ping timeout: 246 seconds)
00:38:28*HakanD____ joined #nim
00:39:12Kingsqueeaaugh
00:39:22Kingsqueerust is doing dumb things with their type system agaain
00:39:46Kingsqueewhy do you guys have to write such a sexy language but with a garbage collector :(
00:40:01Kingsqueea vile temptress, this nim-chan is
00:40:17def-Kingsquee: what's wrong with a GC?
00:40:30EXetoCpotentially nothing
00:41:17KingsqueeI like being able to see what's happening or not-happening just from looking at the code
00:41:41Kingsqueethe less magicks not written by me happening at runtime, the better
00:41:57*fizzbooze quit (Ping timeout: 248 seconds)
00:42:35gokrKingsquee: Then use assembler and never call anyone else's code :)
00:43:01*HakanD____ quit (Ping timeout: 248 seconds)
00:43:01Kingsqueegokr: oh how I'd love to
00:43:14EXetoCreally?
00:43:22Kingsqueehttp://blog.erratasec.com/2015/03/x86-is-high-level-language.html sadly
00:43:26Kingsqueethose days are numbered too
00:45:07*askatasuna joined #nim
00:45:55gokrKingsquee: What "dumb thing" is Rust doing?
00:46:20EXetoCbut using pure assembly for example incurs a massive development overhead
00:46:35KingsqueeI think the best way to describe it is they're defining relationships with the type system
00:46:58Kingsqueeprimarily with how they're handling strings
00:48:27Kingsqueethey've got a String type and a &str type, the first is an owned, mutable unicode string, and the second is basically an immutable slice reference to some valid-unicode bytes
00:49:06Kingsqueenote that they don't use &String because that passes an immutable reference to the whole string
00:49:40Kingsqueeand if there's any type that closely wraps a string, like say, a filesystem path, it too has to carry that same pattern
00:49:46EXetoCthere is a lot of "magic" going on in some libs that I use, but I have simply no need to know what that would be exactly
00:49:56Kingsqueeso you get PathBuf/Path wrapping an OsString/OsStr
00:49:58Kingsqueeand aagh
00:50:05Kingsqueecombined with static typing and conversions
00:50:16Kingsqueeand error checking if the thing is valid utf8
00:50:42EXetoCthe same goes for garbage collection. knowing the semantics of the program and the individual instructions that are executed are two very different things
00:50:46Kingsqueelet dir_name = String::from_str(toml_path.parent().unwrap().file_name().unwrap().to_str().unwrap());
00:51:00*Kingsquee can't scream only laugh
00:51:34EXetoCthough you might have just meant "it seems nice, but it's not for me"
00:51:55EXetoCyou can't escape that? I recall functions such as unwrap for example but I haven't used rust in some time
00:52:16Kingsqueethey have ways to leave the unwrap() until the very end
00:52:32Kingsqueebut you have to use and_then(function)
00:52:43Kingsqueewhich ends up being even longer and uglier to read
00:52:48*Kingsquee shrugs
00:53:43Kingsqueesomeday a nim-ish language will use a borrow checker
00:53:46Kingsqueeand the world will be at peace
00:55:07*brson joined #nim
00:55:47*gokr quit (Quit: Leaving.)
00:56:02EXetoCas long as I don't have to use it. I think there are plans for such things
00:59:02Kingsqueethat would be amazing
01:05:20*reem quit (Remote host closed the connection)
01:07:19fowlmouthAraq, I didnt know that ._.
01:18:00*reem joined #nim
01:23:34*mwbrown joined #nim
01:30:32*johnsoft quit (Ping timeout: 264 seconds)
01:30:46*johnsoft joined #nim
01:40:43*reem quit (Remote host closed the connection)
01:42:17*reem joined #nim
01:51:42*TEttinger quit (Ping timeout: 250 seconds)
01:53:49*wb quit (Ping timeout: 264 seconds)
01:57:57*BitPuffin quit (Ping timeout: 250 seconds)
02:00:34*reem quit (Remote host closed the connection)
02:02:44*saml_ joined #nim
02:03:01*untitaker quit (Ping timeout: 248 seconds)
02:06:17*brson quit (Quit: leaving)
02:06:40*reem joined #nim
02:08:57*untitaker joined #nim
02:11:26*darkf joined #nim
02:14:04*reem quit (Remote host closed the connection)
02:14:51*pipeep quit (Quit: Bye!)
02:16:28*pipeep joined #nim
02:21:31*reem joined #nim
02:50:20*fizzbooze joined #nim
03:01:40*reem quit (Remote host closed the connection)
03:07:36*askatasuna quit (Ping timeout: 272 seconds)
03:14:00*reem joined #nim
03:25:50*reem quit (Remote host closed the connection)
03:27:04*reem joined #nim
03:35:23*reem quit (Remote host closed the connection)
03:37:16*reem joined #nim
03:39:13*reem quit (Remote host closed the connection)
03:39:46*reem joined #nim
03:53:13*johnsoft quit (Ping timeout: 264 seconds)
04:02:32*saml_ quit (Quit: Leaving)
04:03:12*brson joined #nim
04:13:27*mwbrown quit (Ping timeout: 252 seconds)
04:14:29*nande quit (Remote host closed the connection)
04:15:40*reem quit (Remote host closed the connection)
04:16:17*reem joined #nim
04:23:33*fizzbooze quit (Quit: WeeChat 1.1.1)
04:23:56*fizzbooze joined #nim
04:24:57*hellonic_ joined #nim
04:24:57*hellonico quit (Read error: Connection reset by peer)
04:28:42*reem quit (Remote host closed the connection)
04:30:49*brson quit (Quit: leaving)
04:43:08*reem joined #nim
04:44:30*reem quit (Remote host closed the connection)
04:56:55*quasinoxen quit (Ping timeout: 250 seconds)
05:34:30*reem joined #nim
05:35:36*gokr joined #nim
05:38:39*TEttinger joined #nim
05:38:54*yglukhov joined #nim
05:43:26*reem quit (Remote host closed the connection)
05:47:28*pafmaf joined #nim
05:51:20*reem joined #nim
06:02:26*MagusOTB joined #nim
06:05:43*HakanD____ joined #nim
06:06:38*reem quit (Remote host closed the connection)
06:10:46*clynamen_ joined #nim
06:12:47*reem joined #nim
06:13:00*clynamen quit (Ping timeout: 246 seconds)
06:15:46*hellonic_ quit (Remote host closed the connection)
06:16:14*hellonico joined #nim
06:17:12*reactormonk joined #nim
06:20:17*hellonico quit (Read error: No route to host)
06:20:24*hellonico joined #nim
06:23:59*BlaXpirit joined #nim
06:32:48*gokr_ joined #nim
06:37:57*reem quit (Remote host closed the connection)
06:38:57*wb joined #nim
06:42:47*reem joined #nim
06:44:45*reem quit (Remote host closed the connection)
06:45:21*reem joined #nim
06:47:19*gokr_ quit (Ping timeout: 245 seconds)
06:47:44*reem quit (Remote host closed the connection)
06:48:00*gokr_ joined #nim
06:51:22yglukhovHello, channel! ;)
06:51:35yglukhovCan anyone test the following?
06:51:35yglukhovnim doc2 "--hint[Conf]:off" '--hint[Path]:off' '--hint[Processing]:off' --putenv:nimversion=0.10.3 --docSeeSrcUrl:https://github.com/Araq/Nim/tree/master/lib/impure -o:web/upload/graphics.html --index:on lib/impure/graphics.nim
06:52:04yglukhovI've got an ICE
06:55:30fowlmouthError: arguments can only be given if the '--run' option is selected
06:56:08yglukhoverr.... is it latest devel you have?
06:57:26fowlmouthit works for me when i remove the quotes
06:57:28yglukhovis it at least devel? ;)
06:57:44yglukhovoh. ok
06:57:53yglukhovso you don't have an ICE?
06:58:48fowlmouthif you compile with --linetrace:on or stacktrace:on you can see where the error is from
06:58:51yglukhovhad to quote, becuse my zsh tried to do something weird with those brackets
06:58:54fowlmouthi dont remember which it is
06:59:07yglukhovnim doc2 "--hint[Conf]:off" '--hint[Path]:off' '--hint[Processing]:off' --putenv:nimversion=0.10.3 --docSeeSrcUrl:https://github.com/Araq/Nim/tree/master/lib/impure -o:web/upload/graphics.html --index:on lib/impure/graphics.nim
06:59:07yglukhovTraceback (most recent call last)
06:59:07yglukhovnim.nim(94) nim
06:59:07yglukhovnim.nim(56) handleCmdLine
06:59:07yglukhovmain.nim(279) mainCommand
06:59:07yglukhovmain.nim(53) commandDoc2
06:59:07yglukhovmodules.nim(203) compileProject
06:59:07*yglukhov quit (Excess Flood)
06:59:41*yglukhov joined #nim
07:00:53yglukhovi shouldn't have pasted the traceback here :)
07:01:20fowlmouthyglukhov, its nice to have if you want to try to fix it or also good to post with the issue
07:01:43*fizzbooze quit (Ping timeout: 256 seconds)
07:01:51*pafmaf quit (Quit: This computer has gone to sleep)
07:01:56yglukhovfowlmouth: i've got the traceback, I'm just curious whether you observe ICE on your OS?
07:02:08yglukhovwhat's your os btw?
07:02:57fowlmouthwindows
07:03:30yglukhovok cool. and you have that ICE as well, don't you?
07:04:34fowlmouthno
07:04:46fowlmouthit works for me
07:05:13yglukhovok. thanks for help.
07:10:46*MagusOTB quit (Ping timeout: 244 seconds)
07:11:35*MagusOTB joined #nim
07:16:13*reem joined #nim
07:18:19*reem quit (Remote host closed the connection)
07:21:14*MagusOTB quit (Ping timeout: 265 seconds)
07:24:03*reem joined #nim
07:29:57*reem quit (Remote host closed the connection)
07:31:50*hellonico quit (Remote host closed the connection)
07:42:25*pafmaf joined #nim
07:56:54*gsingh93 quit (Ping timeout: 245 seconds)
08:06:17*tumult joined #nim
08:09:59*BlaXpirit quit (Quit: Quit Konversation)
08:32:17*Trustable joined #nim
08:32:36*hellonico joined #nim
08:33:32*MyMind joined #nim
08:42:04*milosn quit (Ping timeout: 250 seconds)
08:47:35*pafmaf quit (Quit: This computer has gone to sleep)
08:53:25*ggVGc is now known as vim
08:53:33*vim is now known as ggVGc
08:53:48*MagusOTB joined #nim
08:55:41*Senketsu quit (Quit: Leaving)
08:57:57*MagusOTB quit (Ping timeout: 248 seconds)
09:10:45*davidhq joined #nim
09:18:08*hellonico quit (Remote host closed the connection)
09:19:26*davidhq quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
09:31:40*yglukhov_ joined #nim
09:32:27*MyMind quit (Ping timeout: 256 seconds)
09:35:01*yglukhov quit (Ping timeout: 252 seconds)
09:36:00*jm116__ joined #nim
09:36:49*jm116__ quit (Changing host)
09:36:49*jm116__ joined #nim
09:38:59*Kingsquee quit (Quit: Konversation terminated!)
09:40:04*pafmaf_ joined #nim
09:45:54*milosn joined #nim
09:47:17*milosn quit (Read error: Connection reset by peer)
09:49:54*milosn joined #nim
09:53:49*pafmaf_ quit (Ping timeout: 264 seconds)
09:54:14*yglukhov_ quit (Remote host closed the connection)
09:54:50*yglukhov_ joined #nim
09:57:23*flaviu quit (Ping timeout: 252 seconds)
09:58:49*johnsoft joined #nim
09:59:00*pafmaf_ joined #nim
10:00:04*flaviu joined #nim
10:01:13*wan joined #nim
10:04:01*cazov quit (Ping timeout: 255 seconds)
10:04:08*cazov joined #nim
10:15:43*daurnimator quit (Ping timeout: 252 seconds)
10:30:31*reem joined #nim
10:33:18*HakanD____ quit (Quit: Be back later ...)
10:33:51*HakanD____ joined #nim
10:35:10*reem quit (Ping timeout: 250 seconds)
10:35:31*filwit joined #nim
10:35:38flyxare there any best practices for source code layout? can I have a source file "package.nim" and at the same level a directory "package" with more source files in it?
10:36:05filwitflyx: yes you can do that and it works well
10:47:36*daurnimator joined #nim
10:48:25*milosn quit (Ping timeout: 264 seconds)
10:52:11*HakanD____ quit (Quit: Be back later ...)
11:05:02*HakanD____ joined #nim
11:07:29*jefus__ joined #nim
11:11:04*jefus_ quit (Ping timeout: 255 seconds)
11:14:09*milosn joined #nim
11:24:16federico3how can I get the destination of a symlink? getFileInfo doesn't provide it and if I readFile on it it will follow the symlink
11:25:15*pafmaf_ quit (Quit: This computer has gone to sleep)
11:27:58*milosn quit (Read error: Connection reset by peer)
11:28:49*milosn joined #nim
11:32:19*banisterfiend quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
11:33:48*milosn quit (Read error: Connection reset by peer)
11:37:45*filwit quit (Quit: Leaving)
11:37:58federico3aha: posix readlink
11:39:08*milosn joined #nim
11:42:46*banister joined #nim
11:48:41*HakanD____ quit (Quit: Be back later ...)
11:49:33flyxthe unittest framework is a bit strange. I have code that works normally, but doesn't work when I put it in a test case
11:50:05pigmejflyx: remove checks
11:50:32flyxI currently have no checks
11:51:10flyxwell test is a macro, and I also use macros, so maybe they just bite each other or something
11:56:38*pafmaf joined #nim
12:00:07*BlaXpirit joined #nim
12:01:41*pafmaf quit (Quit: This computer has gone to sleep)
12:09:39*milosn quit (Ping timeout: 246 seconds)
12:13:03*gimireh joined #nim
12:13:14*gimireh quit (Client Quit)
12:24:30*banister quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
12:25:11*HakanD____ joined #nim
12:25:44*polde quit (Ping timeout: 265 seconds)
12:35:13*gokr quit (Ping timeout: 264 seconds)
12:36:10*gokr joined #nim
12:37:02*gokr_ quit (Ping timeout: 256 seconds)
12:44:38*kashyap_ joined #nim
12:45:12kashyap_Can someone please send me a sample program to connect to SQL server
12:49:15*arnetheduck joined #nim
12:51:23*mpthrapp joined #nim
12:52:54*polde joined #nim
12:53:50*milosn joined #nim
13:01:01*polde quit (Ping timeout: 265 seconds)
13:03:06*HakanD____ quit (Quit: Be back later ...)
13:05:09*banister joined #nim
13:05:49*banister quit (Max SendQ exceeded)
13:06:57LoneTechkashyap_: nope, but what you want may be related to database support under http://nim-lang.org/lib.html#impure-libraries
13:07:25LoneTechor wrappers
13:08:09*milosn quit (Ping timeout: 245 seconds)
13:11:18*banister joined #nim
13:12:45kashyap_Thanks LoneTech .... I had checked out that link .. I am considering using odbcsql but not quite sure how to ...
13:13:18*jm116__ quit (Quit: Leaving)
13:13:57LoneTechme neither
13:21:37*milosn joined #nim
13:28:30*polde joined #nim
13:31:22*pafmaf joined #nim
13:32:51def-kashyap_: odbc seems to be missing the high level sql library, so I guess someone would have to write that first
13:33:20kashyap_oh I see
13:33:28kashyap_thanks def
13:34:03def-sqlite, mysql and postgres have it already and can be used easily: https://github.com/def-/nim-unsorted/blob/master/tablecreation.nim
13:35:49*TEttinger quit (Ping timeout: 264 seconds)
13:36:37tumultif I had the Nim skills I'd write the wrapper for SQL server myself as that would let me start using Nim at work, but sadly I'm too much of a noob atm :/
13:36:53tumulton my todo list tho
13:38:20tumultI do just want to say though that basic3d and basic2d are FANTASTIC :D
13:39:46*kashyap_ quit (Ping timeout: 246 seconds)
13:43:33*polde quit (Ping timeout: 265 seconds)
13:45:25*milosn quit (Ping timeout: 248 seconds)
13:49:00Araqdon't do it via odbc.
13:49:12Araquse the native APIs instead
13:49:55Araqwe don't need yet another layer in between with lots of silly integer typedefs and crap
13:54:58*milosn joined #nim
14:03:34*milosn quit (Read error: Connection reset by peer)
14:04:19*milosn joined #nim
14:10:34*milosn quit (Read error: Connection reset by peer)
14:11:02*polde joined #nim
14:11:35*milosn joined #nim
14:14:14*milosn quit (Read error: Connection reset by peer)
14:20:52*HakanD____ joined #nim
14:21:01*BitPuffin joined #nim
14:21:39*milosn joined #nim
14:24:38*polde quit (Ping timeout: 265 seconds)
14:24:55*milosn quit (Read error: Connection reset by peer)
14:26:38*milosn joined #nim
14:30:07*gokr_ joined #nim
14:33:09*gokr quit (Ping timeout: 245 seconds)
14:34:01*banister quit (Ping timeout: 255 seconds)
14:44:42*jefus__ is now known as jefus
14:46:13*darkf quit (Quit: Leaving)
14:48:25*milosn quit (Ping timeout: 264 seconds)
14:50:21*BitPuffin quit (Remote host closed the connection)
14:50:52*BitPuffin joined #nim
14:51:46*polde joined #nim
14:59:59*davidhq joined #nim
15:01:09*davidhq quit (Max SendQ exceeded)
15:01:51*polde quit (Ping timeout: 265 seconds)
15:07:44*jm116__ joined #nim
15:10:40*banister joined #nim
15:17:20*mpthrapp_ joined #nim
15:19:32*mpthrapp quit (Ping timeout: 244 seconds)
15:26:50*gokr joined #nim
15:29:01*polde joined #nim
15:29:18*gokr_ quit (Ping timeout: 256 seconds)
15:30:08*gokr_ joined #nim
15:33:05*gokr quit (Read error: Connection reset by peer)
15:33:16*gokr joined #nim
15:34:24*gokr_ quit (Ping timeout: 256 seconds)
15:35:36*HakanD____ quit (Quit: Be back later ...)
15:36:04*mpthrapp_ quit (Ping timeout: 244 seconds)
15:41:12*mpthrapp joined #nim
15:53:07*mpthrapp quit (Ping timeout: 244 seconds)
15:54:54*banister quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
16:00:05*milosn joined #nim
16:03:03*mpthrapp joined #nim
16:05:53*mpthrapp quit (Read error: Connection reset by peer)
16:13:46*tumult quit (Ping timeout: 246 seconds)
16:18:17*jm116__ quit (Quit: Leaving)
16:23:58*mwbrown joined #nim
16:31:38*johnsoft quit (Quit: Leaving)
16:35:38*johnsoft joined #nim
16:36:53*yglukhov_ quit (Ping timeout: 256 seconds)
16:36:53*brson joined #nim
16:48:43*mpthrapp joined #nim
16:51:30*fizzbooze joined #nim
16:51:36*HakanD____ joined #nim
17:02:39*EXetoC quit (Remote host closed the connection)
17:12:53*johnsoft quit (Ping timeout: 248 seconds)
17:15:50*johnsoft joined #nim
17:19:26*EXetoC joined #nim
17:22:49*gokr_ joined #nim
17:24:24*gokr quit (Ping timeout: 245 seconds)
17:29:00*irrequietus joined #nim
17:31:37*pafmaf quit (Ping timeout: 264 seconds)
17:39:36*pafmaf joined #nim
17:43:30*gsingh93 joined #nim
17:52:27*gokr joined #nim
17:52:34*gokr quit (Read error: Connection reset by peer)
17:54:24*reem joined #nim
17:55:52*fizzbooze quit (Ping timeout: 250 seconds)
17:58:13*nande joined #nim
18:01:56*wb quit (Ping timeout: 250 seconds)
18:03:42*irrequietus quit ()
18:04:34*pafmaf quit (Quit: This computer has gone to sleep)
18:12:02ldleworkJulia has an official Docker image now
18:22:58*wb joined #nim
18:36:13*Etheco quit (Read error: Connection reset by peer)
18:37:11reactormonkldlework, docker?
18:37:42*irrequietus joined #nim
18:41:50*reem quit (Remote host closed the connection)
18:46:13*BitPuffin quit (Ping timeout: 248 seconds)
18:49:04*reem joined #nim
18:50:23*reem quit (Read error: Connection reset by peer)
18:50:57*reem joined #nim
18:51:53dom96ldlework: does Nim have one?
18:53:29ldleworkdom96: Don't think so
18:54:04dom96ldlework: Why?
18:54:58ldleworkdom96: Probably because no one from the Nim project has reached out to Docker Inc to maintain one.
19:03:57*pafmaf joined #nim
19:10:23*davidhq joined #nim
19:13:01*pafmaf quit (Quit: This computer has gone to sleep)
19:14:22*renesac joined #nim
19:15:48renesacthere is some new magic in the compiler
19:15:59renesacdo I need to download the csources again to be able to bootstrap it?
19:17:38def-renesac: if ./koch boot -d:release fails, yes
19:17:47renesacok
19:18:12renesacit's been some time since I updated the compiler
19:18:26*yglukhov_ joined #nim
19:20:00*pafmaf joined #nim
19:20:53federico3may I suggest putting an "edit me on github" link to the docs HTML pages to encourage contribution?
19:22:17*pafmaf quit (Client Quit)
19:25:08reactormonkfederico3, hm. would need to go into koch web probably
19:25:36*Etheco joined #nim
19:27:06*Etheco quit (Client Quit)
19:31:12federico3reactormonk: the tool itself rather than configuration/template files?
19:31:52reactormonkfederico3, I don't know how exactly you would have to add it
19:32:24dom96ldlework: Any chance you could maintain one?
19:32:47*Etheco joined #nim
19:53:51*fizzbooze joined #nim
20:00:53*gokr joined #nim
20:12:58*BitPuffin joined #nim
20:14:19*reem quit (Remote host closed the connection)
20:15:06*brson quit (Quit: leaving)
20:15:27*vbttt joined #nim
20:15:35*vbttt is now known as vbtt_
20:17:01*reem joined #nim
20:17:34*BitPuffin quit (Ping timeout: 250 seconds)
20:18:15*HakanD____ quit (Quit: Be back later ...)
20:18:42vbtt_so 'concepts' are a proper feature now? i though the user defined type classes had some bugs.
20:22:45vbtt_can I read the devel manual in the pretty web format somewhere?
20:25:11EXetoCsome bugs remain
20:25:45*gokr_ quit (Quit: IRC for Sailfish 0.9)
20:27:19*gokr quit (Ping timeout: 245 seconds)
20:28:04Araqvbtt_: no. they are not working yet
20:28:20Araqbut at least they have a sexy name now
20:28:42Araqbut they will be in 1.0, quite sure
20:29:06def-vbtt_: ./koch web builds the documentation (and some more)
20:29:33Araqkoch pdf builds PDFs
20:29:35Araqiirc
20:31:22renesacvbtt_: http://nim-build.nim-lang.org/documentation.html
20:31:44renesacat least this used to work
20:32:50renesacaraq: 'rune' should be int32 (or uint32), not int, don't you think?
20:33:30Araqrenesac: I don't care, int is not wrong
20:33:31renesac*RuneImpl
20:33:50renesacwell, it is 4 bytes more per element in the string on 64bit systems, isn't?
20:33:58renesacand 4 bytes per character is already big
20:34:23Araqsure make a PR
20:35:20renesacok
20:35:39*reem quit (Remote host closed the connection)
20:35:41renesacand there is no function to convert a unicode string to the closest ascii string possible, right?
20:35:57Araqthere is unidecode.nim for that
20:35:57def-what does "closest" even mean?
20:36:14renesacdepends
20:36:28def-oh, unidecode looks interesting
20:36:52renesacI'm fine with 'ê' being converted in either 'e' or 'e^'
20:37:59renesacthanks Araq, I didn't saw it
20:38:16renesac*didn't see
20:41:15*Strikecarl joined #nim
20:41:49StrikecarlWhat lib is involved in keystrokes?
20:42:03Strikecarli want to make a program, while i hold space it clicks space every 20 ms.
20:43:22reactormonkStrikecarl, that's an OS setting. If you want real control, gotta do something else
20:43:34Strikecarlkk.
20:43:44reactormonkso you want keydown/keyup information?
20:43:50Strikecarlyes
20:43:51Strikecarllike
20:43:59Strikecarlwhile(keydown(spaceidhere))
20:44:04reactormonknot sure you can do that on a terminal, but you can certainly do it in a gui
20:44:10Strikecarlkk.
20:46:05*Kingsquee joined #nim
20:46:57reactormonkStrikecarl, yup, terminals are character-based, not event-based
20:47:04StrikecarlAh kk.
20:47:30reactormonkI assume you're talking about a terminal app
20:48:28StrikecarlYup.
20:49:38vbtt_thanks Araq, renesac
20:49:56vbtt_Araq:did you see my note a few days ago about parsing 'f -1` and `f - 1`?
20:49:58*reem joined #nim
20:50:09vbtt_basically, coffeescript and moonscript already do it like you proposed
20:50:15vbtt_f -1 -> f(-1)
20:56:23vbtt_Araq:about 'concepts' - just saw some related commits and assumed it was now on track for 1.0
20:57:14pigmejhmm
20:57:29pigmejis there any 'incomming changes' list ?
20:58:34def-https://github.com/Araq/Nim/blob/devel/todo.txt https://github.com/Araq/Nim/wiki/Roadmap
20:58:37vbtt_pigmej: github
20:58:55vbtt_I was just talking about https://github.com/Araq/Nim/commits/devel
20:59:45pigmejok
21:00:26pigmejvbtt_: well contracts aren't on devel afair?
21:01:10vbtt_what are contracts?
21:01:34*Demos joined #nim
21:05:49*mpthrapp quit (Remote host closed the connection)
21:09:31*BitPuffin joined #nim
21:11:21*reem quit (Remote host closed the connection)
21:12:55pigmejhmm
21:13:51pigmejconcepts :)
21:13:53*irrequietus quit ()
21:14:00*BlaXpirit quit (Quit: Quit Konversation)
21:14:12pigmejmisstype :)
21:19:20def-concepts are on devel, renamed from generics
21:20:12pigmejhmm
21:20:29pigmejthat would explain:)
21:22:25Demoswait, we are talking the keyword rihgt
21:22:34Demoslike user defined typeclasses
21:33:40*clone1018 quit (Ping timeout: 256 seconds)
21:33:41vbtt_yes, the keyword is now 'concept'
21:35:23*mikolalysenko quit (Ping timeout: 256 seconds)
21:36:40*hguux___ joined #nim
21:36:42*clone1018 joined #nim
21:37:04*gever-gever quit (Ping timeout: 256 seconds)
21:38:04*reem joined #nim
21:38:06*gever-gever joined #nim
21:38:12*Triplefox quit (Ping timeout: 256 seconds)
21:38:45*Triplefox joined #nim
21:38:47*hguux__ quit (Ping timeout: 265 seconds)
21:38:48*jasondotstar quit (Ping timeout: 265 seconds)
21:39:13*jasondotstar joined #nim
21:39:25*mikolalysenko joined #nim
21:40:20*reem quit (Remote host closed the connection)
21:41:57*mwbrown quit (Ping timeout: 264 seconds)
21:42:30*reem joined #nim
21:57:53renesachow do I use unidecode.nim?
21:58:12renesacI tried compiling my program with 'nim c -r test.nim -d:embedUnidecodeTable'
21:58:29*reem quit (Remote host closed the connection)
21:59:03def-renesac: you'll need a unidecode table
21:59:13renesacit is in the same folder
21:59:24renesacas the module
21:59:30renesacthere is a line there "when defined(embedUnidecodeTable):"
21:59:36renesachow I trigger it?
21:59:49def-that would be -d:embedUnidecodeTable
22:00:00renesacthat is what I tried
22:00:04*dewdrop quit (Read error: Connection reset by peer)
22:00:05def-but the slurp path may not work anymore
22:00:35def-renesac: Seems to do something for me, not sure if it's useful what it does
22:00:41renesaclib/pure/unidecode/unidecode.nim(46, 10) Error: type mismatch: got (seq[string], int literal(65535))
22:00:42def-renesac: try calling loadUnidecodeTable() first
22:00:42renesacbut expected one of:
22:00:42renesacsystem.newSeq(len: int)
22:00:42renesacsystem.newSeq(s: var seq[T], len: int)
22:01:04renesacthis is what happened when I used "when true:" there
22:02:41def-works for me
22:04:27*Strikecarl quit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client)
22:04:29renesacwell, loading with the proc works
22:04:44def-you can either copy the unidecode.dat to your directory, or use -d:embedUnidecodeTable
22:04:55renesacwhy it can't be loaded automatically on import?
22:05:14def-so you can define another file i guess
22:05:47def-Maybe you can improve the module, it looks pretty small
22:06:00renesacyeah
22:06:05renesacwell, now it is working
22:06:34def-similarly with math's random, you have to call randomize() before using it
22:07:05renesacthe problem was calling -d: after the file
22:07:17renesacin my original command line
22:07:28def-if you write it after the file then it becomes an argument to the program you're running (if you use -r)
22:07:43renesacoh, right
22:08:07renesacwell, the problem is that here it is not simply "randomize()"
22:08:42renesacit is "longprocname(path_to_your_nim_library_sources/unidecode.dat)"
22:09:10def-longprocname() if you want to use the default file
22:09:20renesacoh
22:09:27renesacok, not so bad
22:10:42renesacError: unhandled exception: cannot open: unidecode.dat [IOError] <--- nope
22:11:03def-you'll need a unidecode.dat in the directory of your main.nim
22:11:10renesacyou must find the file and copy to your working directory
22:11:24renesacyep, that is bad
22:11:46def-maybe make embedding the default?
22:11:48renesacis there some way to make the default arg relative to the module directory?
22:12:01def-hm, i don'T think so
22:12:05def-how do you want to find the module dir at runtime?
22:12:11def-the user may not even have Nim installed
22:12:16renesacgood question
22:12:57def-the only way I see to change it would be to embed it by default
22:13:22renesacyeah, there is no explanation on why it is not so
22:13:53def-I guess you don't want to fill up binaries with some huge database
22:14:02renesacincreases the executable size by 1.3MB
22:14:17renesacand unicode.dat is only 227kb
22:14:44renesacactually, more like 1.4 to 1.5MB
22:16:01def-strip -s gets it down to 900 KB but still pretty bad
22:17:34Araqvbtt_: yes thanks, I did see it
22:19:42Araqyes these unicode tables are *huge*
22:20:20*reem_ joined #nim
22:21:29renesacwell, there is a middle ground:
22:21:41renesacconst staticdata = slurp"unidecode/unidecode.dat"
22:21:41renesac var translationTable = splitLines staticdata
22:22:12renesacwith that it only grows the size of the unicode.dat
22:22:25Araqyeah "only"
22:22:32renesacthat would be needed anyway
22:22:39flaviuIf executable size is that important, just use UPX or something.
22:23:11Araqjust put the file next to your .exe :P
22:23:26renesacis there a severe downside of having the executable file size increasing instead of having it in a separate file?
22:23:42renesacit is more convenient if it is embeded
22:23:44Araqor sudo it to /etc/bananajoe
22:23:46flaviuDepends on the quality of your virtual memory implementation.
22:24:27def-renesac: i'd like to be able to update the binary without transferring some embedded files all the time
22:25:03renesacthat could still be an option
22:25:32flaviudef-: I feel that this may be a case of premature optimization.
22:25:53def-flaviu: for me it's more about keeping a clean boundary
22:26:11def-much easier to just swap the unidecode.dat file without swapping the exe at the same time
22:26:16def-or even editting it by hand
22:27:08flaviufair enough then
22:27:08def-flaviu: and I'm already paying extra for traffic, so it's not premature for me
22:27:11renesacI think most users won't alter the unidecode.dat
22:27:44renesacand I still rarelly see delta updates for software
22:28:04renesacand it is less than 300kb
22:29:47renesacI will put at least some clarification on the documentation indicating that one should copy the unidecode.dat to it's own project
22:30:19renesacmaybe unidecode should be a nimble package
22:30:30renesacthat one could then add as a dependency
22:33:42*Sembei quit (Quit: WeeChat 1.2-dev)
22:35:03Araq+1 for making it a nimble package
22:35:10Araqdoesn't belong into the stdlib
22:40:11*filwit joined #nim
22:52:35*fizzbooze quit (Quit: WeeChat 1.1.1)
22:57:27*gsingh93 quit (Ping timeout: 265 seconds)
22:58:41*reem_ quit (Remote host closed the connection)
23:02:26*reem joined #nim
23:07:07*reem quit (Ping timeout: 244 seconds)
23:07:26*jefus_ joined #nim
23:11:05*jefus quit (Ping timeout: 250 seconds)
23:11:55*gsingh93 joined #nim
23:14:34*jholland joined #nim
23:17:42*Demos quit (Quit: leaving)
23:17:46*wink-s joined #nim
23:18:53*HakanD____ joined #nim
23:19:28*Trustable quit (Quit: Leaving)
23:23:02*HakanD____ quit (Ping timeout: 246 seconds)
23:28:58filwitso I've been thinking about working on object constructors soon, but while considering the code I realize Nim already has something that almost works similar to overload-by-returnType constructors: converters.. it's just they're currently limited
23:29:44filwitwould it not be better to extend converters to allow multiple parameters as almost a sugar for converters which took a tuple?
23:30:57filwitone sec
23:32:27filwitone sec
23:32:32filwitwhoops
23:34:15filwitokay, so what I mean clearly is:
23:34:27filwitproc newFoo(a, b:int): Foo = ...
23:34:37filwitcan be used like:
23:34:47filwitvar f = newFoo(1, 2)
23:34:55filwitvar f: Foo = (1, 2)
23:35:41filwitwhoops, damn.. `newFoo` is supposed to be a `converter` not a proc
23:36:37filwitanyways, that syntax is almost already possible today in Nim
23:36:59filwitconverter newFoo(t:tuple[a, b:int]): Foo = ...
23:37:22*yglukhov_ quit (Quit: Be back later ...)
23:38:14filwitbut you have to actually pass a tuple to 'newFoo', and withing newFoo you have to prefix all "parameters" with 't.'
23:40:01AraqI don't like ;-) surprising, huh?
23:41:31filwitWell I'm not entirely sure if this is the best either... one better thing about extending constructor syntax is that constructors are available to every type by default, while `var f: Foo = ()` is not a universal way to allocate an object.
23:43:13*a5i quit (Quit: Connection closed for inactivity)
23:43:16filwitthe thing is I can't help but feel like hijacking converters is more "seamless".. because this syntax is already part of Nim, it's almost feels like "less magic" going on
23:44:07filwitless magic than having constructors implicitly invoke a 'create' proc I mean
23:49:44flaviufilwit: I still think my proposal is the best ;)
23:49:46Araqconverters are not encouraged
23:50:18Araqit seems wrong to enhance them to get "constructors"
23:50:55flaviuThe central difference in my proposal is 'var f: Foo = ()' -> 'var f = Foo()'.
23:51:07EXetoCwhat's the purpose? do you need to invoke constructors generically? a convention like we have now seems fine to me
23:51:48flaviuFor me? Aesthetics.
23:52:33filwitEXetoC: good point, the converter syntax doesn't support generics well
23:53:16filwitflaviu: i'm not sure exactly what your proposal was, can you link me to where you talk about it?
23:53:45flaviuhttps://github.com/Araq/Nim/issues/1693
23:53:45EXetoCit's nice and short though
23:56:27filwitflaviu: i actually made what you originally suggest there already
23:56:39filwitflaviu: it doesn't work very well though
23:56:46flaviuhmm?
23:57:09filwiti'm trying to remember the problems I was having with it
23:57:34*a5i joined #nim
23:59:48*davidhq quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)