00:05:11 | * | gsingh93 joined #nim |
00:05:49 | * | sampwing quit (Ping timeout: 252 seconds) |
00:06:17 | * | sampwing joined #nim |
00:08:39 | * | dapz joined #nim |
00:16:27 | * | Varriount_ joined #nim |
00:18:07 | * | Varriount quit (Ping timeout: 255 seconds) |
00:38:34 | * | gokr1 joined #nim |
00:38:47 | * | gunn joined #nim |
00:39:36 | * | gokr quit (Ping timeout: 272 seconds) |
00:49:57 | * | irrequietus quit () |
00:53:58 | * | reem joined #nim |
00:57:08 | * | threewood quit (Ping timeout: 272 seconds) |
00:57:48 | * | jasondotstar joined #nim |
00:58:51 | * | reem quit (Ping timeout: 264 seconds) |
01:02:14 | * | reem joined #nim |
01:09:59 | * | sampwing quit (Ping timeout: 252 seconds) |
01:12:30 | * | dapz quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
01:15:06 | * | rational quit (Quit: Lost terminal) |
01:31:48 | * | dapz joined #nim |
01:31:52 | * | dapz quit (Max SendQ exceeded) |
01:41:36 | * | reem quit (Remote host closed the connection) |
01:42:11 | * | reem joined #nim |
01:45:04 | * | sillesta quit (Ping timeout: 264 seconds) |
01:47:28 | * | milosn quit (Ping timeout: 264 seconds) |
01:59:46 | onionhammer | Araq | Varriount NimLime now supports nimsuggest (on master) |
02:00:22 | onionhammer | well, just def, not sug|con |
02:02:34 | * | milosn joined #nim |
02:03:19 | flaviu | I have an ill-behaved program, is there some way to tell gnu parallel to output all the stdouts into a file instead of printing? |
02:04:17 | flaviu | oops, wrong channel |
02:04:19 | flaviu | lol |
02:08:47 | onionhammer | araq re:nimsuggest 'use' doesnt seem to work (if i understand how it's supposed to work) |
02:09:30 | onionhammer | araq I initialize w/ 1 file, then "use" another file, but it just returns empty > lines for subsequent def calls |
02:23:56 | * | darkf joined #nim |
02:26:16 | * | VinceAddons quit (Read error: Connection reset by peer) |
02:27:19 | flaviu | `.. image:: http://i.imgur.com/oCem13Y.png` doesn't seem to work on the form |
02:33:09 | * | ehaliewicz quit (Ping timeout: 245 seconds) |
02:37:50 | * | EXetoC quit (Ping timeout: 272 seconds) |
02:37:56 | * | reem quit (Remote host closed the connection) |
02:47:16 | fowlmouth | is that RST? |
02:48:31 | * | EXetoC joined #nim |
02:49:16 | * | flaviu quit (Read error: Connection reset by peer) |
02:49:16 | * | Mimbus quit (Read error: Connection reset by peer) |
02:52:38 | * | flaviu joined #nim |
02:54:22 | flaviu | yep, for the forum |
02:54:55 | * | Mimbus joined #nim |
02:58:57 | * | saml_ joined #nim |
03:09:14 | * | zahary1 quit (Quit: Leaving.) |
03:16:02 | * | noam_ quit (Read error: Connection reset by peer) |
03:16:35 | * | noam_ joined #nim |
03:19:04 | * | Danjcla quit (Ping timeout: 244 seconds) |
03:20:01 | * | sampwing joined #nim |
03:22:24 | * | Danjcla joined #nim |
03:35:13 | * | vendethiel quit (Ping timeout: 255 seconds) |
03:39:35 | * | sampwing quit (Ping timeout: 252 seconds) |
03:45:59 | * | vendethiel joined #nim |
04:03:09 | * | ehaliewicz joined #nim |
04:06:36 | * | vendethiel quit (Ping timeout: 244 seconds) |
04:15:50 | * | vendethiel joined #nim |
04:26:33 | * | EXetoC quit (Ping timeout: 276 seconds) |
04:38:10 | * | vendethiel quit (Ping timeout: 272 seconds) |
04:40:28 | * | brson joined #nim |
04:43:57 | * | vendethiel joined #nim |
04:51:20 | * | kapil__ joined #nim |
04:57:30 | * | gsingh93 quit (Quit: Connection closed for inactivity) |
05:07:00 | * | vendethiel quit (Ping timeout: 246 seconds) |
05:09:30 | * | saml_ quit (Quit: Leaving) |
05:39:30 | * | vendethiel joined #nim |
06:24:14 | * | Fusion_Gaming joined #nim |
06:26:03 | * | Boscop__ joined #nim |
06:27:08 | * | nande quit (Remote host closed the connection) |
06:27:11 | * | stonecolddevin quit (Ping timeout: 255 seconds) |
06:27:22 | * | stonecolddevin joined #nim |
06:27:26 | * | betawaffle quit (Excess Flood) |
06:27:34 | * | FusionGaming quit (Ping timeout: 255 seconds) |
06:28:44 | * | betawaffle joined #nim |
06:29:49 | * | Boscop_ quit (Ping timeout: 255 seconds) |
06:36:57 | * | vendethiel quit (Ping timeout: 246 seconds) |
06:39:30 | * | vendethiel joined #nim |
06:59:32 | Araq | ping onionhammer |
07:00:12 | * | vendethiel quit (Ping timeout: 244 seconds) |
07:02:15 | * | vendethiel joined #nim |
07:15:05 | Araq | "I initialize w/ 1 file, then "use" another file, but it just returns empty > lines for subsequent def calls" <-- I don't understand this |
07:25:36 | * | SplinterOfChaos quit (Ping timeout: 246 seconds) |
07:27:24 | dtscode | i dont understand either |
07:27:36 | dtscode | i dont understand why my code wont compile for that matter |
07:38:04 | * | SplinterOfChaos joined #nim |
07:54:32 | * | reem joined #nim |
07:58:41 | * | mytrile joined #nim |
08:12:58 | * | BlaXpirit joined #nim |
08:26:17 | * | bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
08:28:52 | * | BitPuffin quit (Ping timeout: 265 seconds) |
08:37:00 | * | Demon_Fox quit (Ping timeout: 246 seconds) |
08:37:03 | * | brson quit (Quit: leaving) |
08:43:25 | * | bjz joined #nim |
08:56:54 | * | VinceAddons joined #nim |
09:16:52 | * | vendethiel quit (Ping timeout: 264 seconds) |
09:17:44 | * | dumdum joined #nim |
09:23:10 | * | vendethiel joined #nim |
09:41:53 | * | gunn_ joined #nim |
09:43:22 | * | gunn quit (Ping timeout: 240 seconds) |
09:45:42 | * | Matthias247 joined #nim |
10:44:10 | * | akiradeveloper joined #nim |
10:44:31 | * | eigenlicht quit (Ping timeout: 255 seconds) |
10:45:33 | akiradeveloper | nim's resolving cycling dependency of modules is not easy to use. Have some plans to improve? |
10:49:18 | def- | akiradeveloper: don't have cyclic dependencies? |
10:50:03 | akiradeveloper | split a module into two modules in natural way for human often cause cyclic dependencies |
10:51:35 | akiradeveloper | another problem is Nim doesn't refer to symbol that's defined afterward. this makes it hard to write program in natural way too |
10:53:02 | akiradeveloper | it's ok if nim inherits C in this point. How can I write prototypes for proc and type? |
11:00:14 | def- | you can declare a proc and define it later |
11:00:34 | def- | haven't tried on types |
11:01:08 | Araq | you cannot do it for types, you can only have cyclic dependencies for types within a single 'type' section |
11:04:28 | BlaXpirit | C++ and Python both have nice solutions for cyclic dependencies |
11:04:34 | BlaXpirit | in Nim you're pretty much screwed |
11:07:17 | Araq | oh yeah, C++'s solution is really nice. "er, that's some incomplete struct then, you can only have pointers to it" |
11:07:30 | BlaXpirit | is really nice |
11:07:31 | * | kuzy000_ joined #nim |
11:08:05 | * | dumdum quit (Ping timeout: 256 seconds) |
11:08:18 | Araq | yeah, I am having fun with such a system right now. the scene has a camera the camera knows about the scene, etc etc etc |
11:08:18 | BlaXpirit | having non-pointers doesn't make sense |
11:09:03 | Araq | there is no lose coupling whatsoever in the system, but it's spreat out over hundreds of files, so it's "nice" |
11:09:14 | BlaXpirit | however messy my project's structure might be, I was able to implement it in Python and C++, not in Nim. |
11:09:26 | Araq | awww |
11:09:29 | akiradeveloper | same here ... A request have session, session handles a request... |
11:10:16 | akiradeveloper | define a proc later and nim can't find the symbol |
11:11:19 | akiradeveloper | I merged session and request module into one and resolved but I want them to be split for maintenance. include can't be the solution |
11:11:50 | BlaXpirit | well i've started thinking that it may be the only solution |
11:12:38 | BlaXpirit | can't find a reason why C++'s approach would not work |
11:26:05 | * | rational joined #nim |
11:26:43 | * | rational quit (Read error: Connection reset by peer) |
11:27:00 | * | rational joined #nim |
11:27:14 | * | rational quit (Client Quit) |
11:35:24 | akiradeveloper | is cstring is null terminated? |
11:37:12 | * | EXetoC joined #nim |
11:38:13 | BlaXpirit | akiradeveloper, cstring is a pointer to a sequence of bytes which should be null-terminated |
11:38:28 | akiradeveloper | thanks |
11:38:39 | BlaXpirit | akiradeveloper, string has a length and is also null-terminated for easy conversion to cstring |
11:38:57 | akiradeveloper | how can I make a cstring from a sequence of byte? |
11:39:10 | BlaXpirit | I can guess |
11:39:22 | BlaXpirit | cstring(add some_seq[0]) |
11:39:26 | BlaXpirit | cstring(addr some_seq[0]) |
11:39:52 | akiradeveloper | oh? that's great if it's possible. I will try |
11:43:09 | * | ehaliewicz quit (Ping timeout: 245 seconds) |
11:43:18 | akiradeveloper | it works! thanks |
11:44:45 | * | dumdum joined #nim |
12:00:29 | ekarlso | Araq: was there a query builder you said for nim sql ? |
12:05:57 | * | Mimbus quit (Remote host closed the connection) |
12:05:57 | * | flaviu quit (Remote host closed the connection) |
12:06:39 | BlaXpirit | akiradeveloper, wait a sec |
12:06:47 | BlaXpirit | that sequence of bytes must be 0 terminated |
12:11:09 | akiradeveloper | yes |
12:11:15 | akiradeveloper | for example |
12:11:37 | akiradeveloper | @['a', 'b', chr(0), 'c'] will be "ab" and the lenght is 2 |
12:11:59 | akiradeveloper | because of null-termination, the last 'c' is not counted in |
12:12:33 | akiradeveloper | how I can convert cstring to string? |
12:13:12 | EXetoC | with $ |
12:18:12 | akiradeveloper | oh... |
12:24:24 | * | saml_ joined #nim |
12:36:37 | * | gunn_ quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
12:41:11 | * | eigenlicht joined #nim |
12:43:48 | * | milosn quit (Ping timeout: 276 seconds) |
12:47:26 | * | reem quit (Remote host closed the connection) |
12:48:53 | * | BlaXpirit quit (Read error: Connection reset by peer) |
12:49:58 | * | BlaXpirit joined #nim |
12:53:17 | * | gunn joined #nim |
13:11:22 | * | akiradeveloper quit () |
13:13:13 | * | BitPuffin joined #nim |
13:17:07 | Araq | akiradeveloper, BlaXpirit there is another workaround btw |
13:17:08 | * | zahary joined #nim |
13:17:09 | Araq | type |
13:17:26 | Araq | AbstractFoo = object of RootObj |
13:17:39 | Araq | SomethingThatWantsConcrete = object |
13:17:49 | Araq | a: ref AbstractFoo |
13:17:56 | Araq | ... # some other module |
13:18:06 | Araq | type Concrete = object of AbstractFoo |
13:31:01 | dom96 | or you could just put your types in a file called types.nim? |
13:32:46 | * | milosn joined #nim |
13:41:54 | BlaXpirit | even that didn't give all the needed freedo |
13:41:55 | BlaXpirit | m |
13:54:53 | gtrundle | Araq: thanks for 2039 fix. |
13:54:55 | * | akiradeveloper joined #nim |
13:55:49 | Araq | gtrundle: strange that I missed that when I introduced regionized pointers |
13:56:07 | Araq | and even stranger that it wasn't triggered before even though the stdlib uses them |
13:56:30 | Araq | well actually |
13:56:53 | Araq | I think before the codegen used a different way to access the type so it remained hidden for some time |
14:06:43 | * | milosn quit (Ping timeout: 265 seconds) |
14:14:34 | dumdum | if I have two 'ref' variables a,b pointing to two heap objects, on a = b , b's content gets copied over to a's content? |
14:16:56 | BlaXpirit | no |
14:20:45 | dumdum | thanks |
14:22:04 | * | akiradeveloper quit () |
14:29:50 | * | kashyap___ joined #nim |
14:30:22 | kashyap___ | What's a good way to deal with addresses in the kernel. I just realized that arithmatic is not defined for unsigned integers |
14:30:36 | def- | import unsigned |
14:30:46 | dumdum | I have a bunch of color (r,g,b,a; int) values, any suggestion on easiest way(nim lib) to write an image file? |
14:30:56 | kashyap___ | thanks def- |
14:31:29 | * | renesac joined #nim |
14:31:32 | def- | dumdum: https://github.com/def-/nim-unsorted/blob/master/bitmap.nim#L64-L70 |
14:31:55 | dumdum | thanks! |
14:32:10 | ekarlso | meh, someone build me a query thing for sql :( |
14:32:32 | * | threewood joined #nim |
14:32:53 | Araq | ekarlso: I said there is an SQL parser in the stdlib, not a query builder |
14:33:27 | ekarlso | Araq: yeah and that makes making more advanced filtered queries a pain :| |
14:35:09 | BlaXpirit | kashyap___, there is also this http://blaxpirit.github.io/nim-csfml/csfml_graphics.html#newImage,cint,cint,ptr.uint8 http://blaxpirit.github.io/nim-csfml/csfml_graphics.html#saveToFile,Image,cstring |
14:36:00 | kashyap___ | BlaXpirit - you meant it for someone else I suppose |
14:36:10 | BlaXpirit | yes... sorry |
14:36:19 | ekarlso | i guess it's one of the missing things ;P |
14:36:37 | * | dumdum quit (Ping timeout: 256 seconds) |
14:36:38 | BlaXpirit | dumdum, ^ [:35:09] |
14:36:41 | kashyap___ | def- unsigned worked for arithmetic .. is there another import for boolean operations? |
14:37:02 | BlaXpirit | what do you mean |
14:37:03 | kashyap___ | or I just have to cast? |
14:37:21 | BlaXpirit | if i understand the question correctly, yes |
14:37:56 | * | darkf quit (Quit: Leaving) |
14:39:12 | dom96 | Araq: Do we want to apply for GSoC this year? |
14:40:25 | EXetoC | kashyap___: operations for signed integers, bools and so on are in the system module, so they are imported implicitly |
14:41:54 | * | mal`` joined #nim |
14:43:20 | EXetoC | kashyap___: the types and operations are exposed as procs, as you can see in the documentation for that module |
14:44:00 | kashyap___ | EXetC looks like system was getting processed even without me importing |
14:44:30 | kashyap___ | importing system caused lib/system.nim(1, 1) Error: redefinition of 'system' |
14:44:44 | EXetoC | it's always imported, so don't do that |
14:45:37 | kashyap___ | oops I misread your message .. okay, I am looking for boolean operations on unsigned integers |
14:46:38 | * | noam__ joined #nim |
14:46:38 | Araq | use uint(x) or bool(x) type conversions |
14:48:18 | * | noam_ quit (Ping timeout: 244 seconds) |
14:49:27 | * | Sphax_ joined #nim |
14:49:33 | * | Sphax_ quit (Client Quit) |
14:53:14 | EXetoC | I was being a little vague though |
14:54:44 | dom96 | Araq: GSoC Y/N? |
14:58:07 | Araq | Y |
14:59:34 | dom96 | You will probably need to be the org admin then. |
15:06:20 | Araq | what's the deadline? |
15:06:48 | * | milosn joined #nim |
15:09:01 | def- | Araq: February 20 |
15:10:50 | Araq | are we allowed to ... er ... reuse everything from 2014? |
15:11:49 | def- | I've seen other projects reuse ideas every year too |
15:12:02 | dom96 | sure |
15:12:08 | * | mal`` quit (Quit: ERC Version 5.3 (IRC client for Emacs)) |
15:12:45 | dom96 | We need to improve our ideas though. |
15:13:42 | dom96 | http://forum.nim-lang.org/t/814 |
15:16:31 | * | mal`` joined #nim |
15:16:42 | * | dumdum joined #nim |
15:30:26 | * | threewood quit () |
15:32:38 | * | mytrile left #nim (#nim) |
15:35:51 | dom96 | Do we have any Googler's here? |
15:36:26 | EXetoC | I'm quite good at googling |
15:36:59 | dom96 | *Google employees :P |
15:37:42 | * | sillesta joined #nim |
15:40:08 | renesac | dom96: do you still have that irc log on the reasons why nimrod wasn't selected? |
15:40:14 | renesac | for gsoc |
15:40:34 | dom96 | I thought I saved it but I can't find it :\ |
15:40:52 | renesac | search nimrod irc logs for the link |
15:40:56 | renesac | and hope it didn't rot |
15:43:55 | dom96 | https://gist.github.com/dom96/9273843 |
15:43:56 | dom96 | Found it |
15:44:19 | EXetoC | *Nim :-) |
15:46:08 | renesac | EXetoC: it was nimrod at the time |
15:46:11 | renesac | ;) |
15:46:52 | renesac | https://github.com/Araq/Nim/issues/936#issuecomment-72322488 <-- is the first overload supposed to work and have higher priority than (a:int, b:int)? |
15:47:03 | * | mal`` quit (Ping timeout: 252 seconds) |
15:50:43 | BlaXpirit | renesac, https://github.com/Araq/Nim/issues/1890? |
15:52:48 | renesac | hum, yeah, probably |
15:53:50 | BlaXpirit | u may want to add reference to issue |
15:55:33 | renesac | I'm not really sure it is the same issue |
15:56:41 | BlaXpirit | ok |
15:56:49 | BlaXpirit | i don't really understand |
15:57:10 | BlaXpirit | but hmm looks very similar |
15:57:43 | renesac | yeah, maybe the root cause is the same |
16:00:48 | * | kapil__ quit (Quit: Connection closed for inactivity) |
16:10:10 | dumdum | This: https://github.com/def-/nim-unsorted is great addition to nim tutorial :D |
16:11:33 | dtscode | if i have a type Foo* = object, with member bar, and then import the module it an another file, i can use it by creating an instance of Foo (ie var baz: Foo) and then use baz.bar right? |
16:12:40 | dumdum | yes if its baz* |
16:12:51 | * | kuzy000_ quit (Read error: Connection reset by peer) |
16:13:08 | dumdum | sorry |
16:13:10 | dumdum | bar* |
16:13:21 | dtscode | oh you have to * all of the members too? |
16:13:31 | dtscode | thanks dumdum |
16:13:37 | dumdum | yes |
16:14:04 | dtscode | guess that makes sense, to simulate private and public scope |
16:14:04 | dumdum | '*' only on public members |
16:14:11 | dtscode | yeah |
16:20:53 | * | noam__ quit (Ping timeout: 240 seconds) |
16:27:32 | * | sdw_ joined #nim |
16:32:47 | * | dumdum quit (Ping timeout: 256 seconds) |
16:45:23 | * | dumdum joined #nim |
16:46:40 | * | saml_ quit (Remote host closed the connection) |
16:48:23 | * | kuzy000 joined #nim |
16:52:13 | * | kuzy000 quit (Remote host closed the connection) |
16:52:37 | * | clone1018_ quit (Quit: No Ping reply in 180 seconds.) |
16:53:03 | * | Triplefox quit (Quit: No Ping reply in 180 seconds.) |
16:54:58 | * | clone1018_ joined #nim |
16:54:59 | * | Triplefox joined #nim |
16:56:33 | * | gunn quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
17:00:13 | EXetoC | dtscode: it seems like the same thing, but without the descriptive names |
17:00:40 | * | UberLambda joined #nim |
17:01:12 | * | UberLambda quit (Client Quit) |
17:01:14 | * | mal`` joined #nim |
17:01:55 | * | UberLambda joined #nim |
17:05:37 | * | kuzy000 joined #nim |
17:14:21 | * | AtomicBool joined #nim |
17:14:26 | AtomicBool | hello |
17:15:23 | UberLambda | hi |
17:18:41 | * | dumdum quit (Ping timeout: 256 seconds) |
17:19:27 | AtomicBool | whats gucci |
17:19:52 | EXetoC | A posh brand |
17:20:28 | EXetoC | sup |
17:20:35 | AtomicBool | lol |
17:24:18 | AtomicBool | Just studying Atomic types in rust |
17:28:04 | * | matkuki joined #nim |
17:31:02 | UberLambda | [offtopic] Anyone using LLVM Ocaml here? I'm trying to compile the Kaleidoscope tutorial but it seems outdated |
17:33:34 | matkuki | BlaXpirit: Just tried your random module. Good stuff, thanks. Great for porting from Python. |
17:38:44 | BlaXpirit | it's not actually porting from python |
18:04:13 | * | mytrile joined #nim |
18:10:27 | * | Fusion_Gaming is now known as FusionGaming |
18:29:29 | * | flaviu joined #nim |
18:30:21 | * | scottj joined #nim |
18:34:46 | * | Matthias247 quit (Read error: Connection reset by peer) |
18:44:57 | * | EXetoC quit (Quit: WeeChat 1.0.1) |
18:55:49 | onionhammer | ping araq |
18:56:01 | matkuki | BlaXpirit: I know. I meant I'm porting some code from Python and all I had to do is a little renaming. |
18:56:38 | onionhammer | is 'use' meant to say use this file? |
19:03:47 | onionhammer | basically i cant do lookups from 2 tabs/files without restarting nimsuggest araq |
19:11:07 | AtomicBool | .eval echo(0x0539); |
19:11:16 | * | renesac quit (Quit: Page closed) |
19:11:39 | AtomicBool | #nim-offtopic |
19:17:40 | * | Varriount|Mobile joined #nim |
19:23:14 | * | Mimbus joined #nim |
19:23:57 | flaviu | AtomicBool: sorry about that, fixed. |
19:24:11 | AtomicBool | .eval echo(0x0539); |
19:24:13 | AtomicBool | its fine |
19:24:16 | Mimbus | AtomicBool: 1337 |
19:24:39 | AtomicBool | is Mimbus written in Nim? |
19:27:06 | flaviu | Yep, written by dtscode |
19:28:16 | flaviu | btw, semicolons mean different things to the bot as compared to nim: |
19:28:17 | flaviu | .eval echo(escape(""";;;;;;""")) |
19:28:20 | Mimbus | flaviu: "\x0A\x0A\x0A\x0A\x0A" |
19:28:26 | AtomicBool | yeah ik |
19:31:46 | * | Varriount|Laptop joined #nim |
19:32:22 | * | Varriount|Mobile quit (Quit: AndroIRC - Android IRC Client ( http://www.androirc.com )) |
19:32:51 | * | Demon_Fox joined #nim |
19:42:45 | * | alexruf joined #nim |
19:43:20 | * | alexruf quit (Max SendQ exceeded) |
19:48:05 | * | alexruf joined #nim |
19:53:27 | vendethiel | reading nim's manual now, I realize that you might have a *lot* of pragmas littered in your, and so I'm wondering: why {. .} ? |
19:53:53 | vendethiel | at first I thought it was only for c-style, low-level stuff, bindings, etc, that you'd have more inside of a compiler/stdlib that tries to optimize everything, but apparently not |
19:57:08 | * | sillesta quit (Ping timeout: 272 seconds) |
20:00:18 | * | brson joined #nim |
20:01:53 | matkuki | vendethiel: You mean why the characters "{. .}" are used, or why so many pragmas? |
20:12:57 | * | dapz joined #nim |
20:16:43 | vendethiel | matkuki: both :P |
20:18:14 | matkuki | "{. .}" looks nice to me, but you should ask Araq about that. |
20:18:16 | matkuki | As to why so many pragmas, I think the first line on Pragmas in the Nim manual says it all. |
20:21:30 | vendethiel | matkuki: ha, it looks like a corner case to me, but well :-) to each his own |
20:25:08 | * | sillesta joined #nim |
20:26:02 | * | dumdum joined #nim |
20:28:44 | * | ehaliewicz joined #nim |
20:29:22 | * | dapz quit (Ping timeout: 240 seconds) |
20:34:21 | * | gtrundle quit (Ping timeout: 265 seconds) |
20:36:46 | * | Varriount|Laptop quit (Ping timeout: 246 seconds) |
20:39:51 | * | dumdum quit (Ping timeout: 256 seconds) |
20:41:30 | * | matkuki quit (Quit: ChatZilla 0.9.91.1 [Firefox 35.0.1/20150122214805]) |
20:54:26 | AtomicBool | how old is Nim |
20:57:47 | * | Varriount|Laptop joined #nim |
20:58:48 | flaviu | AtomicBool: The oldest commit is on Sun Jun 22 16:14:11 2008 |
20:59:16 | AtomicBool | i see |
21:06:35 | ekarlso | .eval @["foo", "bar"].join(" ") |
21:06:38 | Mimbus | ekarlso: eval.nim(3, 15) Error: value of type 'string' has to be discarded |
21:22:08 | * | UberLambda quit (Quit: Leaving the Matrix) |
21:23:40 | * | AtomicBool left #nim (#nim) |
21:26:48 | ekarlso | so quiet here :| |
21:26:53 | ekarlso | flaviu: any more cool ideas for pkg ? |
21:28:33 | * | duncanmv joined #nim |
21:28:38 | * | EXetoC joined #nim |
21:29:24 | duncanmv | What is the equivalent of an interface/trait in nim? If I want a struct to contain something that could be a seq of bytes, but this could be a string, or a mmaped file, or anything implementing some set of methods? |
21:29:57 | def- | user defined typeclass |
21:30:54 | duncanmv | does the standard library uses them already? |
21:30:59 | def- | Or maybe do something with streams: http://nim-lang.org/streams.html |
21:31:03 | def- | duncanmv: don't think so |
21:31:06 | duncanmv | (eg a file and a string having some common interface?) |
21:31:47 | Araq | vendethiel: well you got it. at first pragmas where only for C interop so I didn't mind the somewhat ugly syntax. Now it's used for ... everything |
21:31:49 | def- | in the case of an mmaped file and a string, a cast would be good enough actually, i think |
21:32:21 | vendethiel | Araq: would you change it if you could? |
21:32:50 | Araq | vendethiel: not really. I've grown to like it |
21:32:57 | vendethiel | alright, that works as well :-) |
21:33:27 | Araq | it could easily be replaced with {} except for a few edge cases, perhaps |
21:33:33 | * | alexruf quit (Quit: Textual IRC Client: www.textualapp.com) |
21:34:07 | Araq | but then we have 2 ways of writing the same and the fraction who is confused by everything will be confused and complain |
21:35:12 | flaviu | Araq: It would also be ambiguous. what does `{ foo: "asdasda" }` mean? |
21:35:39 | Araq | flaviu: yeah that's the edge case I'm talking about ;-) |
21:36:05 | Araq | onionhammer: 'use' doesn't do what you think it does |
21:36:14 | * | FusionGaming quit (Read error: Connection reset by peer) |
21:42:39 | flaviu | I may just not understand C++, but how does it do "no gc" when it has reference counted shared_ptr? |
21:43:10 | reactormonk | flaviu, that's no gc, because it's done locally. GC is globally. |
21:44:57 | flaviu | reactormonk: So replacing Nim's GC with reference counting lets me say Nim doesn't use GC? |
21:45:22 | reactormonk | flaviu, I'd say so. Have fun with loops. |
21:45:53 | flaviu | pfft, who cares about performance ;) |
21:46:11 | reactormonk | nah, I mean looping structures |
21:46:59 | flaviu | Oh, I see. Well, C++ has boost::weak_ptr, I assume it uses that to deal with loops. |
21:47:26 | onionhammer | Araq what does it do? |
21:47:46 | onionhammer | and how do I get definitions in a different file w/o restarting nimsuggest? |
21:48:35 | Araq | it's simply "find usages" |
21:48:39 | onionhammer | ahh |
21:48:40 | onionhammer | cool |
21:48:48 | Araq | and only works properly on definitions, I'm afraid |
21:48:48 | * | Jesin joined #nim |
21:49:14 | onionhammer | couldnt u go-to-definition on a reference and then find usages from there (seemlessly)? |
21:49:38 | Araq | yeah but that requires a restart |
21:50:02 | onionhammer | so going back to def; |
21:50:06 | onionhammer | how do i handle multiple tabs? |
21:50:40 | Araq | well you can only query all the modules that the project actually uses |
21:51:20 | Araq | but I can add a "add/compile this module too" |
21:51:27 | onionhammer | that would be nice |
21:51:38 | Araq | I'm not sure |
21:51:45 | reactormonk | Araq, what does the experimental macro do? |
21:52:08 | Araq | reactormonk: it's a pragma that enables all the stuff that's unstable |
21:52:17 | Araq | or that we're unsure what to do with |
21:53:07 | Araq | onionhammer: well that will be confusing, perhaps. |
21:53:40 | onionhammer | Araq so here's the use case.. I have a 'test1.nim' which imports 'test2.nim', which imports 'test3.nim', but when I go-to-def on test1.nim -> test2.nim, no go-to-defs work within test2 |
21:53:43 | onionhammer | I just get empty lines |
21:55:37 | Araq | let me try this |
21:58:41 | Araq | nope. works |
21:59:25 | Araq | I'm not sure you understood that it works only on the given *project* |
22:00:47 | Araq | and it only recompiles what changed |
22:01:46 | onionhammer | right, but i have a "project" |
22:01:59 | onionhammer | i.e. kind of an entry module which references other modules |
22:02:05 | onionhammer | i'll try again though |
22:02:55 | Araq | but yeah, we need a dirty command |
22:03:17 | onionhammer | ok, it seems to be working now. I'll re-test on the machine that wasnt workin |
22:03:32 | Araq | to tell nimsuggest that a file has been modified |
22:03:55 | Araq | cause right now it only dirties the file that you give to it via def|sug|... |
22:05:27 | onionhammer | so.. doing an "add" isnt possible? |
22:05:41 | onionhammer | like if I pull up an unreferenced module that isnt in there yet |
22:05:59 | * | ehaliewicz quit (Ping timeout: 256 seconds) |
22:06:01 | onionhammer | and I want to start doing lookups |
22:06:40 | Araq | well actually I'm wrong, it does a crc checksum check to determine whether it needs recompilations |
22:06:58 | Araq | and to 'add' you simply 'import' it somewhere in your project |
22:08:04 | Araq | try it |
22:08:08 | Araq | works for me |
22:08:21 | onionhammer | yeah, but im saying if you open a nim file that *isnt* referenced yet |
22:08:32 | onionhammer | it'd be nice to still be able to do lookups w/o another nimsuggest instance |
22:08:49 | * | Sornaensis joined #nim |
22:08:57 | Araq | hi Sornaensis welcome |
22:09:09 | Sornaensis | hi |
22:09:16 | Araq | onionhammer: yeah, as I said, I tried to keep implementation complexity reasonable |
22:09:55 | Araq | we can add this feature, but it might end up confusing since the editor pretends it works on a file basis, when it really does not |
22:10:15 | onionhammer | Araq understandable; I dont want to overcomplicate things, but it'd be nice from an end-user perspective if we can make it work how one would expect |
22:10:28 | onionhammer | i.e. "I open up a nim file, hit go-to-definition, and it works" |
22:10:43 | Araq | well what about 'include' files? |
22:10:54 | onionhammer | how do you mean? |
22:10:58 | Araq | usually these cannot be compiled on their own |
22:11:08 | Araq | you can only compile the module that includes them |
22:11:16 | onionhammer | brb |
22:12:04 | * | Pisuke quit (Quit: WeeChat 1.2-dev) |
22:13:08 | * | Sembei joined #nim |
22:14:43 | onionhammer | back |
22:14:44 | * | ehaliewicz joined #nim |
22:14:53 | onionhammer | araq i think it would be perhaps just 'best effort' |
22:15:12 | onionhammer | for example, im not really working within a project, I'm working in a directory of independent utility modules |
22:15:25 | onionhammer | but i cant really switch between them and work on each one as i want to without restarting nimsuggest |
22:15:35 | onionhammer | but they're all in the same directory |
22:15:44 | * | Danjcla quit (Ping timeout: 244 seconds) |
22:15:48 | Araq | no, you can restart with a different port |
22:16:27 | onionhammer | well, it's stdin |
22:16:55 | Araq | if you don't start with --stdin nimsuggest uses sockets |
22:17:24 | onionhammer | right |
22:17:40 | * | Danjcla joined #nim |
22:17:49 | Araq | thing is |
22:18:00 | onionhammer | araq can you perhaps think through this scenario a bit and recommend how you would handle this for ides? |
22:18:05 | onionhammer | that sort of thing should be documented a bit.. |
22:18:24 | onionhammer | like do I keep a hashtable of which files came back FROM the tool and which didnt? |
22:18:51 | onionhammer | because if the module came back from the tool, i dont need to start a new instance when someone calls def on it |
22:18:52 | Araq | I'm not sure if my visual studio does autocomplete for files that I just open with it |
22:19:10 | Araq | and that are not part of my project/solution |
22:19:12 | Araq | let's see |
22:19:14 | onionhammer | not without a csproj (for example) |
22:19:25 | flaviu | I have an interesting use of "include": Accessing private procedures for unit testing. |
22:19:26 | onionhammer | but thats because theres no assemblies etc linked in afaik |
22:21:07 | onionhammer | araq what about just allowing you to use the entire directory when you initialize nimsuggest |
22:21:19 | onionhammer | nimsuggest --stdin . |
22:22:07 | onionhammer | brb |
22:22:37 | Araq | just tested. my visual studio doesn't give a shit about files that are not referenced in my solution |
22:24:38 | Araq | er ... do you plan to use --stdin in your editor plugin? o.O |
22:28:25 | Araq | flaviu: 'include' is generally useful for code injections into modules |
22:31:07 | * | bmaxa joined #nim |
22:31:15 | dom96 | ldlework: You around? |
22:34:16 | * | kuzy000 quit (Ping timeout: 264 seconds) |
22:35:48 | reactormonk | Araq, sockets? How are they exposed? |
22:40:23 | * | ehaliewicz quit (Remote host closed the connection) |
22:41:04 | Araq | reactormonk: well nimsuggest is a server. |
22:41:44 | reactormonk | Araq, via ::1 or file socket? |
22:42:06 | Araq | via Nim's net module |
22:42:27 | * | kuzy000_ joined #nim |
22:44:42 | reactormonk | so localhost |
22:45:28 | Araq | I think it works remotely too |
22:45:36 | Araq | but yeah, usually localhost |
23:00:31 | * | duncanmv left #nim ("Ex-Chat") |
23:05:21 | * | onionhammer quit (Quit: WeeChat 1.0.1) |
23:09:16 | * | reem joined #nim |
23:12:04 | * | kuzy000_ quit (Ping timeout: 264 seconds) |
23:21:47 | * | scottj left #nim (#nim) |
23:28:23 | * | vendethiel- joined #nim |
23:30:33 | * | vendethiel quit (Ping timeout: 276 seconds) |
23:30:42 | ldlework | dom96 hi |
23:35:52 | * | matkuki joined #nim |
23:36:15 | matkuki | BlaXpirit: You there? |
23:36:25 | BlaXpirit | hi |
23:37:34 | matkuki | I'm compiling with "--deadCodeElim:on" and get this error: random\random.nim(141, 9) Error: internal error: expr: var not init :envP_161514 |
23:37:59 | BlaXpirit | https://github.com/BlaXpirit/nim-random/issues/2 |
23:38:44 | matkuki | Thanks. |
23:40:19 | matkuki | I'm using "--deadCodeElim:on" to try to get a program to work on Windows XP. It was suggested on the forum. Any other solution for this? |
23:41:17 | * | gtrundle joined #nim |
23:41:29 | def- | matkuki: ha, just got the exact same error and wanted to report to BlaXpirit |
23:41:38 | BlaXpirit | :s |
23:41:42 | BlaXpirit | what am i supposed to do |
23:41:48 | def- | fix the compiler! |
23:41:50 | matkuki | def-: Jinx :) |
23:42:04 | def- | i get this on linux too though |
23:43:15 | * | Grauwolf quit (Ping timeout: 264 seconds) |
23:43:37 | * | Varriount__ joined #nim |
23:43:51 | * | no_name quit (Ping timeout: 264 seconds) |
23:44:37 | * | no_name joined #nim |
23:46:44 | matkuki | Is the warning in this code a problem: https://bpaste.net/show/1e3f478dc8d9 ? |
23:46:52 | * | Varriount_ quit (Ping timeout: 264 seconds) |
23:47:30 | Araq | that's just https://github.com/Araq/Nim/issues/2023 |
23:47:39 | Araq | which I'm already working on |
23:47:52 | * | Varriount|Laptop quit (Ping timeout: 246 seconds) |
23:48:28 | Araq | matkuki: no but your horrible formating is ;-) |
23:48:47 | Araq | var foo: int, not var foo :int |
23:49:01 | Araq | this is not ruby with its sigils |
23:49:24 | BlaXpirit | such formatting totally makes sense to me |
23:49:53 | BlaXpirit | the only reason it looks weird is it doesn't follow english rules of punctuation |
23:51:31 | matkuki | Araq: Sorry, CoDeSys coding side-effect. Coded Beckhoff PLC's and got used to it. |
23:51:41 | * | sillesta quit (Ping timeout: 264 seconds) |
23:52:02 | matkuki | But as BlaXpirit says, I find it oddly pleasing :) |
23:52:57 | Araq | it annoys me so much I'll change the compiler to disallow it |
23:53:07 | flaviu | :O |
23:53:08 | Araq | (just kidding) |
23:53:15 | matkuki | Thank god! |
23:53:42 | flaviu | Araq: Wouldn't it be hard to do anyway? You'd have to mess with the tokenizer, I think. |
23:54:36 | Araq | the tokenizer is usually the easiest part in a compiler |
23:55:07 | flaviu | Yeah, but if you change the emitted tokens, there's a high chance of introducing weird bugs higher up. |
23:55:20 | BlaXpirit | pls |
23:56:09 | flaviu | Although I guess you could do the checks in the tokenization for `:`, and emit an error if the left spacing > 0 and the right spacing = 0; just ignore me. |
23:56:39 | Araq | flaviu: you only have to emit an error token instead to tkColon when there is whitespace before the colon |
23:57:01 | Araq | it's perhaps 3 lines of code |
23:57:08 | Araq | if not one |
23:57:50 | matkuki | Please don't go there! You two are starting to scare me. |
23:58:08 | def- | BlaXpirit: so, can't use the random library right now? |
23:58:22 | BlaXpirit | why not |
23:58:29 | BlaXpirit | don't use deadcodeelim |
23:58:29 | def- | BlaXpirit: i wanted to demonstrate that a benchmark of languages using random is useless, because it depends on the rng |
23:58:40 | def- | BlaXpirit: i don#t have deadcodeelim activated |
23:58:52 | BlaXpirit | dont use release then |
23:59:07 | def- | too slow code |
23:59:12 | def- | ok, will try^^ |
23:59:46 | BlaXpirit | use nim 0.9.4 :| |
23:59:48 | def- | no, same without -d:release |