00:52:59 | * | vlad1777d quit (Ping timeout: 268 seconds) |
00:54:03 | * | abm quit (Remote host closed the connection) |
00:54:26 | * | abm joined #nim |
00:55:53 | * | Cthalupa quit (Ping timeout: 245 seconds) |
00:56:46 | * | Cthalupa joined #nim |
01:28:08 | * | rnrwashere joined #nim |
01:32:46 | * | rnrwashere quit (Ping timeout: 276 seconds) |
02:00:04 | * | banc quit (Quit: Bye) |
02:05:16 | * | leorize joined #nim |
02:20:43 | * | banc joined #nim |
02:46:06 | * | rnrwashere joined #nim |
03:04:40 | * | dddddd quit (Remote host closed the connection) |
03:07:07 | * | smitop quit (Quit: Connection closed for inactivity) |
03:13:57 | * | [rg] joined #nim |
03:22:25 | * | rnrwashere quit (Remote host closed the connection) |
03:28:05 | * | rnrwashere joined #nim |
03:29:32 | disruptek | if i close a channel, i can still read any messages out of it, right? i just cannot add to it? |
03:33:24 | FromGitter | <jrfondren> I reckon not |
03:33:29 | disruptek | hmm, looks like once it's dead, you can't recv, either. |
03:33:29 | FromGitter | <jrfondren> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5cc67089375bac747022163a] |
03:34:03 | disruptek | that would be fine, but the recv looks for the dead mask, which is set when you close it. |
03:34:21 | disruptek | so there's no way i can see for a producer to indicate that they are done filling the channel. |
03:34:35 | disruptek | i mean, without some oob communication. |
03:34:56 | disruptek | multiple message types, i guess. :-/ |
03:35:10 | FromGitter | <jrfondren> one message type that's a variant type, and one of the variants is "done" |
03:36:01 | * | rockcavera joined #nim |
03:41:52 | * | [rg] quit (Read error: Connection reset by peer) |
03:58:13 | * | xet7 joined #nim |
03:58:46 | * | [rg] joined #nim |
04:28:41 | * | Intensitea joined #nim |
04:31:25 | * | nsf joined #nim |
04:38:52 | * | xet7 quit (Remote host closed the connection) |
04:40:02 | * | xet7 joined #nim |
04:41:19 | * | xet7 quit (Remote host closed the connection) |
04:42:37 | * | xet7 joined #nim |
04:53:28 | FromGitter | <zetashift> Q |
05:12:30 | * | kapil____ joined #nim |
05:22:16 | * | narimiran joined #nim |
05:25:17 | * | [rg] quit (Ping timeout: 246 seconds) |
06:00:01 | * | solitudesf- joined #nim |
06:00:38 | * | Sembei quit (Ping timeout: 246 seconds) |
06:12:17 | * | Sembei joined #nim |
06:12:20 | * | Summertime quit (Quit: Sunsetting.) |
06:13:04 | * | Summertime joined #nim |
06:13:54 | * | krux02 joined #nim |
06:21:58 | * | PMunch joined #nim |
06:23:06 | * | rnrwashere quit (Remote host closed the connection) |
06:26:30 | * | jjido joined #nim |
06:42:12 | * | jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
06:45:04 | * | Jjp137 quit (Read error: Connection reset by peer) |
06:45:29 | * | Jjp137 joined #nim |
07:00:00 | * | gmpreussner quit (Quit: kthxbye) |
07:04:29 | * | gmpreussner joined #nim |
07:26:53 | * | Vladar joined #nim |
08:06:31 | * | stefanos82 joined #nim |
08:11:24 | FromGitter | <mratsim> @deech @kayabaNerve just != is enough no need to cast to uint to check if different instantiation |
08:13:50 | * | floppydh joined #nim |
08:37:45 | * | neceve joined #nim |
08:45:37 | * | neceve quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
08:48:12 | * | neceve joined #nim |
08:48:51 | * | slugm_ joined #nim |
08:53:47 | * | a_b_m joined #nim |
08:55:25 | * | abm quit (Ping timeout: 246 seconds) |
08:58:45 | * | vlad1777d joined #nim |
09:02:17 | * | neceve quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
09:08:23 | * | neceve joined #nim |
09:10:41 | * | neceve quit (Client Quit) |
09:11:04 | * | neceve joined #nim |
09:19:30 | * | absolutejam2 joined #nim |
09:24:05 | PMunch | dom96, you here? |
09:29:59 | * | skelett quit (Ping timeout: 252 seconds) |
10:23:02 | * | floppydh quit (Quit: WeeChat 2.4) |
10:25:35 | * | floppydh joined #nim |
10:31:25 | * | banc quit (Ping timeout: 268 seconds) |
10:38:30 | * | banc joined #nim |
10:46:01 | PMunch | The new playground I've been setting up seems to work fairly well now :) |
10:46:33 | PMunch | And it shouldn't be too hard to add the tour functionality we've been talking about to it |
10:46:47 | Araq | PMunch, how did you solve the threading problems? |
10:46:47 | PMunch | Just need to actually write a tour :P |
10:47:14 | * | banc quit (Ping timeout: 250 seconds) |
10:48:10 | PMunch | By making the strings into ptr string and putting the address of the main thread strings in there |
10:48:21 | Araq | huh? |
10:48:25 | Araq | ok... lol |
10:48:28 | Araq | could work |
10:48:38 | PMunch | It's a hack, but they won't be collected since they're main scope, and they're only written to before the threads start |
10:49:31 | PMunch | I'm not entirely sure if how he was passing the state to the individual threads though is sane.. |
10:51:53 | dom96 | PMunch oooh, yay |
10:53:03 | PMunch | I haven't set up certificates for it yet though. Wasn't sure if you had a system in place for that |
10:53:07 | * | banc joined #nim |
10:53:48 | dom96 | You don't need to set those up |
10:53:54 | dom96 | Since we're using cloudflare |
10:53:55 | PMunch | But if you try to go to "index.html" on the server you should see it working :) |
10:53:59 | PMunch | Ah right |
10:54:29 | PMunch | Hmm, I should set up index.html as the default as well.. |
10:56:37 | PMunch | There, done |
11:02:36 | dom96 | Awesome job PMunch! |
11:02:48 | dom96 | I'll point cloudflare to it once I'm home this evening |
11:02:58 | PMunch | Thanks :) |
11:03:28 | PMunch | It also supports adding ?ix=<id> to load a snippet from ix.io |
11:03:42 | dom96 | cool |
11:04:35 | PMunch | And the editor I'm using is a bit more suited for Nim, and in my testing worked quite a bit better than the old one |
11:12:15 | Zevv | !eval echo 42 |
11:12:15 | NimBot | Compile failed: <no output> |
11:14:09 | PMunch | Zevv, it's not updated yet |
11:14:20 | PMunch | It's running on a secret server :P |
11:14:49 | PMunch | But that should work once it's back up on the main domain :) |
11:17:17 | livcd | and the hole that was used to pwn the old playground is fixed ? lol |
11:19:46 | PMunch | Which hole? |
11:19:58 | PMunch | I haven't done all that much with the actual back-end :P |
11:24:08 | * | rnrwashere joined #nim |
11:26:39 | PMunch | livcd, what hole? |
11:28:11 | FromGitter | <Vindaar> PMunch: https://irclogs.nim-lang.org/18-01-2019.html#12:52:33 |
11:28:49 | * | rnrwashere quit (Ping timeout: 276 seconds) |
11:35:53 | PMunch | Hmm, it certainly wasn't happy with that.. |
11:36:06 | livcd | PMunch: dunno dom96 knows |
11:38:04 | federico3 | urgh |
11:39:38 | PMunch | God damn it.. Now the entire box is locked.. |
11:39:58 | FromGitter | <Vindaar> :| |
11:40:15 | federico3 | of course |
11:43:29 | PMunch | dom96, do you have any way to restart this machine? |
11:53:28 | xace | lol did it print /etc/passwd too? |
12:05:56 | dom96 | lol |
12:06:23 | dom96 | PMunch I do, but not right now |
12:07:08 | PMunch | xace, I didn't add that part in. But each script runs it it's own docker container, so printing /etc/passwd shouldn't do much harm |
12:08:08 | xace | PMunch: I think the security aspect of this is going to be a problem, as you could potentially inject any harmful code you like... |
12:08:22 | dom96 | Glad I set up a separate VPS for this :P |
12:08:40 | PMunch | Haha, yeah that was a good idea dom96 |
12:08:50 | dom96 | PMunch have a look at what the other playground's use |
12:09:09 | PMunch | xace, well with docker containers without any network it's a bit limited what they can do |
12:09:18 | PMunch | dom96, other playgrounds? |
12:09:25 | xace | iirc they include severe limitations to what is allowed, but i'm not familiar with the nim playground, i have just heard mentions of it over the past month(s) |
12:09:48 | dom96 | PMunch yeah, almost every language has one nowadays |
12:09:49 | dom96 | Go, Rust, Clojure, Haskell, etc. |
12:10:03 | PMunch | Ah right |
12:10:10 | * | Snircle joined #nim |
12:10:37 | xace | i think 1 of the common factors is limit the ammount of time the application is allowed to run and max ram usage... but I dont think that is enough |
12:11:10 | * | Snircle quit (Read error: Connection reset by peer) |
12:11:59 | * | Snircle joined #nim |
12:12:37 | dom96 | Guess there are some settings in Docker you might need to set |
12:12:47 | dom96 | Rust seems to use Docker too |
12:13:48 | dom96 | Possibly this: https://github.com/integer32llc/rust-playground/blob/master/deployment/ubuntu.md |
12:13:49 | dom96 | "# Ensure Docker can control the PID limit" |
12:14:53 | PMunch | Yeah I've found memory and cpu limiting options |
12:14:58 | PMunch | Definitely switching those on |
12:15:18 | PMunch | But the script that is used today should already have a timeout, so it should kill it if it takel too long |
12:15:36 | PMunch | Doesn't seem to work too well though |
12:16:10 | PMunch | Hmm, I see that the Rust playground also pulls the 100 most used crates |
12:16:19 | PMunch | That could be something to consider for the playground as well |
12:17:22 | federico3 | dom96: you might want to use seccomp |
12:20:14 | * | rockcavera quit (Read error: Connection reset by peer) |
12:22:11 | * | dddddd joined #nim |
12:22:32 | FromGitter | <mratsim> @PMunch, yes that would be nice. But some might need devel and some stable. Like the latest complex changes in devel were followed with updates in nimbls which broke Arraymancer on devel :/ |
12:22:57 | PMunch | Ah right, yeah that is an issue |
12:28:26 | FromGitter | <mratsim> nimblas* |
12:29:04 | FromGitter | <mratsim> Actually I think if we nail that down, that means we have a good package + package manager ecosystem |
12:32:02 | * | slugm_ quit (Remote host closed the connection) |
12:32:21 | * | slugm_ joined #nim |
12:36:20 | * | sentreen quit (Quit: sentreen) |
12:36:40 | * | sentreen joined #nim |
12:38:22 | Araq | mratsim: huh? devel does test arraymancer |
12:38:28 | Araq | what's wrong with it? |
12:38:56 | * | sentreen_ joined #nim |
12:39:15 | FromGitter | <mratsim> This: https://github.com/unicredit/nimblas/issues/7 |
12:39:26 | * | sentreen_ quit (Client Quit) |
12:39:33 | FromGitter | <mratsim> devel works but stable does not |
12:39:35 | * | sentreen_ joined #nim |
12:39:51 | FromGitter | <mratsim> because nimblas now depends on the new Complex changes |
12:40:02 | FromGitter | <mratsim> which are incompatible with 0.19.4. |
12:40:19 | Araq | you mean the generic complex numbers? |
12:40:24 | FromGitter | <mratsim> yes |
12:40:38 | * | sentreen quit (Read error: Connection reset by peer) |
12:40:41 | Araq | ok, one more reason to release 0.20 then |
12:40:44 | * | slugm__ joined #nim |
12:41:02 | * | slugm_ quit (Read error: Connection reset by peer) |
12:41:05 | FromGitter | <mratsim> so basically we would need to lock version numbers for the playground if we import popular packages |
12:41:31 | FromGitter | <mratsim> that's why I said it would be a good test of package management in the Nim ecosystem |
12:42:43 | FromGitter | <mratsim> assuming we release 0.20 now, would it still be like a RC for 1.0 or are newruntime/owned refs still too new |
12:43:23 | Araq | --newruntime is Nim's new --gc:none for the time being |
12:43:55 | shashlick | @dom96 any chance of getting the nocompiler PR merged today? |
12:44:10 | leorize[m] | memory corruptions for global doesn't seem too nice :p |
12:44:32 | dom96 | shashlick: if it works on my machine then yes. |
12:44:37 | dom96 | Araq: can you test it as well? |
12:44:40 | shashlick | @Araq when is 0.20 scheduled? |
12:44:47 | shashlick | I fixed that bug |
12:44:59 | shashlick | That you found @dom96 |
12:45:14 | Araq | shashlick, tomorrow. *cough* |
12:45:21 | shashlick | Hoping it gets some testing by the community before 0.20 comes out |
12:46:13 | shashlick | Hopefully 0.20 can wait :) |
12:46:33 | narimiran | shashlick: don't worry, i won't let Araq release it tomorrow ;) |
12:47:01 | Araq | we need to work more impulsively. New release? NOW. |
12:47:47 | narimiran | ^ hmmm, maybe we should also take his commit rights? :D |
12:48:08 | * | sentreen_ quit (Ping timeout: 255 seconds) |
12:48:21 | federico3 | is there any test tarball with the same layout as a real release? |
12:49:15 | Araq | nightlies? federico3 |
12:51:11 | * | slugm__ quit (Remote host closed the connection) |
12:51:28 | * | slugm__ joined #nim |
12:52:55 | FromGitter | <mratsim> On my shopping list of PR to merge before 0.20, there are a couple of nice little PR: https://github.com/nim-lang/Nim/pull/11132, https://github.com/nim-lang/Nim/pull/11103, probably this once the octal runnableExample is fixed: https://github.com/nim-lang/Nim/pull/11107, https://github.com/nim-lang/Nim/pull/11026, https://github.com/nim-lang/Nim/pull/11011 |
12:54:18 | FromGitter | <arnetheduck> how much of the std lib has caught up with the new runtime? not only in terms of merely working, but actually being designed to work well with it? |
12:54:20 | FromGitter | <mratsim> Also in the announcement, the role of 0.20.0 and it's relation to the future 1.0 should be explicit (is it a RC or not). |
12:55:02 | PMunch | Note to self, don't forkbomb a machine you don't have physical access to.. |
12:56:09 | FromGitter | <mratsim> also always edit limits.conf on Linux |
12:56:36 | FromGitter | <mratsim> BSDs/Solaris don't suffer from fork bombs by default, I don't know why Linux doesn't use sane anti-forkbomb defaults |
12:56:52 | * | Vladar quit (Remote host closed the connection) |
12:56:53 | shashlick | Close to getting arm in nightlies as well |
12:57:19 | * | Vladar joined #nim |
12:58:32 | PMunch | mratsim, I'll have to look into that |
13:02:08 | * | sentreen_ joined #nim |
13:02:34 | * | sentreen_ quit (Client Quit) |
13:02:42 | * | sentreen joined #nim |
13:04:33 | FromGitter | <mratsim> Ah I found one of my old comments on Arch forkbombs: https://bugs.archlinux.org/task/25690#comment81982 |
13:12:44 | Araq | arnetheduck: designed to work well with it!? I don't even know if the current async can work with it |
13:14:35 | shashlick | What's next in priority for tools? Looking for next thing to work on after nightlies |
13:15:03 | * | lritter joined #nim |
13:15:50 | FromGitter | <arnetheduck> `rm -rf lib; mkdir lib; <start hacking>` |
13:17:31 | narimiran | shashlick: nimsuggest maybe? |
13:18:03 | Araq | shashlick, definitely nimsuggest |
13:22:55 | shashlick | Memory leak? |
13:25:51 | FromGitter | <mratsim> freezing on unfinished macro code, using 100%CPU, using 2GB of memory ... |
13:26:20 | FromGitter | <mratsim> part of the issue is also the VSCode plugin that spawns 1 nimsuggest per file |
13:29:28 | * | neceve quit (Remote host closed the connection) |
13:32:16 | shashlick | Ok I'll run thru the nimsuggest defects |
13:32:16 | * | sentreen quit (Quit: sentreen) |
13:32:28 | * | sentreen joined #nim |
13:33:15 | FromGitter | <mratsim> @PMunch you might want to look into this SO thread if using systemd, though I guess you had a root forkbomb in that case: https://unix.stackexchange.com/questions/469950/why-cant-i-crash-my-system-with-a-fork-bomb |
13:33:20 | * | neceve joined #nim |
13:40:20 | * | theju joined #nim |
13:41:16 | theju | I am reading the code of jester and am wondering what is 'bind' in https://github.com/dom96/jester/blob/master/jester.nim#L522 |
13:43:41 | PMunch | https://nim-lang.org/docs/manual.html#generics-bind-statement |
13:43:47 | PMunch | theju ^ |
13:44:41 | theju | PMunch: thanks |
13:45:23 | theju | i couldn't locate any references to this bind in the searchable index and neither could my search engine |
13:46:45 | PMunch | Hmm weird, I got that from googling "nim bind" |
13:48:36 | PMunch | That being said I'm not entirely sure why it's being used there |
13:52:36 | * | neceve quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
13:53:00 | * | neceve joined #nim |
14:03:35 | * | Trustable joined #nim |
14:05:27 | PMunch | Oh well, I'm off. Hopefully we can get the playground back up and running today :) |
14:06:12 | PMunch | I limited the amount of memory and cpu time each docker instance has, so the simplest of fork bombs should be foiled |
14:06:50 | leorize | dom96: I've been using jester's `router` to separate logic into respective modules |
14:06:53 | PMunch | But I should probably set up a pool of docker instances, each limited to a fixed amount of CPU time, and then just queue up extra jobs |
14:07:10 | * | PMunch quit (Remote host closed the connection) |
14:07:16 | leorize | but it appears that I've to export everything in that module for `extend` to properly work :/ Is that a bug? |
14:16:06 | Araq | I doubt it, 'extend' is complex shit |
14:38:17 | dom96 | leorize: Yeah? Does it work well? |
14:42:12 | Araq | btw any competition for system.unown ? |
14:42:18 | leorize | dom96: ^ you can see my message above :p |
14:42:20 | Araq | I mean the name. |
14:42:47 | Araq | it's used to strip ownership away from an expression |
14:43:41 | leorize | wouldn't the correct verb be 'disown'? |
14:43:52 | Araq | https://github.com/nim-lang/Nim/blob/devel/tests/destructor/twidgets_unown.nim#L37 for example usages |
14:44:03 | Araq | I don't know if it should be a verb. |
14:44:11 | dom96 | leorize: oh, didn't notice your other message. Hm, that depends, can you create a small repro code sample? |
14:44:19 | Araq | is 'disown' even a word? |
14:44:34 | Araq | ah |
14:44:35 | Araq | it is |
14:44:38 | FromGitter | <mratsim> it's the normal word |
14:44:52 | Araq | I don't think it means the correct thing |
14:45:00 | federico3 | https://www.merriam-webster.com/dictionary/disown#examples it does not :) |
14:45:09 | Araq | it's not like you "reject" (?) the expression |
14:45:11 | FromGitter | <mratsim> unown is a Pokemon apparently |
14:45:35 | dom96 | disown is indeed correct |
14:45:51 | FromGitter | <mratsim> I think we disown someone of their inheritance :P |
14:46:02 | Araq | but I want to *undo* the 'owned' annotation |
14:46:09 | FromGitter | <mratsim> aren't owned ref about removing inheritance ;) |
14:46:56 | FromGitter | <mratsim> I'm fine with having a pokemon in system.nim |
14:47:12 | * | theju quit (Read error: Connection reset by peer) |
14:47:17 | Araq | see -- this is why need more operator symbols :P |
14:47:25 | * | theju joined #nim |
14:47:46 | * | theju quit (Client Quit) |
14:48:23 | FromGitter | <mratsim> don't you dare introduce a lifetime operator |
14:49:04 | Araq | then I could use >>=o.x and people would assume Araq knows Haskell and monads |
14:49:51 | Araq | theirs obj.field ? if I don't 'own' it, it's theirs |
14:50:10 | Araq | 'foreign' |
14:50:41 | Araq | oh well, unown is fine, we will get rid of it anyway. later. |
14:55:44 | FromGitter | <mratsim> Or they assume that you are to do in-place shifts |
14:55:50 | FromGitter | <mratsim> trying to do* |
14:58:53 | leorize | dom96: here you go: http://ix.io/1Hy1/nim |
15:03:31 | * | Perkol joined #nim |
15:09:04 | FromGitter | <liquid600pgm> is do notation getting phased out? it's been removed from the manual |
15:09:38 | FromGitter | <jrfondren> minor sins against English are OK, or my code would have #then after all the ifs |
15:10:27 | FromGitter | <mratsim> removing the do notation would break all kind of things |
15:10:49 | Araq | liquid600pgm: I moved to manual_experimental the features that need polish |
15:10:59 | Araq | not the features that will be removed |
15:11:20 | FromGitter | <liquid600pgm> aah, makes sense |
15:11:21 | FromGitter | <jrfondren> for the playground, just limit CPU and RAM with cgroups. Anything short of 100% and you'll at least be able to administer the server (kill the container, see what broke it and then ask whoever broke it to please stop) rather than get locked out. I had to deal with a modsec bug that caused Apache to consume 100% of CPU on servers and cgroups limited that wonderfully, allowing troubleshooting. |
15:11:52 | FromGitter | <jrfondren> if docker doesn't make cgroups convenient for you, you should still be able to apply it from outside to the docker processes. |
15:12:22 | FromGitter | <arnetheduck> I get confused by `do` - it uses different symbols for return type/implementation than `proc` so I always have to look it up |
15:12:58 | Araq | it uses '->' instead but 'do as anon procs' sux big time |
15:14:03 | FromGitter | <arnetheduck> well, yeah, and that's what I always have to look up.. and it breaks parameter lists in a weird way, ie that you pass some parameters with (a, b, c) and suddenly one of them outside the parens |
15:14:34 | disruptek | "nim is not a header file generator." -- too funny. %-D |
15:24:02 | * | rnrwashere joined #nim |
15:31:57 | * | slugm joined #nim |
15:32:50 | * | slugm__ quit (Ping timeout: 255 seconds) |
15:37:54 | * | absolutejam2 quit (Ping timeout: 268 seconds) |
15:44:02 | * | slugm quit (Ping timeout: 258 seconds) |
15:44:05 | * | Snircle quit (Read error: Connection reset by peer) |
15:44:41 | * | Snircle joined #nim |
15:44:51 | * | rockcavera joined #nim |
15:45:31 | * | slugm joined #nim |
16:05:30 | * | floppydh quit (Quit: WeeChat 2.4) |
16:05:55 | * | floppydh joined #nim |
16:06:05 | * | Perkol quit (Remote host closed the connection) |
16:12:22 | dom96 | leorize: hrm, that's a tough call |
16:12:55 | dom96 | It is how generics work too |
16:15:30 | * | kapil____ quit (Quit: Connection closed for inactivity) |
16:21:53 | zestyr | dom96: while you're here, can you test this real quick? http://ix.io/1Hyn opening this jester example with nimsuggest then running chk on it, I get a "key already exists: match" error which makes nimsuggest errors unusable when using jester |
16:22:05 | zestyr | I'm not sure if it's a nimsuggest or jester error |
16:22:11 | leorize[m] | my current solution is to just add an export mark to everything :p |
16:22:21 | zestyr | couldn't find any related github issues |
16:22:36 | dom96 | zestyr: does Nim compile it? |
16:22:39 | zestyr | yes |
16:22:43 | dom96 | then it's a nimsuggest bug |
16:23:00 | leorize | nimsuggest couldn't handle anything within `routes` |
16:23:05 | zestyr | I get this though "Hint: Synchronous route `match` has been optimised. Use `{.async.}` to change." |
16:23:07 | zestyr | maybe that's related |
16:23:13 | dom96 | leorize[m]: yeah, that sucks. We should come up with a better way, not sure what we can do here though :/ |
16:23:42 | dom96 | zestyr: nope. If it compiles then it's definitely a nimsuggest problem |
16:23:53 | dom96 | or a `nim check` one |
16:24:10 | leorize | dom96: in templates you could `bind`, but not in `router` :/ |
16:24:37 | zestyr | `nim check` doesn't complain either, should I open an issue for this? |
16:24:48 | dom96 | sure |
16:25:41 | leorize | zestyr: please open in nim-lang/nimsuggest |
16:26:19 | zestyr | alright, I'll try to come up with a simpler example that doesn't use jester |
16:30:30 | zestyr | got it |
16:31:55 | disruptek | i'm thinking about building a clojure-style async lib. |
16:34:12 | disruptek | the channels will be full-featured, more like highland.js streams. |
16:35:07 | * | Trustable quit (Remote host closed the connection) |
16:37:01 | * | Trustable joined #nim |
16:42:19 | * | a_b_m quit (Ping timeout: 246 seconds) |
16:50:14 | * | Jesin quit (Quit: Leaving) |
17:09:28 | Araq | disruptek, what are "full-featured" channels? |
17:09:57 | disruptek | batteries-included functional programming-style operations. |
17:11:15 | disruptek | the idea is to have something conceptually simple, but with enough surface that it can be powerfully extended. so you can reach for this tool and then grow your use in complexity as the problem scales. |
17:15:53 | Araq | hmm ok |
17:16:36 | Araq | don't laugh ... I need a operator synonym for 'owned' for 0.19.4 |
17:17:04 | Araq | what should it be? ^^ ? |
17:17:24 | Araq | `!` ? |
17:17:31 | disruptek | one hat probably makes more sense than two. the owner wears the hat? |
17:17:50 | Araq | hat is already used for ^1 though |
17:17:55 | Araq | (backwards indexing) |
17:18:03 | FromGitter | <jrfondren> ! <- emoticon of a guard alerted by your attempt to mess with someone else's property |
17:18:31 | zestyr | ! universally means "not", probably a bad choice |
17:18:49 | Araq | universally? |
17:18:57 | Araq | it means "watch out" |
17:18:58 | FromGitter | <jrfondren> I wouldn't say universally. It doesn't mean that in Nim. It's the message-passing operator in Erlang |
17:19:24 | disruptek | @@, because at-ats pwn in star wars. |
17:19:41 | leorize | `^!` :P |
17:19:51 | Araq | it is allowed to be ugly btw |
17:19:52 | disruptek | hats ahead? |
17:20:11 | FromGitter | <jrfondren> prefix [] |
17:20:11 | Araq | @^@ the weird face operator |
17:21:21 | disruptek | ?? because... wtf? |
17:21:55 | Araq | one problem is that it'll end up in the generated docs :-/ |
17:22:08 | Araq | unless I hack some workaround into renderer.nim |
17:22:48 | Araq | it should be an operator nobody ever used... |
17:24:30 | FromGitter | <jrfondren> $ <- duplicating money is against the law |
17:24:38 | * | jjido_ joined #nim |
17:25:06 | FromGitter | <jrfondren> it's a pity that no other currency symbols exist. |
17:25:15 | Araq | € |
17:25:50 | FromGitter | <kaushalmodi> not sure what the discussion is, but https://www.fileformat.info/info/unicode/char/20b9/index.htm |
17:26:02 | disruptek | seems like it has to be a ? or : because the others are more frequently used or have special semantics. |
17:26:11 | narimiran | owned = $% (if you own something, you pay some percentage of interest :D) |
17:26:52 | FromGitter | <jrfondren> discussion is an operator for owned refs, from https://nim-lang.org/araq/ownedrefs.html |
17:26:54 | * | jjido_ quit (Client Quit) |
17:27:16 | narimiran | owned = ø :D |
17:27:29 | Araq | no non-ascii operators are allowed in Nim |
17:28:05 | zestyr | ø is part of ascii |
17:28:17 | Araq | hardly |
17:28:35 | FromGitter | <jrfondren> if it's ASCII then why are you using two bytes for it? |
17:29:14 | zestyr | hm? it's 155 |
17:29:42 | disruptek | nim source is utf-8 |
17:31:04 | Araq | I'll pick <//> |
17:31:05 | FromGitter | <jrfondren> ~bob <- in Unix, refers to bob's home directory, similar to ~/something/in/my/home/directory |
17:31:17 | disruptek | :: |
17:31:19 | Araq | if you own something, you can put it into a box |
17:31:22 | narimiran | <|> |
17:31:47 | narimiran | <\/> |
17:31:51 | disruptek | four corners of a box? :: |
17:31:52 | FromGitter | <jrfondren> and <> is a diamond and diamonds are semi-precious gems |
17:31:58 | narimiran | </\> |
17:32:06 | disruptek | //\/\//\\// |
17:32:17 | FromGitter | <jrfondren> is that <ownedref> or is the whole operator `<//>` ? |
17:32:45 | * | NimBot joined #nim |
17:33:18 | Araq | jrfondren: the whole operator is <//> |
17:33:19 | disruptek | |arity-2| |
17:34:09 | FromGitter | <jrfondren> <//>thing then. ... was the € the inspiration after all? |
17:34:30 | Araq | maybe |
17:34:49 | Araq | it's ugly enough that it's unlikely to be used anywhere and I can remember it |
17:34:53 | Araq | so it's good enough. |
17:35:08 | Araq | with some luck people won't have to read it... ha ha ha ha |
17:35:18 | * | rnrwashere quit (Remote host closed the connection) |
17:37:42 | Araq | proc newTable*[A, B](initialSize=64): <//>TableRef[A, B] |
17:37:59 | Araq | yep, a pure beauty |
17:38:54 | Araq | at least it doesn't crash 0.19.4 |
17:39:44 | shashlick | Arm builds are a go - https://github.com/genotrance/nightlies/releases - will push this to nightlies soon |
17:40:41 | * | rnrwashere joined #nim |
17:44:02 | narimiran | shashlick: great! btw, don't be surprised if the latest 0.19.5 is red - it is my fault - i've backported something and now some tests are red (and i cannot reproduce it on my machine) |
17:50:11 | * | rnrwashere quit (Remote host closed the connection) |
17:51:46 | shashlick | well, i'm not able to run koch docs or megatest on arm |
17:52:11 | shashlick | koch docs needs libpcre which isn't setup |
17:52:19 | shashlick | and megatest runs into a bug i opened last night |
17:54:08 | * | rnrwashere joined #nim |
17:57:03 | * | absolutejam2 joined #nim |
17:59:31 | * | rnrwashere quit (Remote host closed the connection) |
18:00:56 | * | Jesin joined #nim |
18:14:35 | * | neceve quit (Remote host closed the connection) |
18:17:31 | * | thomasross quit (Remote host closed the connection) |
18:17:50 | * | thomasross joined #nim |
18:33:37 | * | a_b_m joined #nim |
18:50:06 | * | floppydh quit (Quit: WeeChat 2.4) |
18:52:35 | * | Jesin quit (Quit: Leaving) |
19:02:19 | * | rnrwashere joined #nim |
19:04:42 | * | Jesin joined #nim |
19:08:55 | * | jjido joined #nim |
19:09:12 | * | absolutejam2 quit (Ping timeout: 245 seconds) |
19:13:49 | shashlick | is it not possible to link to openssl static? like libpcre? |
19:24:48 | * | rnrwashere quit (Remote host closed the connection) |
19:25:07 | FromGitter | <bluenote10> Is there a way to test if a `NimNode` has a type? In other words, the check should return true if and only if `n.getTypeInst()` would work. Or is it somehow possible to handle the "node has no type" error in a try/catch? |
19:28:57 | * | absolutejam2 joined #nim |
19:30:31 | FromGitter | <mratsim> I think I handled that by checking if it's Sym |
19:30:35 | FromGitter | <jrfondren> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5cc750db8790b0307e226f02] |
19:30:59 | FromGitter | <mratsim> and all symbols have a type |
19:31:38 | FromGitter | <jrfondren> from compiler/vm.nim. I reckon it's not possible to handle the error, but those are the tests. |
19:32:08 | FromGitter | <mratsim> you would be surprised at what "when compiles" can do :P |
19:32:12 | FromGitter | <bluenote10> In my case it can be any node kind (arbitrary expressions), so I cannot test for nnkSym |
19:33:35 | * | Trustable quit (Remote host closed the connection) |
19:34:02 | FromGitter | <mratsim> Not sure of your exact use case but this might help: https://github.com/numforge/loop-fusion/blob/master/loopfusion.nim#L20-L72 |
19:34:59 | FromGitter | <bluenote10> haha I didn't even consider `compiles`, but I get the "node has no type" from even with the check `when compiles(n.getTypeInst): echo n.getTypeInst.treeRepr` |
19:36:26 | FromGitter | <mratsim> I think loop-fusion is the library where I fought the most with getTypInst and generics :P |
19:36:34 | FromGitter | <mratsim> in macros |
19:36:43 | FromGitter | <mratsim> and consequently raised the most bugs |
19:38:33 | * | rnrwashere joined #nim |
19:38:42 | FromGitter | <bluenote10> most likely there is some trick to solve it, can sometimes just take a few hours to find it... a `hasType(n: NimNode): bool` would be nice |
19:40:07 | FromGitter | <mratsim> Probably should be named "isTyped". |
19:40:29 | FromGitter | <mratsim> I use hasType like that: https://github.com/mratsim/Arraymancer/blob/master/src/private/ast_utils.nim#L20-L22 |
19:43:34 | FromGitter | <mratsim> @Araq, I'm pretty sure macros.owner didn't exist before, and it somehow was backported in 0.19.4? https://nim-lang.org/docs/macros.html#owner%2CNimNode |
19:47:09 | FromGitter | <mratsim> seems like it sneaked in in 0.19.2 backports |
20:11:23 | * | ng0 joined #nim |
20:12:00 | * | rnrwashere quit (Remote host closed the connection) |
20:16:18 | * | rnrwashere joined #nim |
20:20:05 | * | salewski joined #nim |
20:21:09 | salewski | when a, b, c are refs or pointers, is there a better way than echo cast[int](a) for debugging? |
20:25:07 | salewski | printf("%p %p %p", a, b, c) |
20:25:33 | * | nsf quit (Quit: WeeChat 2.4) |
20:29:06 | Araq | mratsim: Maybe. narimiran will investigate :P |
20:29:27 | Araq | salewski, toHex(cast[int](...) maybe |
20:29:53 | shashlick | looks like log2() is missing on android arm so nim cannot build |
20:33:03 | salewski | Araq, I want to save me typing the cast three times for 3 pointers. I guess repr(a) may work. Or I have to define my own proc... |
20:33:08 | salewski | Bye. |
20:33:11 | * | salewski quit (Quit: WeeChat 2.3) |
20:35:02 | * | rnrwashere quit (Remote host closed the connection) |
20:41:14 | FromGitter | <mratsim> @shashlick, strange, fastLog2 is using gcc/clang builtins and have a fallback using de Bruijn multiplication |
20:42:10 | shashlick | dockcross does have an older NDK - r16 |
20:42:24 | shashlick | i made a custom log2() for now |
20:42:29 | shashlick | but now stuck on __ctype_get_mb_cur_max |
20:42:43 | shashlick | am going to ditch android arm for now, android-arm64 is working |
20:45:23 | Zevv | shashlick: what's your issue with arm 32 bits? |
20:48:30 | shashlick | log2() was missing, so made my own |
20:49:49 | shashlick | then ctype_get_mb_cur_max was missing, so added -landroid_support |
20:50:21 | shashlick | then complained about operator new(unsigned int) so added -lstdc++ |
20:50:40 | shashlick | now asking for dladdr but -ldl doesn't work since it's not available |
20:51:02 | shashlick | i have to build with -static since I need to run it with qemu and /system/bin/linker isn't present |
20:53:08 | * | slugm quit (Ping timeout: 246 seconds) |
20:54:25 | shashlick | okay, android-arm is out |
21:08:40 | * | narimiran quit (Ping timeout: 246 seconds) |
21:10:54 | * | theelous3_ joined #nim |
21:19:41 | * | rnrwashere joined #nim |
21:21:19 | * | JappleAck joined #nim |
21:27:55 | * | krux02 quit (Remote host closed the connection) |
21:29:08 | * | Vladar quit (Remote host closed the connection) |
21:34:32 | * | rnrwashere quit (Remote host closed the connection) |
21:40:14 | * | Hexeratops joined #nim |
21:53:02 | dom96 | PMunch: I power cycled the VPS |
21:53:22 | * | solitudesf- quit (Ping timeout: 245 seconds) |
21:57:37 | * | jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
21:58:58 | shashlick | @dom96: pretty please 😄 </nag> |
22:06:14 | dom96 | shashlick, Merged. I squashed it, hope you don't mind |
22:13:38 | * | absolutejam2 quit (Ping timeout: 246 seconds) |
22:16:04 | Zevv | shashlick: nice! |
22:19:13 | shashlick | That's perfect @dom96, thanks a bunch! |
22:30:12 | * | xet7 quit (Remote host closed the connection) |
22:33:17 | * | Hexeratops left #nim ("Leaving") |
22:33:47 | * | Sembei quit (Ping timeout: 245 seconds) |
22:34:58 | * | Jesin quit (Quit: Leaving) |
22:38:06 | * | Jesin joined #nim |
22:39:16 | * | ng0 quit (Quit: Alexa, when is the end of world?) |
22:42:35 | * | absolutejam2 joined #nim |
22:53:19 | * | Hexeratops joined #nim |
22:54:41 | * | Sembei joined #nim |
23:08:36 | * | [rg] joined #nim |
23:14:18 | * | stefanos82 quit (Remote host closed the connection) |
23:20:53 | * | [rg] quit (Remote host closed the connection) |
23:21:14 | * | [rg] joined #nim |
23:22:58 | * | a_b_m quit (Ping timeout: 250 seconds) |
23:36:29 | * | faifacr joined #nim |
23:37:12 | * | faifacr quit (Client Quit) |
23:55:10 | * | [rg] quit (Quit: Leaving) |
23:55:33 | * | [rg] joined #nim |
23:56:01 | * | theelous3_ quit (Ping timeout: 244 seconds) |