00:00:23 | cheatfate | openbsd is just good os to compile for security and read warnings :) |
00:01:43 | Varriount | Hrm. I just tried Visual Studio Code. I like the interface, but the memory usage worries me... 5 processes totalling 107 Mb for no files open? |
00:02:24 | Varriount | Even using Python as a plugin language, Sublime Text only uses 27 Mb, and that's with around 10 files open. |
00:05:12 | pigmej | well my emacs takes "a bit more" |
00:05:37 | * | vendethiel quit (Ping timeout: 240 seconds) |
00:05:48 | Varriount | pigmej: 20 processes and 500 Mb? |
00:06:32 | * | desophos quit (Remote host closed the connection) |
00:06:49 | pigmej | well, do we count whole tree ? |
00:07:46 | pigmej | Varriount: ^ |
00:07:57 | Varriount | pigmej: I guess? I was kinda being sarcastic - I was under the impression that emacs would be fairly lightweight, compared to Sublime Text or VS Code. |
00:09:05 | pigmej | ah |
00:09:21 | pigmej | well I think my full blown emacs daemon mode with tons of stuff takes ~1GB |
00:09:29 | * | toaoMgeorge joined #nim |
00:10:13 | Varriount | O_o |
00:10:16 | pigmej | well, 250MB RSS, 1,1GB VSZ :) |
00:10:33 | Varriount | pigmej: What about bare, out-of-the-box state? |
00:10:41 | * | desophos joined #nim |
00:10:45 | pigmej | Varriount: but well, I have email client there, irc client there, .... |
00:10:49 | * | filwit quit (Ping timeout: 240 seconds) |
00:11:43 | pigmej | and emacs says that I have 240 buffers opened |
00:12:53 | pigmej | Varriount: my emacs is kinda "big" |
00:12:57 | pigmej | vanilla emacs hmm... |
00:13:08 | pigmej | hard to say, probably quite memory efficient |
00:15:10 | * | desophos quit (Ping timeout: 244 seconds) |
00:37:17 | * | arnetheduck joined #nim |
00:45:35 | * | Trustable quit (Remote host closed the connection) |
00:55:34 | * | BitPuffin|osx joined #nim |
00:55:45 | * | gmpreussner quit (Ping timeout: 246 seconds) |
00:57:56 | * | gmpreussner joined #nim |
01:05:17 | * | [CBR]Unspoken quit (Ping timeout: 244 seconds) |
01:10:09 | * | MyMind quit (Excess Flood) |
01:11:16 | * | MyMind joined #nim |
01:20:55 | * | [CBR]Unspoken joined #nim |
01:52:32 | * | Jesin quit (Quit: Leaving) |
01:54:14 | * | Jesin joined #nim |
02:30:57 | * | desophos joined #nim |
02:35:25 | * | desophos quit (Ping timeout: 252 seconds) |
02:36:38 | * | desophos_ is now known as desophos |
03:08:21 | * | Demon_Fox joined #nim |
03:12:17 | * | brson quit (Quit: leaving) |
03:15:25 | * | francisl joined #nim |
03:16:14 | * | vendethiel joined #nim |
03:22:49 | * | vendethiel quit (Ping timeout: 240 seconds) |
03:47:31 | * | BitPuffin|osx quit (Ping timeout: 244 seconds) |
03:55:45 | * | Vivek quit (Remote host closed the connection) |
03:57:21 | * | vendethiel joined #nim |
04:09:05 | * | Vivek joined #nim |
04:36:01 | * | desophos quit (Read error: Connection reset by peer) |
04:41:15 | * | wuehlmaus quit (Quit: Lost terminal) |
04:54:20 | * | brson joined #nim |
05:00:24 | * | vendethiel quit (Ping timeout: 246 seconds) |
05:09:31 | * | exebook quit (Read error: Connection reset by peer) |
05:18:34 | * | francisl quit (Quit: francisl) |
05:24:18 | * | arnetheduck quit (Remote host closed the connection) |
05:41:32 | * | gokr joined #nim |
05:49:00 | * | gokr quit (Quit: Leaving.) |
05:49:12 | * | gokr joined #nim |
06:03:41 | cheatfate | Varriount, why you are looking for something if you have ST3? |
06:11:57 | * | yglukhov joined #nim |
06:14:11 | * | arnetheduck joined #nim |
06:18:30 | * | gokr quit (Quit: Leaving.) |
06:31:39 | arnetheduck | hi.. finished, in system.nim, currently depends on emit and the specifics of how the c generator implements closures.. would this be a good candidate for a magic? |
06:35:50 | * | brson quit (Quit: leaving) |
06:41:40 | * | yglukhov quit (Remote host closed the connection) |
06:58:57 | * | yglukhov joined #nim |
07:00:25 | * | rok joined #nim |
07:05:57 | * | gokr joined #nim |
07:11:39 | * | rok quit (Ping timeout: 260 seconds) |
07:12:04 | * | rok joined #nim |
07:24:33 | * | wuehlmaus joined #nim |
07:33:20 | * | Gonzih joined #nim |
07:54:33 | * | vendethiel joined #nim |
07:57:42 | * | gokr quit (Quit: Leaving.) |
08:01:10 | * | desophos joined #nim |
08:05:25 | * | desophos quit (Ping timeout: 252 seconds) |
08:06:12 | * | chrishel_ quit (Remote host closed the connection) |
08:28:39 | * | allan0 quit (Ping timeout: 260 seconds) |
08:30:14 | * | darkf_ joined #nim |
08:33:34 | * | darkf quit (Ping timeout: 248 seconds) |
08:36:10 | * | yglukhov quit (Remote host closed the connection) |
08:50:32 | * | yglukhov joined #nim |
08:54:53 | * | yglukhov quit (Remote host closed the connection) |
09:00:08 | * | Trustable joined #nim |
09:09:52 | * | yglukhov joined #nim |
09:15:07 | * | yglukhov quit (Remote host closed the connection) |
09:16:08 | * | yglukhov joined #nim |
09:18:27 | * | Arrrr joined #nim |
09:18:38 | * | Arrrr quit (Changing host) |
09:18:38 | * | Arrrr joined #nim |
09:19:12 | * | yglukhov quit (Remote host closed the connection) |
09:24:23 | * | Gonzih quit (Ping timeout: 244 seconds) |
09:30:04 | * | darkf_ quit (Quit: Leaving) |
09:34:14 | * | boopsiesisaway is now known as boopsies |
09:43:21 | * | yglukhov joined #nim |
09:45:58 | * | Ven joined #nim |
10:14:01 | * | zxtx quit (Ping timeout: 240 seconds) |
10:16:33 | * | zxtx joined #nim |
10:18:05 | * | bjz_ quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
10:18:54 | * | toaoMgeorge quit (Quit: Bye) |
10:19:17 | * | toaoMgeorge joined #nim |
10:21:27 | * | bjz joined #nim |
10:27:07 | * | tdc quit (Quit: Bye bye) |
10:28:12 | * | desophos joined #nim |
10:32:48 | * | desophos quit (Ping timeout: 276 seconds) |
10:58:47 | * | vendethiel quit (Ping timeout: 260 seconds) |
11:06:05 | * | StarBrilliant quit (Quit: ZNC - http://znc.in) |
11:09:16 | * | allan0 joined #nim |
11:14:55 | * | krux02 joined #nim |
11:40:13 | * | NimBot1 quit (Remote host closed the connection) |
11:43:06 | * | Gonzih joined #nim |
11:52:13 | * | NimBot joined #nim |
11:54:10 | * | BitPuffin|osx joined #nim |
11:55:18 | * | krux02 quit (Remote host closed the connection) |
12:12:54 | * | BitPuffin|osx quit (Ping timeout: 276 seconds) |
12:14:36 | * | vendethiel joined #nim |
12:23:07 | * | kulelu88 joined #nim |
12:23:08 | * | kulelu88 quit (Changing host) |
12:23:08 | * | kulelu88 joined #nim |
12:32:07 | * | toaoMgeorge quit (Ping timeout: 260 seconds) |
12:32:48 | * | toaoMgeorge joined #nim |
12:35:05 | * | francisl joined #nim |
12:35:51 | * | vendethiel quit (Ping timeout: 264 seconds) |
12:59:54 | * | Gonzih quit (Ping timeout: 260 seconds) |
13:00:54 | * | Gonzih joined #nim |
13:04:15 | * | allan0 quit (Ping timeout: 276 seconds) |
13:09:48 | * | vendethiel joined #nim |
13:17:38 | * | allan0 joined #nim |
13:19:48 | * | francisl quit (Quit: francisl) |
13:22:40 | * | rok quit (Quit: rok) |
13:56:37 | * | Trustable quit (Quit: Leaving) |
14:20:50 | * | Ven quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
14:37:23 | * | vonh2 quit (Ping timeout: 248 seconds) |
15:10:16 | Varriount | arnetheduck: Probably, if it is to work in a cross-backend manner. |
15:11:11 | Varriount | cheatfate: Well, I like to see how editors stack up against ST3. |
15:12:29 | Varriount | cheatfate: My only... annoyance with ST3 right now is that there are so many things that aren't currently allowed by the API, like the receiving of mouse events. |
15:25:09 | * | desophos joined #nim |
15:36:24 | * | exebook joined #nim |
16:14:39 | * | kulelu88 left #nim ("Leaving") |
16:16:49 | * | BitPuffin|osx joined #nim |
16:19:35 | * | uryga joined #nim |
16:22:17 | * | rok joined #nim |
16:23:23 | uryga | hey everyone, where's the right place to ask about syntax things? as in, "why is X like this and not different" |
16:23:45 | uryga | Python has PEPs which you can refer to, something like that for nim? |
16:27:02 | dom96 | uryga: You can ask here, in the forum or even on Github. |
16:27:19 | dom96 | Although Github is more suited for discussions surrounding issues/features rather than questions. |
16:28:29 | * | Arrrr_ joined #nim |
16:29:50 | uryga | cool. I was wondering about constructs that span multiple lines |
16:30:33 | uryga | like case-of or defining types |
16:31:34 | uryga | in python, if a thing spans multiple lines, like an if statement or a for loop, there's always a `:` to indicate that |
16:31:56 | dom96 | I'm not sure about case-of statements but I do know that type sections have been inspired by Pascal/Modula |
16:32:03 | * | Arrrr quit (Ping timeout: 240 seconds) |
16:32:22 | dom96 | in terms of the `:`, it is optional in case statements |
16:32:52 | dom96 | so you can write `case x:\n of 3:\n of 4:` or `case x\n of 3:\n of 4:` |
16:34:11 | uryga | hmm ok |
16:34:25 | uryga | it just feels sort of inconsistent |
16:35:00 | uryga | because type has no colon, for and if have one, and proc has a `=` |
16:36:07 | uryga | it'd be great to just have one way of saying "hey, this block below is related to this thing" |
16:38:08 | uryga | and colons seem good for that. but maybe they'd be too overloaded, because they're already used for specifying types? |
16:39:24 | dom96 | yes, that's the problem. |
16:39:43 | * | Arrrr_ quit (Quit: WeeChat 1.4) |
16:39:49 | dom96 | Having to write `let: x: int = 5` would be strange |
16:39:57 | * | Gonzih quit (Ping timeout: 248 seconds) |
16:39:58 | * | Arrrr joined #nim |
16:39:58 | * | Arrrr quit (Changing host) |
16:39:58 | * | Arrrr joined #nim |
16:40:13 | dom96 | (You can have 'let', 'var', 'const', 'type' and more kinds of sections) |
16:40:26 | uryga | actually, `def foo(x: int): int : ` does look pretty goofy too, so i get why `=` is used there |
16:42:37 | uryga | so yeah, it'd be great to have docs of design decisions like that, like PEPs |
16:43:14 | dom96 | uryga: it would be, but the one person who can write such docs has very limited time as it is. |
16:43:40 | uryga | you mean Araq? |
16:44:13 | * | yuta joined #nim |
16:44:13 | * | arnetheduck quit (Ping timeout: 248 seconds) |
16:51:53 | * | vonh joined #nim |
16:53:59 | * | exebook quit (Read error: Connection timed out) |
16:58:44 | * | yuta quit (Quit: ERC (IRC client for Emacs 25.1.50.1)) |
17:03:04 | * | krux02 joined #nim |
17:03:34 | * | uryga quit (Ping timeout: 252 seconds) |
17:05:03 | * | BitPuffin|osx quit (Ping timeout: 240 seconds) |
17:11:37 | dom96 | uryga: yes |
17:15:14 | * | exebook joined #nim |
17:15:20 | * | BitPuffin|osx joined #nim |
17:18:10 | * | Demon_Fox quit (Quit: Leaving) |
17:21:46 | * | krux02 quit (Remote host closed the connection) |
17:22:16 | * | Ven joined #nim |
17:22:23 | * | themagician_m is now known as themagician |
17:26:51 | * | BitPuffin|osx quit (Ping timeout: 276 seconds) |
17:49:19 | * | sorakun joined #nim |
17:56:47 | cheatfate | dom96, i have removed my PR #3982 |
18:04:52 | * | darkf joined #nim |
18:05:18 | dom96 | cheatfate: why? |
18:16:52 | * | uryga joined #nim |
18:17:59 | ^aurora^ | 'lo ... mmm ... i am a little bit confused. didn't use nim for quite a while (last time was nim 0.10.x) |
18:20:34 | ^aurora^ | yesterday i successfully installed nim 0.13 and a mac using the install.sh script. somehow after builder there was the 'install.sh' script and also an 'install' script. i used the command './install /usr/local/bin' and the script managed to put the nim binary below /usr/local/bin, and the other stuff below /usr/local/lib ... which is what i would expect |
18:21:18 | * | uryga quit (Ping timeout: 252 seconds) |
18:21:27 | ^aurora^ | today i wanted to install nim 0.13 on my mac at home and somehow i am unable to generate the 'install' script and the 'install.sh' script puts everything under /usr/local/bin/nim ... |
18:22:02 | ^aurora^ | so i get /usr/local/bin/nim/nim for the binary and /usr/local/bin/nim/lib ... etc for the libs ... |
18:23:36 | ^aurora^ | specifying /usr/local as path for install.sh doesn't help either, because that places a nim folder in /usr/local ... mmm ... what am i doing wrong ... ? |
18:26:10 | ^aurora^ | ah ... i should better look at my bash history before writing stupid stuff in an irc channel ... sorry :D |
18:26:47 | ^aurora^ | missed the make install command at my mac at home ;-) |
18:29:32 | ^aurora^ | but now i have real question: i would be in need of a good tutorial about 'pragmas'. i don't get them by reading the official nim manual. for example: when compiling a source that worked with nim 0.10 i now get the following error: |
18:29:38 | ^aurora^ | Error: type mismatch: got (iterator (): string{.inline, gcsafe, locks: 0.}) but expected 'iterator (): string{.closure.}' |
18:30:15 | ^aurora^ | adding '{.closure.}' to the complained line fixes the problem, but i would really like to understand when i need this, why i need this, and so on ... |
18:30:16 | flyx | ^aurora^: pragmas are a very heterogeneous topic and it's probably best to learn about each one as you need it |
18:31:24 | flyx | ^aurora^: in your case, the error is that you have an iterator which is inlined (i.e. the compiler just replaces calls to it with its code), but what is expected is a closure iterator (i.e. a reference to an iterator implementation) |
18:31:50 | flyx | the relevant manual section is: http://nim-lang.org/docs/manual.html#iterators-and-the-for-statement-first-class-iterators |
18:33:18 | flyx | ^ |
18:33:34 | ^aurora^ | mmm ... this apparently is something that changed between 0.10 and 0.13 ? |
18:34:09 | flyx | ^aurora^: I don't know, but I'd guess that the default changed somewhere (i.e. whether an iterator is inline or closure if you don't explicitly specify it) |
18:35:35 | flyx | ^aurora^: anyway, I'd suggest to use the current Nim development version instead of the release, because it constantly gets improved and bugs get fixed. I am pretty sure my current code doesn't compile on 0.13.0 |
18:35:57 | ^aurora^ | flyx: ok, thanks :) ... i'll do so |
18:56:39 | federico3 | cheatfate: http://sockpuppet.org/blog/2014/02/25/safely-generate-random-numbers/ |
18:58:19 | federico3 | cheatfate: and btw don't forget that one wants to set a fixed seed to generate the same values during unit testing |
19:01:37 | cheatfate | federico3, "that one wants" whois that one? |
19:02:31 | federico3 | one... person (that expects unit tests to work consistently :) ) |
19:04:15 | * | yglukhov quit (Remote host closed the connection) |
19:04:38 | cheatfate | "random" tests? :) to work consistently :) |
19:05:11 | federico3 | pseudorandom, obviously |
19:11:15 | cheatfate | federico3, what algorithm you propose? open /dev/urandom at start by standard library save fd in thread local var and then reading file all the time "nim's random()" called? |
19:15:29 | * | Arrrr quit (Quit: WeeChat 1.4) |
19:16:27 | federico3 | using urandom by default is much safer than a userspace csprng but it doesn't provide reproducibility. Some languages use urandom, some (e.g. Python) use a weak prng |
19:20:03 | * | rok quit (Ping timeout: 240 seconds) |
19:20:06 | federico3 | given that sometimes developers mistakengly use Python random for security, maybe it's better to use urandom by default, just to be on the safe side, and expose cryptographically unsecure functions with an obvious name and warning? |
19:21:42 | federico3 | rust has a hybrid method with a rng that frequently seeds itself from urandom |
19:24:46 | GangstaCat | don't forget this issue: https://github.com/nim-lang/Nim/issues/1506 ; it's old but still open |
19:26:35 | GangstaCat | federico3, maybe you can add some idea on it |
19:31:29 | * | toaoMgeorge quit (Read error: Connection reset by peer) |
19:33:22 | federico3 | nice nickname |
19:34:42 | * | Gonzih joined #nim |
19:39:03 | * | Gonzih quit (Ping timeout: 240 seconds) |
19:39:33 | * | uryga joined #nim |
19:39:52 | * | sorakun quit (Remote host closed the connection) |
19:40:27 | uryga | is it possible to make an operator that's really a macro? |
19:41:04 | uryga | as an experiment, i wanted to try writing a `:=` macro that'd work like this: |
19:41:46 | uryga | `foo := bar()` into `var foo = bar` |
19:42:21 | def- | uryga: that even works with a template |
19:43:13 | def- | template `:=`(x, y) = |
19:43:16 | def- | var x = y |
19:44:28 | uryga | oh wow, that's so cool! i forgot about templates. |
19:45:32 | uryga | honestly, this kind of stuff is why i find nim so cool. looking forward to building something bigger with it! |
19:47:55 | uryga | i'm a bit confused about the difference between a template and a macro though. |
19:49:43 | uryga | nvm, found an article about it. |
19:50:57 | * | brson joined #nim |
20:17:10 | * | desophos quit (Quit: Leaving) |
20:18:16 | * | uryga quit (Ping timeout: 252 seconds) |
20:25:21 | * | aziz joined #nim |
20:25:39 | * | Jesin quit (Quit: Leaving) |
20:29:03 | * | uryga joined #nim |
20:32:07 | * | yglukhov joined #nim |
20:36:45 | * | yglukhov quit (Ping timeout: 248 seconds) |
20:37:16 | * | Ven quit (Ping timeout: 252 seconds) |
20:38:14 | * | Ven joined #nim |
20:49:02 | * | gokr joined #nim |
20:53:04 | * | yglukhov joined #nim |
21:08:35 | baabelfish | uryga: http://nim-lang.org/docs/macros.html |
21:13:16 | * | Jesin joined #nim |
21:19:37 | * | rok joined #nim |
21:26:22 | flyx | is there a proc to get the current code line number? |
21:34:30 | * | mahasamoot quit (Ping timeout: 276 seconds) |
21:34:56 | def- | flyx: you can build one |
21:35:08 | def- | using instantiationInfo |
21:36:51 | def- | template currentLine: int = instantiationInfo().line |
21:39:57 | * | nsf quit (Quit: WeeChat 1.4) |
21:41:13 | flyx | ah yes, that's what I was looking for |
21:41:15 | flyx | thanks |
21:41:37 | uryga | @def- why make it a template and not a proc? |
21:42:02 | def- | uryga: instantiationInfo only works in templates iirc |
21:42:49 | def- | and it makes sense to do that at compile time instead of runtime |
21:43:06 | * | nsf joined #nim |
21:43:10 | uryga | ok, that makes sense |
21:46:18 | * | yglukhov quit (Remote host closed the connection) |
21:46:51 | * | gokr quit (Ping timeout: 276 seconds) |
21:47:29 | * | gokr joined #nim |
21:48:32 | * | toaoMgeorge joined #nim |
22:00:41 | * | ^aurora^ quit (Read error: Connection reset by peer) |
22:07:47 | * | chrisheller joined #nim |
22:10:44 | * | bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
22:14:30 | dom96 | So, what are you guys up to this weekend? Working on any Nim projects? |
22:14:48 | baabelfish | dom96: wish I could |
22:17:45 | baabelfish | Have been thinking about a resharper like tool for Nim |
22:19:15 | dom96 | cool |
22:19:34 | dom96 | brb |
22:21:01 | * | mahasamoot joined #nim |
22:22:05 | * | boopsies is now known as boopsiesisaway |
22:22:56 | * | uryga quit (Ping timeout: 252 seconds) |
22:29:09 | federico3 | a linter would be nice |
22:29:22 | baabelfish | federico3: nim check? |
22:29:49 | baabelfish | or do you mean a style enforcer? |
22:29:55 | federico3 | baabelfish: the latter :) |
22:30:55 | federico3 | something that warn the developer if the same variable or type show up as foo_bar / fooBar / foobar in the same codebase |
22:31:29 | baabelfish | federico3: nice idea |
22:31:41 | baabelfish | constant nimgrepping on the background :D |
22:32:04 | federico3 | optionally it could enforce a configurable style, e.g. MyType my_variable |
22:32:04 | * | krux02 joined #nim |
22:32:49 | federico3 | dom96: regarding https://github.com/nim-lang/Nim/pull/3648 I was asking you if we have a way to detect the kernel version we are compiling against |
22:33:54 | * | rok quit (Ping timeout: 260 seconds) |
22:35:24 | * | Trustable joined #nim |
22:46:27 | * | yglukhov joined #nim |
22:50:43 | * | yglukhov quit (Ping timeout: 248 seconds) |
23:02:03 | * | krux02 quit (Ping timeout: 240 seconds) |
23:02:19 | * | krux02 joined #nim |
23:14:34 | * | gokr quit (Quit: Leaving.) |
23:20:10 | dom96 | baabelfish: any implementation plans for it yet? a CLI app like nimsuggest? |
23:21:41 | baabelfish | dom96: CLI indeed that could be wrapped with plugins |
23:22:02 | dom96 | federico3: I don't think we do :\ |
23:22:18 | baabelfish | editors could wrap that with a plugin* |
23:23:49 | baabelfish | and no implementation plans yet, just thinking about what that tool should be able to do |
23:24:13 | dom96 | federico3: maybe you could just define a cint variable without the {.include, header.} pragmas, set its value to whatever it's defined under Linux, then use an {.emit.} pragma to check for kernel version and set the value to whatever it is supposed to be. |
23:26:41 | * | aziz quit (Remote host closed the connection) |
23:27:42 | * | Ven quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
23:45:50 | * | Trustable quit (Quit: Leaving) |
23:56:54 | cncl | after using c2nim, what's the appropriate way to deal with an enum that's used with bitwise and/or as flags in the c api? |
23:58:05 | * | bjz joined #nim |