00:01:39 | * | lritter quit (Ping timeout: 240 seconds) |
00:05:37 | leorize | ok I kinda give up on nimph |
00:09:39 | shashlick | what's wrong |
00:20:36 | leorize | for some reason, nimph keeps trying to do nimble dump on the Nim source tree |
00:21:10 | leorize | I moved the tree to an another location, and now it's trying to nimble dump the nimble packages that I have in /usr/share/nimble/pkgs (yes, I do have nimble packages installed globally) |
00:21:47 | leorize | and I don't even know what it's trying to do :/ |
00:33:53 | disruptek | leorize: yes, it will try to learn the versions of anything in its path. that's how it figures out what dependencies are available to your package and what their versions are. |
00:34:33 | disruptek | if you limit the compiler's search path with a nim.cfg then nimph will similarly limit the packages it looks at. |
00:34:52 | leorize | my search path don't have ~/source/Nim/lib... |
00:35:03 | leorize | I don't know how it figured to look in there |
00:35:23 | disruptek | it's likely a path setup by the compiler. |
00:35:36 | disruptek | see `nim dump` to confirm, or run nimph with --log=lvlDebug |
00:36:05 | disruptek | if you really think it's a bug, then build it with -d:debugPaths -d:debug and you'll get tons of path-related output. |
00:37:23 | * | krux02 quit (Remote host closed the connection) |
00:37:33 | leorize | how can I pass --log=lvlDebug when I don't specify any subcommand for nimph? |
00:37:42 | leorize | it just passes that to nimble for whatever reasons |
00:37:46 | disruptek | `nimph nurse` |
00:38:48 | leorize | it doesn't print anything more important |
00:39:00 | leorize | and nim dump don't show any directory that nimph has tried to look at |
00:39:40 | disruptek | really. |
00:40:01 | leorize | yep, I'll try to compile with a bunch of flags |
00:41:37 | disruptek | `nim dump` doesn't show your nim library directories? |
00:41:49 | disruptek | i don't know how that's possible, honestly. |
00:42:18 | leorize | it just show the standard library paths, not any of the paths that nimph looked at though |
00:42:31 | disruptek | can you paste some output somewhere? |
00:44:07 | disruptek | when nimph look at path X, it will also search X's parents to find a source .nimble. but, the compiler includes a compiler.nimble, so i don't really understand how it could not find that. |
00:45:17 | disruptek | also, afaik $nim works anywhere the other path subs work. i don't think there's any special code for it; it's equivalent to config.libpath iirc. |
00:45:44 | leorize | it's equivalent to getPrefixDir |
00:45:58 | disruptek | okay, sure. |
00:46:01 | leorize | which is /usr for nim installed in /usr/bin/nim |
00:46:10 | leorize | and I don't have "compiler" there :P |
00:46:51 | disruptek | i don't think i've ever tested nimph against a nim installed outside of its git tree; you're basically on your own, there. |
00:47:24 | leorize | add my gentoo overlay, it has a nim-9999.ebuild :P |
00:48:16 | leorize | I'll probably have to "fix" this by just do a copy of Nim source to /usr/lib then symlink the rest |
00:48:33 | disruptek | i'm told that no one important wants to use nimph, so it no longer needs to serve any such strange use-case. yay! |
00:50:06 | disruptek | i'm sure there's an easier solution in src/nimph/config.nim if you really want to pursue it. |
00:53:15 | leorize | disruptek: I figured out one problem |
00:53:23 | leorize | looks like nimph hardcodes the compiler path... |
00:55:35 | disruptek | probably, yes. |
00:55:57 | leorize | it hardcodes the path of the compiler used to compile it... |
00:56:05 | leorize | and that one is in the source tree |
00:56:06 | disruptek | yes, that was my understanding. |
00:58:11 | leorize | that's where 90% of my troubles came from |
00:58:34 | disruptek | this `make -j 4 -l 4` stuff is silly. |
00:58:59 | leorize | the other 10% is from nimble attempting to create a temporary file in a read-only folder... |
00:59:15 | disruptek | yes, there's an open ticket for that. |
00:59:26 | disruptek | please create a ticket for the nimph bug and i will fix it. |
00:59:42 | disruptek | i mean, there's an open ticket to fix nimble. |
01:00:30 | disruptek | !search permission denied fatal |
01:00:31 | disbot | https://github.com/nim-lang/nimble/issues/748 -- 3permission denied to ~/.nimble/pkgs is fatal 7& 4 more... |
01:00:54 | * | rockcavera joined #nim |
01:02:00 | leorize | I'll probably fix nimble myself, I'm gonna use Nim in a shared project and I'd like it to be as frictionless for others as possible |
01:02:44 | leorize | meanwhile what would you like me to file for nimph? :P |
01:02:44 | disruptek | well, that would be awesome. that bug really annoys me because i never let nimble write anywhere. |
01:03:01 | disruptek | that the compiler path shouldn't be hardcoded if we can help it. |
01:03:16 | leorize | I'll have to fix that bug anyway if I want nimble to support global package directory |
01:03:31 | disruptek | that one and several others. |
01:05:20 | * | nullwarp joined #nim |
01:06:04 | * | disrupteq joined #nim |
01:08:00 | leorize | done disruptek/nimph#118 |
01:08:12 | disruptek | thanks. 👍 |
01:15:14 | * | icebattle quit (Ping timeout: 240 seconds) |
01:15:16 | dom96 | Cool, my talk is up https://mirror.as35701.net/video.fosdem.org/2020/AW1.125/asyncawaitnim.mp4 |
01:20:16 | * | Hideki_ joined #nim |
01:24:52 | * | Hideki_ quit (Ping timeout: 265 seconds) |
01:34:40 | ftsf | @dom96, ooh, keen to watch it after work |
01:39:31 | * | cgfuh joined #nim |
01:41:34 | * | k4k0 joined #nim |
01:42:21 | * | k4k0 left #nim (#nim) |
01:55:48 | * | a_b_m quit (Read error: Connection reset by peer) |
02:10:47 | * | thomasross quit (Ping timeout: 265 seconds) |
02:13:08 | FromDiscord_ | <Fern & Simula (They/Them)> whats the difference between `quote` and `quote do`? |
02:27:17 | * | chemist69_ joined #nim |
02:30:36 | * | chemist69 quit (Ping timeout: 265 seconds) |
02:40:57 | ftsf | @dom96, https://play.nim-lang.org/#ix=28pQ doesn't seem to work "Unable to load ix paste, file too large, or download is too slow" |
02:41:44 | ftsf | ahh, a few reloads and it worked |
02:41:57 | ftsf | when running: /usercode/in.nim(11, 19) Error: undeclared identifier: 'Future' |
02:42:53 | ftsf | seems to need import asyncdispatch |
02:44:45 | ftsf | would be good to include an example of what getMagicalInt might look like so the playground is functional |
02:47:05 | ftsf | *applause* good talk @dom96 |
02:49:46 | nisstyre | yeah it was great, I just watched it all |
02:50:03 | nisstyre | I didn't know async/await were just macros |
02:50:12 | ftsf | same, impressed! |
03:00:55 | * | cgfuh quit (Quit: WeeChat 2.6) |
03:01:15 | * | cgfuh joined #nim |
03:03:26 | * | endragor joined #nim |
03:04:40 | * | ptdel joined #nim |
03:05:07 | * | cgfuh quit (Client Quit) |
03:05:25 | * | cgfuh joined #nim |
03:11:34 | * | icebattle joined #nim |
03:16:08 | * | icebattle quit (Ping timeout: 260 seconds) |
03:23:20 | * | rockcavera quit (Remote host closed the connection) |
03:37:18 | * | muffindrake quit (Ping timeout: 265 seconds) |
03:39:02 | * | muffindrake joined #nim |
03:43:01 | leorize | shashlick: you around? |
03:50:12 | shashlick | Sup |
03:50:50 | leorize | why does nimble copy the generated .nims file to it's original directory before running? |
03:52:37 | leorize | I'm reading that code and also traced your commits, ended up with a helpful "Initial version" commit :P |
03:53:19 | shashlick | 🙂 |
03:53:28 | disrupteq | probably so that a current dir assumption works. |
03:53:35 | shashlick | ya cause the nimble file is there and that's the only way to ensure that relative paths work |
03:53:51 | leorize | hmmm does --path not work? |
03:53:58 | shashlick | if i run it from temp, all existing nimble files that imported or referred to relative paths won't work |
03:54:43 | disrupteq | maybe --path doesn't do what you think it does. |
03:54:49 | shashlick | like if you run a cpFile or similar commands |
03:55:07 | * | greenfor` joined #nim |
03:56:24 | leorize | shashlick: is there any nimscript function to get the current script folder? |
03:57:57 | shashlick | currentSourcePath.parentDir() probably |
03:59:06 | leorize | it's thisDir() for nimscript |
03:59:12 | leorize | we could fake that |
03:59:22 | leorize | currentSourcePath is a different story though :/ |
03:59:55 | leorize | I'm looking into how to avoid copying the file back to the package directory |
04:00:02 | * | disrupteq quit (Ping timeout: 240 seconds) |
04:00:11 | shashlick | will be great if you can figure that out |
04:00:16 | shashlick | i'm not happy with that hack |
04:03:48 | * | disrupteq joined #nim |
04:04:32 | disruptek | shashlick: why do you think that's the wrong approach? |
04:28:53 | * | thomasross joined #nim |
04:38:50 | * | nsf joined #nim |
04:48:12 | shashlick | It's not perfect, having to copy files over for relative paths instead of just setting cwd |
04:48:52 | disruptek | can you just run it from the same directory as the project file? |
04:49:41 | disruptek | ie. `cd /some/where; nim e /some/other/path/foo.nims` |
04:54:28 | shashlick | No relative paths don't work |
04:54:56 | shashlick | Any code context in any Nim file is relative to that file |
04:55:23 | disruptek | that's... surprising. |
04:58:41 | * | sentreen quit (Ping timeout: 272 seconds) |
04:59:08 | * | sentreen joined #nim |
04:59:20 | disruptek | so maybe you should setCurrentDir in the generated script? |
05:01:46 | * | ltriant quit (Quit: leaving) |
05:14:25 | * | ptdel quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
05:18:02 | * | gmpreussner quit (Ping timeout: 240 seconds) |
05:18:16 | leorize | for include and import, I think --path should do |
05:18:46 | * | gmpreussner joined #nim |
05:19:36 | * | sentreen quit (Ping timeout: 265 seconds) |
05:20:01 | * | sentreen joined #nim |
05:40:40 | * | marmotini_ joined #nim |
05:51:29 | * | narimiran joined #nim |
05:51:30 | * | endragor quit (Read error: Connection reset by peer) |
05:56:12 | * | Jjp137_ joined #nim |
05:56:17 | * | Jjp137 quit (Read error: Connection reset by peer) |
06:13:27 | * | cgfuh quit (Quit: WeeChat 2.6) |
06:14:30 | * | thomasross quit (Killed (verne.freenode.net (Nickname regained by services))) |
06:14:30 | * | thomasross joined #nim |
06:19:54 | * | endragor joined #nim |
06:41:45 | * | s3govesus joined #nim |
07:02:20 | * | marmotini_ quit (Remote host closed the connection) |
07:21:21 | FromDiscord_ | <Rika> are `cast`s normally unsafe |
07:21:28 | FromDiscord_ | <Rika> or are they considered "safe" |
07:21:47 | Araq | it's Nim's most unsafe feature. |
07:22:07 | FromDiscord_ | <Rika> i see |
07:22:41 | FromDiscord_ | <Rika> how would i go by changing an object to another object, knowing that the 2nd object only adds fields |
07:23:11 | FromDiscord_ | <Rika> https://play.nim-lang.org/#ix=2aKm something akin to this |
07:24:02 | leorize | I think the compiler is permitted to rearrange the field, even though it doesn't do so atm |
07:24:12 | leorize | use inheritance for this |
07:24:19 | leorize | `cast` is unsafe by design |
07:24:40 | FromDiscord_ | <Rika> well i assumed it was but was unsure if it was |
07:25:32 | FromDiscord_ | <Rika> also i have Test2 first, and cannot inherit Test1 |
07:26:06 | Zevv | leorize: afaik there is no rearranging as objects are guaranteed to map on the underlying C struct |
07:26:16 | Zevv | there might be packing though, but that does not affect augmentation |
07:26:25 | leorize | I thought that's only applicable to tuples? |
07:28:01 | * | dddddd quit (Remote host closed the connection) |
07:28:03 | Zevv | good point, can't find it in the manual though |
07:53:04 | * | solitudesf joined #nim |
07:54:21 | Araq | the spec in my head says "layout is compatible for .bycopy" objects |
07:55:01 | Araq | but it kinda sucks, we need ".clayout" for that. however since every version uses clayout probably something like .freeToReorder makes more sense |
08:00:00 | * | gmpreussner quit (Quit: kthxbye) |
08:04:41 | * | gmpreussner joined #nim |
08:04:57 | Zevv | but since nothing is reordering yet, we need nothing at this time and we can document that the default is .clayout |
08:06:21 | * | vesper11 quit (Ping timeout: 265 seconds) |
08:07:03 | * | PMunch joined #nim |
08:07:48 | * | vesper11 joined #nim |
08:12:05 | PMunch | Back to work after a great time at FOSDEM2020! Two of the four Nim talks are already available online for those who would like to watch them: https://fosdem.org/2020/schedule/event/nimoneverything/ https://fosdem.org/2020/schedule/event/nimoneverything/ |
08:12:23 | PMunch | Woops, same link twice: https://fosdem.org/2020/schedule/event/asyncawaitnim/ |
08:12:27 | Zevv | cmon dude. You can't fool us |
08:12:29 | Zevv | right |
08:12:33 | Zevv | :) |
08:13:09 | PMunch | Haha, cut me some slack, I got home after midnight yesterday and is running on about 5 hours of sleep :P |
08:13:21 | PMunch | s/is/am |
08:13:22 | Zevv | You can't even english anymore |
08:13:41 | PMunch | Haha, exactly! |
08:14:00 | Zevv | The Delirium Tremens must be getting to you - better take it easy for a few days |
08:14:55 | Araq | PMunch, do I need to do anything to get my talk online? |
08:15:01 | PMunch | And of course it's been snowing non-stop while I was gone, so had to shovel my driveway to get the car out this morning. And had to pull a taxi free from another driveway as he was stuck (yay for having a good car and a tow-rope) |
08:15:09 | * | hax-scramper quit (Ping timeout: 268 seconds) |
08:15:19 | PMunch | Araq, you should've gotten a link to review the video |
08:15:23 | * | hax-scramper joined #nim |
08:15:49 | PMunch | There you can make sure that the start/stop times are good and check that the audio sounds fine |
08:16:05 | PMunch | If you haven't gotten it try asking over in #fosdem-video here on Freenode |
08:16:27 | PMunch | Zevv, yeah that stuff hits hard :S |
08:17:12 | Araq | haven't checked my emails yet... |
08:20:30 | * | chenhq2005 joined #nim |
08:21:20 | PMunch | Ah right, yeah as soon as you finish the review process it will get sent of for rendering, and then it will be made available in about a day it seems |
08:37:28 | * | JustASlacker joined #nim |
08:38:08 | * | chenhq2005 quit (Ping timeout: 260 seconds) |
08:43:14 | * | floppydh joined #nim |
08:43:20 | * | thomasross quit (Ping timeout: 268 seconds) |
08:46:15 | FromGitter | <alehander92> yeah norway sounds fun |
08:46:18 | FromGitter | <alehander92> for driving |
08:47:24 | * | thomasross joined #nim |
08:50:01 | PMunch | Haha, it's definitely an experience |
08:59:16 | * | Vladar joined #nim |
08:59:37 | Zevv | I'm having some macro headaches. I have a snippet of Nim that works, and I am trying to generate the same code from a macro. My AST is the same according to dumpAstGen, only I have some newIdentNode()s where the original AST has newSymNode(). What is newSymNode(), and where does that come from? My problem now is "inconsistent typing for reintroduced symbol" |
09:03:46 | PMunch | A symbol is a looked-up ident |
09:04:02 | PMunch | That is an ident that's been resolved to a type |
09:04:17 | FromDiscord_ | <mratsim> you probably either need to transform everything as a newIdentNode or you are using the same name twice and need to "let foo = newNimNode("foo")" and need to reuse that |
09:12:38 | * | chenhq2005 joined #nim |
09:17:39 | Zevv | Ok, let me dump my code |
09:17:55 | Zevv | need to cleanup a bit first |
09:19:55 | Zevv | http://ix.io/2aKD |
09:20:11 | Zevv | I must say the error message eludes me |
09:20:23 | Zevv | so can I force the lookup of an ident to fix this? |
09:20:25 | Zevv | bindSym? |
09:23:02 | * | Pqzcih5 joined #nim |
09:28:12 | * | chemist69_ quit (Ping timeout: 265 seconds) |
09:29:02 | * | chemist69 joined #nim |
09:36:48 | * | skrylar joined #nim |
09:40:19 | * | NimBot joined #nim |
09:41:08 | Zevv | I think I do, otherwise I do not know what Box[T] to put it into |
09:41:13 | Zevv | getType needs typed |
09:41:16 | FromGitter | <Vindaar> Ah, yes just saw that too |
09:41:52 | Zevv | I have a working alternative that works with untyped, by doing Box[typeof(v)], but I need some glue there to automatically convert strings to cstrings |
09:42:01 | Zevv | so for that I want to know it it is a string |
09:42:06 | FromGitter | <Varriount> We need a "guide to macros for the unenlightened" detailing these things. I don't think the difference between a symbol and an identifier is spelled out anywhere |
09:42:34 | Zevv | I touch these things every now and then, but there are just a lot of relevant details |
09:42:38 | Zevv | I never said it was simple ;) |
09:43:32 | Zevv | But your point 2 explains the error message, which is nice. thanks |
09:44:36 | FromGitter | <Vindaar> no worries. you could come up with some naming convention and return e.g. the result as `aBox` or something |
09:55:58 | * | chenhq2005_ joined #nim |
09:56:20 | FromGitter | <Vindaar> or you leave it untyped and add an `initBox` proc: https://ix.io/2aKJ/nim |
09:56:39 | FromGitter | <Vindaar> http://ix.io/2aKJ/nim |
09:57:11 | FromGitter | <Vindaar> however that errors when compiling the C code. But I guess that's because of the pragma? works without it at least |
09:59:13 | * | chenhq2005 quit (Ping timeout: 260 seconds) |
10:03:03 | * | natrys joined #nim |
10:04:42 | Zevv | yeah it's for a specific cpu only, but that is the whole point. This data gets stored in a magic place that is not mapped to memory, and I'm trying to hide that fact |
10:05:35 | Zevv | initBox does the job - thanks for that |
10:05:56 | FromGitter | <Vindaar> yep, cool! |
10:14:35 | skrylar | mailed the new build scripts for alpine off to the maintainer |
10:42:04 | * | abm joined #nim |
10:50:07 | FromGitter | <Varriount> Mailed as in, emailed, or physically mailed? |
10:50:28 | FromGitter | <Varriount> skrylar: ^ |
10:51:07 | Araq | why would it mean "physically mailed"? |
10:51:51 | * | skrylar pontificates. |
10:52:20 | skrylar | e-mailed, but that might not be minimalist enough for them ^_~ |
10:53:09 | dom96 | PMunch any ideas when these talks make it to YouTube? |
10:53:22 | skrylar | i did notice that the async tests seem to hang indefinitely (or at least for longer than 20 minutes) so i have checks turned off :/ |
10:55:11 | * | pbb quit (Quit: http://quassel-irc.org - Chat comfortably. Anywhere.) |
10:56:29 | * | pbb joined #nim |
11:14:09 | * | pigmej quit (*.net *.split) |
11:14:10 | * | chenhq2005_ quit (*.net *.split) |
11:14:10 | * | skrylar quit (*.net *.split) |
11:14:21 | * | PMunch quit (*.net *.split) |
11:14:21 | * | muffindrake quit (*.net *.split) |
11:14:21 | * | letto_ quit (*.net *.split) |
11:14:21 | * | matti quit (*.net *.split) |
11:14:21 | * | uvegbot quit (*.net *.split) |
11:14:21 | * | FromGitter quit (*.net *.split) |
11:14:21 | * | nuxdie quit (*.net *.split) |
11:14:21 | * | msmorgan quit (*.net *.split) |
11:14:21 | * | tefter quit (*.net *.split) |
11:14:21 | * | oprypin quit (*.net *.split) |
11:14:21 | * | moon-chilled quit (*.net *.split) |
11:14:21 | * | dom96 quit (*.net *.split) |
11:14:21 | * | bozaloshtsh quit (*.net *.split) |
11:14:21 | * | r4vi quit (*.net *.split) |
11:14:21 | * | jwm224 quit (*.net *.split) |
11:14:21 | * | silvernode[m] quit (*.net *.split) |
11:14:21 | * | BitPuffin quit (*.net *.split) |
11:14:21 | * | skelett quit (*.net *.split) |
11:14:21 | * | Ckat quit (*.net *.split) |
11:14:21 | * | pbb quit (*.net *.split) |
11:14:21 | * | hax-scramper quit (*.net *.split) |
11:14:21 | * | gmpreussner quit (*.net *.split) |
11:14:21 | * | endragor quit (*.net *.split) |
11:14:21 | * | ehmry quit (*.net *.split) |
11:14:21 | * | ikan-keli_ quit (*.net *.split) |
11:14:21 | * | gangstacat quit (*.net *.split) |
11:14:21 | * | Yardanico quit (*.net *.split) |
11:14:21 | * | disbot quit (*.net *.split) |
11:14:21 | * | blueberrypie quit (*.net *.split) |
11:14:21 | * | hpyc9 quit (*.net *.split) |
11:14:21 | * | EastByte quit (*.net *.split) |
11:14:21 | * | cyraxjoe quit (*.net *.split) |
11:14:21 | * | d10n-work quit (*.net *.split) |
11:14:21 | * | zielmicha__ quit (*.net *.split) |
11:14:21 | * | WilhelmVonWeiner quit (*.net *.split) |
11:16:07 | * | dom96 joined #nim |
11:16:07 | * | dom96 quit (Changing host) |
11:16:07 | * | dom96 joined #nim |
11:17:08 | * | hohlerde quit (*.net *.split) |
11:17:08 | * | Yardanico[m] quit (*.net *.split) |
11:17:51 | * | r4vi joined #nim |
11:17:51 | * | jwm224 joined #nim |
11:17:51 | * | silvernode[m] joined #nim |
11:17:51 | * | BitPuffin joined #nim |
11:17:51 | * | skelett joined #nim |
11:17:51 | * | Ckat joined #nim |
11:18:01 | * | pigmej joined #nim |
11:18:01 | * | natrys quit (*.net *.split) |
11:18:02 | * | thomasross quit (*.net *.split) |
11:18:02 | * | vesper11 quit (*.net *.split) |
11:18:02 | * | narimiran quit (*.net *.split) |
11:18:02 | * | arecaceae quit (*.net *.split) |
11:18:03 | * | mal`` quit (*.net *.split) |
11:18:03 | * | Amun_Ra quit (*.net *.split) |
11:18:04 | * | kadin quit (*.net *.split) |
11:18:04 | * | blackbeard420 quit (*.net *.split) |
11:18:04 | * | d10n_ quit (*.net *.split) |
11:18:05 | * | Eyess quit (*.net *.split) |
11:18:07 | * | shashlick quit (*.net *.split) |
11:18:08 | * | GaveUp quit (*.net *.split) |
11:18:11 | * | s3govesus quit (Ping timeout: 247 seconds) |
11:18:13 | * | d10n joined #nim |
11:18:17 | * | setenforce joined #nim |
11:18:27 | * | chenhq2005_ joined #nim |
11:18:27 | * | skrylar joined #nim |
11:18:27 | * | PMunch joined #nim |
11:18:27 | * | muffindrake joined #nim |
11:18:27 | * | letto_ joined #nim |
11:18:27 | * | uvegbot joined #nim |
11:18:27 | * | FromGitter joined #nim |
11:18:27 | * | msmorgan joined #nim |
11:18:27 | * | tefter joined #nim |
11:18:27 | * | oprypin joined #nim |
11:18:27 | * | moon-chilled joined #nim |
11:18:46 | * | bozaloshtsh joined #nim |
11:18:48 | * | natrys joined #nim |
11:18:53 | * | pbb joined #nim |
11:18:53 | * | hax-scramper joined #nim |
11:18:53 | * | gmpreussner joined #nim |
11:18:53 | * | endragor joined #nim |
11:18:53 | * | ehmry joined #nim |
11:18:53 | * | ikan-keli_ joined #nim |
11:18:53 | * | gangstacat joined #nim |
11:18:53 | * | Yardanico joined #nim |
11:18:53 | * | disbot joined #nim |
11:18:53 | * | blueberrypie joined #nim |
11:18:53 | * | hpyc9 joined #nim |
11:18:53 | * | EastByte joined #nim |
11:18:53 | * | cyraxjoe joined #nim |
11:18:53 | * | zielmicha__ joined #nim |
11:18:53 | * | WilhelmVonWeiner joined #nim |
11:19:01 | * | matti joined #nim |
11:19:09 | * | GaveUp joined #nim |
11:19:13 | * | Amun_Ra joined #nim |
11:19:48 | * | d10n quit (Changing host) |
11:19:48 | * | d10n joined #nim |
11:20:18 | * | noonien quit (Ping timeout: 245 seconds) |
11:20:36 | * | r4vi quit (Ping timeout: 248 seconds) |
11:20:47 | * | mal`` joined #nim |
11:21:12 | * | gsingh93 quit (Ping timeout: 268 seconds) |
11:21:35 | * | MD87 quit (Ping timeout: 252 seconds) |
11:21:43 | * | r4vi joined #nim |
11:21:45 | * | SunDwarf joined #nim |
11:21:47 | * | LyndsySimon quit (Ping timeout: 260 seconds) |
11:21:49 | * | narimiran joined #nim |
11:21:52 | * | arecaceae joined #nim |
11:21:52 | * | blackbeard420 joined #nim |
11:22:03 | * | npgm quit (Ping timeout: 260 seconds) |
11:22:10 | * | SunDwarf is now known as Guest89399 |
11:22:21 | * | MD87 joined #nim |
11:22:31 | * | LyndsySimon joined #nim |
11:22:32 | * | vesper11 joined #nim |
11:23:14 | * | gsingh93 joined #nim |
11:23:14 | * | msmorgan quit (Ping timeout: 265 seconds) |
11:23:43 | * | npgm joined #nim |
11:23:48 | * | noonien joined #nim |
11:23:52 | * | shashlick joined #nim |
11:24:23 | * | msmorgan joined #nim |
11:24:37 | * | d10n-work joined #nim |
11:24:38 | * | nuxdie joined #nim |
11:32:34 | * | natrys quit (Quit: natrys) |
11:32:52 | * | natrys joined #nim |
11:38:36 | * | pbb quit (Quit: http://quassel-irc.org - Chat comfortably. Anywhere.) |
11:39:04 | * | pbb joined #nim |
11:47:58 | * | pbb_ joined #nim |
11:50:11 | * | pbb quit (Ping timeout: 252 seconds) |
11:59:57 | PMunch | dom96, no idea really. Think it's probably a couple of days |
12:01:32 | PMunch | Varriount, yes a guide like that would be helpful. But the difference in this case is kinda outlined in the description of the NimSym type: "Represents a Nim symbol in the compiler; a symbol is a looked-up ident." |
12:03:28 | PMunch | And Zevv, probably the easiest way to achieve that is to create a macro makeBox that takes a typed argument and returns "Box[thetype](val: thevalue)" and then have your current macro expand to "let a {.codegenDecl: "...".} = makeBox(thevalue)" |
12:04:00 | * | FromGitter quit (Remote host closed the connection) |
12:04:18 | * | FromGitter joined #nim |
12:04:54 | * | nsf quit (Quit: WeeChat 2.7) |
12:12:13 | * | abm quit (Ping timeout: 260 seconds) |
12:12:58 | * | krux02 joined #nim |
12:20:12 | * | endragor quit (Remote host closed the connection) |
12:20:39 | * | couven92 joined #nim |
12:27:41 | Zevv | PMunch: yeah, that is what I discussed with Vindaar this morning, should work. It was just that I was a bit flabbergasted with the error I had never met before |
12:28:44 | PMunch | Yeah, macros can be a bit complex :P |
12:28:53 | * | endragor joined #nim |
12:29:06 | PMunch | Can't really think of a way to make them much easier either.. |
12:30:06 | Zevv | Given my npeg adventures with macros I already counted myself as "one of the guys", but my naivity was again showing |
12:30:36 | Zevv | But really, I think I know my way around, but *always* its something type related if I run into problems |
12:31:00 | PMunch | Haha, working with the typed inputs are always a bit harder |
12:31:04 | Zevv | And I am not ashamed of my self: https://github.com/nim-lang/RFCs/issues/44 |
12:31:06 | disbot | ➥ [RFC] Working with types in macro is difficult. |
12:31:49 | PMunch | But yeah, the trick is just to "defer" the little type-checking you normally need to the output of your main macro. |
12:33:19 | * | endragor quit (Ping timeout: 265 seconds) |
12:33:24 | PMunch | I think it's mostly a documentation error, but maybe we should have a NimNode[typed] vs. NimNode[untyped] distinction that makes it a bit more obvious to the user what they are working with |
12:33:52 | Zevv | That would help indeed |
12:39:46 | * | cgfuh joined #nim |
12:50:25 | * | PMunch quit (Read error: Connection reset by peer) |
12:50:30 | * | PMunch_ joined #nim |
12:50:38 | * | PMunch_ is now known as PMunch |
12:54:36 | Araq | it's what OCaml does internally |
12:54:41 | Araq | I'm not sure if it helps or not |
12:55:01 | Araq | but types are really much harder than ASTs |
12:58:22 | Araq | "I ran that with nimble build which omits the compilation messages" |
12:58:32 | Araq | can somebody fix nimble please? |
13:07:07 | dom96 | Why? |
13:07:26 | dom96 | if you want output you can use `nimble c` |
13:13:44 | leorize | Araq: nimble build --debug |
13:13:47 | leorize | you're welcome |
13:14:10 | leorize | I'm aliasing nimble to nimble --debug so I can see the important stuff now |
13:17:37 | * | icebattle joined #nim |
13:22:27 | * | icebattle quit (Ping timeout: 265 seconds) |
13:28:21 | * | Kaivo joined #nim |
13:29:40 | * | kungtotte quit (Read error: Connection reset by peer) |
13:30:22 | * | kungtotte joined #nim |
13:31:36 | Araq | leorize, it's not about me |
13:31:55 | Araq | I quoted somebody from the forum. people run into this quite often. |
13:32:01 | leorize | nimble has this weird principle of "hiding the compiler" for whatever reason |
13:32:15 | leorize | this is a design decision and you'll have to convince it's author to change it |
13:32:32 | Araq | yes, that's exactly what I'm trying to do. |
13:32:41 | Araq | the design decision has no merit. |
13:37:40 | * | shashlick quit (Quit: quit) |
13:38:34 | * | shashlick joined #nim |
13:39:48 | * | marmotini_ joined #nim |
13:40:35 | * | marmotini_ quit (Remote host closed the connection) |
13:41:09 | * | marmotini_ joined #nim |
13:41:16 | * | marmotini_ quit (Remote host closed the connection) |
13:41:18 | Araq | feedback welcome: https://github.com/nim-lang/Nim/pull/13309 |
13:41:21 | disbot | ➥ new outplace operator: `doAssert @[2,1,3].@sort() == @[1,2,3]` ; snippet at 12https://play.nim-lang.org/#ix=2aLi |
13:41:31 | * | marmotini_ joined #nim |
13:44:01 | * | Vladar quit (Quit: Leaving) |
13:44:30 | PMunch | Wait, what exactly does that do? |
13:44:55 | leorize | basically an operator for the new outplace macro |
13:44:57 | dom96 | what is the point of this? |
13:44:58 | dom96 | We've already got two different ways to do sorting |
13:44:59 | dom96 | why add a third? |
13:45:12 | leorize | because it's not restricted to only sorting? |
13:45:24 | PMunch | Oooh, so it allows you to do dot-chain calls that take a var parameter? |
13:45:28 | narimiran | my concern is that `@` now would mean two completely different things |
13:46:57 | dom96 | leorize and what does `outplace` accomplish? |
13:47:14 | leorize | copy the parameter and pass it to a var function |
13:47:15 | dom96 | Outplace operator: turns an `in-place`:idx: algorithm into one that works on a copy and returns this copy. |
13:47:57 | leorize | allowing you to not have to write two versions of the same proc for example |
13:48:29 | dom96 | I'd rather get a macro which follows our conventions |
13:48:41 | leorize | what conventions? |
13:48:56 | dom96 | i.e. sort vs. sorted |
13:49:01 | dom96 | sort takes a `var`, sorted makes a copy. |
13:49:10 | leorize | please no |
13:49:19 | dom96 | It's simple and we can have a macro that means you don't have to duplicate code |
13:49:30 | dom96 | even though the duplication is so minor |
13:49:45 | dom96 | Please no from me on this operator |
13:50:55 | dom96 | Rather, a big no. This has such a small use case which is already handled by our convention that it doesn't make sense to introduce an obscure operator that everyone will need to learn |
13:51:00 | Araq | "minor duplication"? |
13:51:09 | Araq | it's a factor of 2 for almost every API |
13:51:33 | * | nsf joined #nim |
13:51:34 | leorize | look no further: strutils |
13:52:20 | dom96 | 4 lines: https://github.com/nim-lang/Nim/blob/devel/lib/pure/algorithm.nim#L437-L457 |
13:52:58 | dom96 | which could be easily abstracted away by a `copy` proc |
13:53:19 | Araq | oh really? and how do you write this 'copy' proc? |
13:53:25 | Araq | smartass :P |
13:53:53 | Araq | ever considered the people involved were not morons? |
13:53:56 | FromDiscord_ | <Rika> oof |
13:54:13 | dom96 | *shrug* 4 lines is still nothing |
13:54:45 | Araq | it's not how to count this. |
13:55:09 | FromDiscord_ | <Rika> you're only accounting for that one specific case |
13:55:30 | leorize | are you gonna introduce removedPrefix, removedSuffix? :) |
13:55:46 | Araq | narimiran, it's '.@' vs '@' |
13:56:05 | FromGitter | <Vindaar> I like the `@` operator for this. To me it feels sort of natural that it should be `@`. While not restricted to procs working on `var seq[T]` this is certainly a major use case. And then `@` just means "make me a tmp seq please!" |
13:56:10 | leorize | we need to operator to screams "copying" :P |
13:56:28 | FromDiscord_ | <Rika> Vindaar, but it's for anything mutable afaik, not just seqs |
13:56:35 | FromGitter | <Vindaar> that's what I said |
13:56:55 | FromDiscord_ | <Rika> but then the meaning wouldnt always mean "make me a temp seq" |
13:56:56 | dom96 | also, if a macro can be made to copy things generically why can't an actual `copy` macro be amde? |
13:56:57 | dom96 | *made |
13:57:15 | dom96 | Indeed, the `@` implies seqs, which apparently is just one specific case, right? :) |
13:57:15 | Araq | look, the operator is '.@' |
13:57:31 | Araq | you don't have to like it, but you can surely get the facts right |
13:57:56 | narimiran | Araq: i know it is really a `.@`, but to an "untrained eye" it looks like @ following the usual dot |
13:58:05 | Araq | I personally would use something else too |
13:58:22 | FromDiscord_ | <Rika> i really think "outOfPlace" would be the best name for this |
13:58:40 | FromGitter | <Vindaar> @Rika: of course not, but a majority of use cases involve those. So (to me anyways) it makes sense that this is where the idea for `.@` comes from |
13:58:42 | * | dddddd joined #nim |
13:58:44 | Araq | we already have the named version, 'outplace' is the best term for it |
13:58:56 | dom96 | `outplace` means nothing to me |
13:58:59 | Araq | problem with the named version is usability |
13:59:11 | dom96 | why not `copied` or something? |
13:59:40 | narimiran | how about `.!` ? |
13:59:40 | dom96 | and yeah, I don't care if it's there as a non-operator |
13:59:42 | Araq | it was considered to be more confusing. at least 'outplace' screams "ok, ok, I'm gonna look this one up" |
13:59:54 | FromDiscord_ | <Rika> `.!` what's the inspiration for this |
14:00:05 | Araq | whereas 'copied' might give you the wrong idea |
14:00:22 | dom96 | what idea could it give you that would be wrong? |
14:00:26 | narimiran | inspiration for `.!` are languages which have `mutating!` vs `nonmutating` |
14:00:41 | Araq | it's not about the copy, the copy is an unfortunate artifact |
14:00:44 | FromDiscord_ | <Rika> can i have a language name for those |
14:00:59 | Araq | it's about "don't mutate x here" |
14:01:18 | FromDiscord_ | <Rika> what about "noMut" or some sorta thing like that |
14:01:19 | dom96 | `copy` implies that perfectly |
14:01:36 | dom96 | s/copy/copied/ |
14:01:42 | Araq | algorithms can be in-place and we like them, but usability of them is worse, so we have outplace |
14:02:37 | narimiran | @Rika julia |
14:03:06 | FromDiscord_ | <Rika> i'll check their docs out a bit |
14:03:40 | FromDiscord_ | <Rika> hmm, it seems kinda localized to julia |
14:03:48 | FromDiscord_ | <Rika> i dont think rust does something like that? |
14:03:58 | FromDiscord_ | <Rika> hmm but rust doesnt have the best naming either |
14:04:21 | Araq | the point of this PR is to introduce an operator for usability |
14:04:26 | FromDiscord_ | <Rika> i think it's okay, the `.!` |
14:04:32 | Araq | and now you discuss a "better name for outplace" |
14:04:52 | Araq | have fun with that, but I'm out, have stuff to do. |
14:04:54 | * | Vladar joined #nim |
14:05:06 | FromDiscord_ | <Rika> see you |
14:05:07 | narimiran | @Rika https://docs.julialang.org/en/v1/manual/style-guide/#Append-!-to-names-of-functions-that-modify-their-arguments-1 |
14:05:23 | dom96 | same. I've given my opinion. I don't think this deserves an operator, at least for now. |
14:08:26 | * | ftsf quit (Ping timeout: 240 seconds) |
14:09:57 | FromDiscord_ | <Rika> narimiran i think it looks good honestly |
14:10:08 | narimiran | :) |
14:10:11 | FromDiscord_ | <Rika> but i think the after-function-name works better than the macro sadly |
14:11:29 | narimiran | to me `foo.@bar(baz)` would be confusing if i just came to nim and learnt that `$` converts to string, and `@` converts to seq. and now somebody is converting a function to a seq?!?! |
14:12:56 | dom96 | agree completely |
14:20:46 | FromDiscord_ | <kodkuce> still no araq fosdem video or i blind? |
14:20:55 | FromDiscord_ | <Clyybber> the name outplace is about the "inversion" of inplace mutation |
14:22:15 | FromDiscord_ | <Clyybber> I also like .! more than .@ |
14:22:38 | * | chenhq2005_ quit (Read error: Connection reset by peer) |
14:23:32 | FromDiscord_ | <Clyybber> .~ looks fine to me too |
14:24:29 | PMunch | By the way Araq, I tested casting a `ptr MyType` to an `Option[ptr MyType]` and it worked fine. So apart from being horrible it can actually make some code a bit nicer :) |
14:25:00 | PMunch | You can for example use my ?. conditional chaining operator on pointers that you get from C interop code |
14:36:52 | * | ofelas quit (Ping timeout: 268 seconds) |
14:43:04 | narimiran | leorize: i have a nim.nvim bug to report :) |
14:50:39 | * | marmotini_ quit (Remote host closed the connection) |
14:53:05 | * | marmotini_ joined #nim |
14:57:14 | FromGitter | <nixfreakz_twitter> Holy shit python versions of driving me crazy |
14:57:27 | FromGitter | <nixfreakz_twitter> now 3_8 is breaking everything |
15:01:56 | FromGitter | <alehander92> guys |
15:02:00 | FromGitter | <alehander92> so many operators |
15:02:09 | FromGitter | <alehander92> lets be calmer on this `@` thing |
15:02:57 | FromGitter | <alehander92> and `!` |
15:03:14 | FromGitter | <alehander92> as i expect `!` to mean "mutate/make something mutable" |
15:03:21 | FromGitter | <alehander92> and outplace iirc is the opposite? |
15:05:38 | FromGitter | <alehander92> `.~` maybe makes sense? just imo |
15:10:03 | Zevv | What is the reason to give this an operator at all then? |
15:14:32 | FromGitter | <alehander92> the problem i see is that for most algorithms |
15:14:39 | FromGitter | <alehander92> i expect the outplaced version to be default.. |
15:15:01 | leorize[m] | narimiran: :) please tell |
15:15:25 | FromGitter | <alehander92> e.g. map, filter, search, find, and for the inplace ones, it just makes sense to be delete vs deleted etc |
15:15:41 | narimiran | you are in the middle of your file, you press `gd` to go to definition, and then you hit ctrl+o to take you back where you've been. nope. |
15:15:55 | leorize[m] | Zevv: @timotheecour started the idea, we are just debating it |
15:16:05 | FromGitter | <alehander92> and such a scheme would mean that idiomatic would be to do a.filter(b) => changes a, a.~filter(b) => return new |
15:16:16 | FromGitter | <alehander92> which might make sense, i am just not sure about it |
15:16:30 | FromGitter | <alehander92> (talking as an example user) |
15:17:01 | FromGitter | <alehander92> otherwise, its very elegant to be able to automatically outplace them |
15:17:36 | leorize[m] | narimiran: hmm, I'll look into it when I get home, but I'm pretty sure I set the ' register before I move the cursor |
15:17:37 | Zevv | Ha just got a message from the CTO from https://eclypsium.com/, they want to go run Nim in the linux kernel. |
15:17:50 | FromGitter | <alehander92> a.with(delete(b)) a.with(sort(b)) ? |
15:18:21 | leorize[m] | Zevv: nice :) you suddenly have a potential paying customer |
15:20:29 | PMunch | Oh cool, and they are serious about it? |
15:20:34 | Zevv | Well, I have no shortage of *actual" paying customers as of yet, but it is nice to keep that warm |
15:21:09 | Zevv | PMunch: no clue, just got a "Hey we found this, what is the status" about something I did a year ago. So the new --gc:arc --os:any stuff comes in just in time for that |
15:21:32 | FromGitter | <kristianmandrup> How can I make a template or macro that takes a table (Object/Hashmap) and spits it out again in some different AST or emit context? |
15:21:52 | Zevv | how do you mean 'different context'? |
15:22:00 | Zevv | You want to eat it here and emit it in a different place? |
15:22:02 | PMunch | Oh cool |
15:22:51 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e398c4b58f02e349761bea3] |
15:23:31 | FromGitter | <kristianmandrup> For some reason Nim playground gives me a 502 error when trying to share |
15:23:38 | * | ng0_ joined #nim |
15:24:08 | narimiran | leorize[m]: now i tried '' (double single quote) to take me back after `gd`, and it took me to some random position |
15:24:13 | FromGitter | <kristianmandrup> I'm trying to make Nim emit a JS decorator syntax for a decorator name, arguument(s) and a proc |
15:26:49 | * | ng0 quit (Ping timeout: 268 seconds) |
15:27:12 | disruptek | narimiran: use ctrl-o to jump backwards to previous positions in vi. |
15:27:27 | narimiran | disruptek: read the whole discussion first :P |
15:28:08 | disruptek | ahh |
15:29:07 | * | ng0_ is now known as ng0 |
15:31:10 | disruptek | alehander92: yeah, i don't want more operators yet. let me assign them myself until they are defacto. |
15:32:22 | leorize[m] | narimiran: looks like I'm not setting it correctly |
15:32:37 | narimiran | leorize[m]: i want my full refund!! |
15:33:50 | disruptek | wow, nimnode[typed|untyped]; that sounds really interesting. |
15:34:24 | FromGitter | <alehander92> hmmmmm |
15:36:14 | * | JustASlacker quit (Remote host closed the connection) |
15:37:11 | * | Vladar quit (Quit: Leaving) |
15:41:24 | disruptek | narimiran: missed you at fosdem. 🙁 |
15:41:46 | narimiran | sorry :) |
15:43:16 | disruptek | we have sneaky untyped/typeclassed dispatch in templates like untyped{nkIdent}; can we do something similar for nimnode? |
15:43:19 | Araq | PMunch, got no email from FOSDEM :-( |
15:44:38 | * | couven92 quit (Read error: Connection reset by peer) |
15:45:02 | * | lritter joined #nim |
15:45:03 | Araq | dom96, I want your opinion after you understood the problem. And I want your opinion specialized to the situation. I already know that don't like new operators |
15:46:18 | Araq | and yeah, other languages simply don't solve the problem, ok. fair enough. we could be better than the others but whatever. |
15:46:47 | Araq | let's all strive for mediocrity everywhere because somebody could be confused or scared |
15:47:05 | disruptek | on it. 👍 |
15:48:26 | disruptek | Araq: it would be good to see more examples of how this stuff would look in real code; ie. what's the value of the enhancement. |
15:48:40 | disruptek | just looking at one-liners doesn't really impress. |
15:48:49 | * | floppydh quit (Quit: WeeChat 2.7) |
15:48:50 | Araq | we can remove sorted() from the stdlib |
15:49:16 | Araq | and don't need removedPrefix (vs removePrefix), see strutils, it's full of this problem |
15:49:47 | disruptek | yes, but the solution isn't as simple as s/ed/@/ |
15:50:42 | lqdev[m] | is $ for floats locale-independent? |
15:50:53 | Araq | lqdev[m], no, it is not. |
15:50:59 | Araq | er |
15:51:05 | Araq | yes it is *in*dependent |
15:51:12 | Araq | sorry I misread. |
15:51:41 | Araq | a couple of years ago I actually wanted to make this a language feature, disruptek |
15:51:43 | lqdev[m] | glad to hear that Nim's fixing C's mistakes again. |
15:52:01 | Araq | the language rule would have been something like: |
15:52:44 | disruptek | yes, and it's a good feature. but it was already added in `outplace`. let's see how to use it before we commit our first sigil operator to it. |
15:52:57 | Araq | "if f(args) returns void and is used in a non-void context, it is rewritten to (let tmp; f(tmp, args); tmp)" |
15:53:57 | Araq | my point is: I personally care a lot about this feature. |
15:53:58 | Zevv | that makes me seriously ambivalentic. I hate that but I'd use the hell out of it. |
15:54:14 | disruptek | Araq: then you should make it work exactly the way you expect. |
15:54:33 | disruptek | you probably understand it much better than anyone else; let's be realistic. |
15:55:16 | Araq | a special language rule bites our philosophy though, "Nim = small core + macro system" |
15:55:40 | Araq | and yeah I know we don't have a "small core" anymore but this cannot be an excuse for bloating it more than necessary |
15:56:01 | Araq | so a specialized operator is actually quite close to my ideal |
15:56:25 | disruptek | well, you know my opinion: if you want to use it in the compiler, it's okay in stdlib. |
15:57:16 | dom96 | Araq: ping me in 4 hours, can't spend too much time on it right now |
15:57:34 | Zevv | but hey, it goes into sugar and not in system |
15:59:27 | Araq | we can also make it an 'outplace' module |
15:59:34 | Araq | and all it contains is .@ |
16:00:27 | disruptek | that sounds better to me. |
16:00:45 | Araq | it's syntax, we can bikeshed about it, but I think Timothee is right |
16:01:00 | Araq | before we can say "ok, it's not used much" we need to make it convenient |
16:01:20 | Araq | and then we can still say "ok, nobody cared" and later on deprecate it again |
16:01:40 | Zevv | or upgrade and move it into system |
16:01:46 | disruptek | please no. |
16:02:41 | disruptek | anyway, if you want to use it, please do use it. otherwise, it's like saying a package manager is unsuitable because it uses packages. |
16:03:11 | disruptek | it makes no sense to carefully hone sharp code and then leave it in the corner because it's too sharp. |
16:04:26 | disruptek | spend a week building a ladder and then cut it in half so you can fit it in the elevator. |
16:08:40 | FromDiscord_ | <Clyybber> disruptek: Thing is, outplace only really makes sense with an operator |
16:08:52 | FromDiscord_ | <Clyybber> since it mimics UFCS |
16:14:50 | Zevv | Ha, now the guy asked me if I would recommend using Rust or Nim for kernel driver develoment. |
16:15:32 | Zevv | pretty great that he is even *considering* not using C |
16:18:20 | FromDiscord_ | <Clyybber> muh safety |
16:20:38 | Araq | Clyybber: does that mean you like .@ too? |
16:20:56 | * | ptdel joined #nim |
16:23:43 | FromDiscord_ | <Clyybber> I like having an operator for it, but I think .! or .~ would fit better |
16:24:09 | FromDiscord_ | <Rika> .! makes at least more sense than .@ |
16:28:58 | shashlick | @Araq - $13307 is ready to go |
16:29:04 | shashlick | #13307 |
16:29:05 | disbot | https://github.com/nim-lang/Nim/pull/13307 -- 3Fix #10717, fix #13284 |
16:29:30 | FromDiscord_ | <exelotl> lol I want $13307 |
16:29:32 | Araq | I just played with it, for me ./ looks best |
16:30:05 | Araq | it's like "oh yeah, use 'x' as the current operand" :P |
16:32:07 | Araq | btw (a & b) == a ./add b |
16:32:08 | FromDiscord_ | <Clyybber> Yep ./ i like too |
16:32:35 | Araq | add vs &, the full += family of operators from C ... it's everywhere |
16:37:21 | * | Vladar joined #nim |
16:38:06 | FromGitter | <kristianmandrup> Any videos up from FOSDEM? |
16:39:18 | FromDiscord_ | <Clyybber> doms and pmunchs |
16:39:58 | Araq | still got no email from them :-( |
16:42:56 | disruptek | i guess ./ won't work with operateOn, then. |
16:43:16 | Araq | lol |
16:46:19 | lqdev[m] | if I want to hash a custom AST node using `hashes`, would I do it like this? http://ix.io/2aLz |
16:46:26 | lqdev[m] | or do I need to put some special care into it |
16:46:37 | lqdev[m] | forgot to !$ the hash at the end |
16:48:00 | dom96 | Araq join #fosdem-video and ask there |
16:48:14 | FromDiscord_ | <Clyybber> Ideally operatoeOn wouldn't be needed anymore |
16:48:21 | dom96 | and double check your spam folder, it went there for me and I couldn't find it even when searching for the email until I went straight into the folder |
16:49:15 | disruptek | clyybber: whoosh |
16:49:46 | FromGitter | <kristianmandrup> Can I `break` from a for loop? what is the best way in Nim to iterate through a list and add to `result` while each item matches condition, then "break out" when condition no longer. ⏎ I'd think a `while` loop should do? |
16:50:13 | disruptek | you can break. sadly, there is no named continue, but there are named breaks. |
16:50:22 | disruptek | Araq: named continue? |
16:50:54 | lqdev[m] | disruptek: how'd you expect that to work? |
16:51:01 | disruptek | also, see the sequtils module and keepIf or whatever. |
16:51:46 | disruptek | lqdev: it's a java feature. |
16:52:24 | FromGitter | <kaushalmodi> @kristianmandrup Yes, use `break` |
16:53:25 | lqdev[m] | lqdev: but java also has named loops. |
16:53:35 | disruptek | you tell him, lqdev! |
16:53:50 | * | ptdel quit (Ping timeout: 265 seconds) |
16:55:48 | FromDiscord_ | <Clyybber> no named loops, no named continue? |
16:55:59 | FromDiscord_ | <Clyybber> just use a break? |
16:56:49 | FromDiscord_ | <Clyybber> leorize: Yo, what should I use for make then? |
16:57:03 | FromDiscord_ | <Clyybber> Instead of -j -l (nproc) ? |
16:58:16 | leorize | Clyybber: make -j (nproc) optionally with -l (nproc) |
16:58:23 | disruptek | i usually use nproc*1.25. |
16:58:34 | leorize | the unofficial algo is -j nproc + 2 -l nproc |
16:58:48 | FromGitter | <kristianmandrup> Is this even remotely possible in Nim? ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39a2c873ddad4acd90ff7d] |
16:58:50 | leorize | that's used by ninja iirc |
16:59:35 | FromGitter | <kristianmandrup> Trying to extend Nim OOP macro example: https://nim-by-example.github.io/oop/ |
17:00:24 | leorize | @kristianmandrup: I'm not even sure what you're trying to achieve here |
17:00:31 | * | matti quit () |
17:00:42 | disruptek | that `for node, index of` dog won't hunt. |
17:01:02 | * | matti joined #nim |
17:01:35 | disruptek | neither will your incomplete case statement. who wrote this and can i get some of whatever they were smoking? |
17:03:09 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39a3cddc52c34ace462cfc] |
17:03:23 | FromGitter | <kristianmandrup> Just "sketching" for now... |
17:03:47 | FromGitter | <kristianmandrup> Trying to add decorator support for JavaScript OOP methods, building on OOP macro |
17:04:21 | FromDiscord_ | <Clyybber> ok, I'll do -j (nproc + 2) -l (nproc) then |
17:04:22 | disruptek | oh, i see. |
17:04:45 | FromGitter | <Vindaar> @kristianmandrup I'm not familiar with JS decorators. Can you give an example of what kind of code you want to generate? |
17:04:56 | FromGitter | <kristianmandrup> A lot of modern JavaScript libraries rely on/require decorators |
17:05:39 | FromGitter | <kristianmandrup> https://netbasal.gitbook.io/akita/core-concepts/store |
17:05:44 | FromGitter | <Varriount> Araq: For what it's worth, I also don't agree that outplace should have an operator yet |
17:06:44 | FromGitter | <kristianmandrup> @Vindaar here |
17:06:53 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39a4acdc52c34ace462f3e] |
17:07:08 | leorize | I though decorators are still in the "proposal" state? |
17:07:12 | FromGitter | <kristianmandrup> But there are similar cases with decorators for methods |
17:07:22 | disruptek | these are manual-hack decorators. |
17:07:22 | leorize | is there any web browser that actually support this? |
17:07:33 | FromGitter | <kristianmandrup> Yeah, but being used heavily with Babel and Typescript, such as in NestJS, Angular etc. |
17:08:02 | Araq | Varriount: it's always fine to disagree with me, once you understood the problem. |
17:08:09 | disruptek | not sure how you can control placing the decorator adjacent to the proc in the generated code. |
17:08:31 | FromGitter | <kristianmandrup> Well, that's my question - if that is even possible? |
17:08:44 | disruptek | maybe you can do this with a proc prototype. |
17:08:56 | FromGitter | <kristianmandrup> if I can combine `emit` macro with macro AST output somehow? |
17:09:09 | leorize | generate emit statements yourself |
17:09:14 | disruptek | he is. |
17:10:02 | disruptek | i guess i would start by seeing if you can inject anything at all in the proper spot; a comment, perhaps. |
17:10:59 | leorize | https://play.nim-lang.org/#ix=2aLD |
17:11:09 | leorize | just generate the right AST nodes |
17:11:15 | * | Trustable joined #nim |
17:11:26 | leorize | I'm not sure if the resulting statements will be at where you expect it to be though |
17:13:07 | leorize | it'd be easier if you can scope the decorator with (ie. {}) |
17:15:20 | FromDiscord_ | <Rika> oh hey the discord update also made it easier to read the irc logs now |
17:15:58 | FromGitter | <kristianmandrup> @leorize when I click run in the playground, I don't see any output |
17:16:19 | FromGitter | <kristianmandrup> When I try to run it locally |
17:16:22 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39a6e6f301780b8366a502] |
17:16:23 | leorize | kristimandrup: switch to debug view |
17:16:35 | leorize | the default output view doesn't show compiler messages |
17:16:52 | disruptek | rika: huh? |
17:17:00 | FromGitter | <kristianmandrup> I see |
17:17:05 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39a71173ddad4acd910c57] |
17:17:10 | leorize | also nim module name has to be a valid identifier |
17:17:44 | leorize | and `macro-emit-ast` is not a valid nim identifier :P |
17:17:48 | FromGitter | <kristianmandrup> So I can just output the raw AST nodes that the `emit` would generate sprinkled around the rest of the target AST... |
17:18:18 | FromGitter | <kristianmandrup> `invalid command: macro_emit_ast.nim` |
17:18:29 | leorize | also not `-c` but `c` |
17:18:30 | FromGitter | <kristianmandrup> No underscore allowed in file names? |
17:18:43 | FromGitter | <kristianmandrup> ok, works now |
17:19:50 | leorize | i don't think the js generator is designed for anything other than web though |
17:20:21 | leorize | I don't think it can generate proper typescript fwiw |
17:20:49 | FromGitter | <kristianmandrup> `Unable to load ix paste, file too large, or download is too slow` |
17:20:57 | leorize | but I'm not too familiar with all these stuff so *shrug* |
17:21:23 | leorize | kristianmandrup: just reload, ix.io can be overloaded at times |
17:22:04 | leorize | narimiran: I... can't reproduce the bug |
17:23:09 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39a87d594a0517c2682394] |
17:23:15 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39a883e8a83835591614de] |
17:23:35 | FromGitter | <kristianmandrup> ah, perhaps just `string`? |
17:25:36 | leorize | try this: https://play.nim-lang.org/#ix=2aLG |
17:27:22 | narimiran | leorize: hmm, interesting. |
17:27:40 | FromGitter | <kristianmandrup> cool, How would I parameterise the raw StrLit AST node? |
17:27:57 | leorize | use newStrLit() :P |
17:28:47 | FromGitter | <Vindaar> @kristianmandrup the problem I see is that even if you define e.g. your procs also in the same template / macro, the emitted code will end up anywhere, not necessarily above the proc |
17:29:28 | FromGitter | <kristianmandrup> @Vindaar I get this output now |
17:29:37 | FromGitter | <kristianmandrup> ```@decoratorName( ⏎ rawEcho();``` [https://gitter.im/nim-lang/Nim?at=5e39aa01dc52c34ace463f2b] |
17:29:41 | FromGitter | <kristianmandrup> Not too far off |
17:30:58 | FromGitter | <Vindaar> ```code paste, see link``` ⏎ ⏎ for instance. Look at the output in the shell and then at the generated JS file (when compiling with `nim js ...`) [https://gitter.im/nim-lang/Nim?at=5e39aa5258f02e3497621019] |
17:31:19 | FromGitter | <Vindaar> the decorator appears anywhere, but not where I put it |
17:31:24 | leorize | narimiran: can I have your reproduction sequence? |
17:31:53 | narimiran | leorize: i don't know if it makes a difference, this is a long file where i lose syntax highlighting in the middle of it |
17:33:21 | narimiran | to reproduce it: open testament/testament.nim, go to line 630, over `gTargets`. press `gd`, then `C-o` and it will take you back to `gTargets` on line 503 |
17:33:24 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39aae3594a0517c2682b37] |
17:33:56 | FromGitter | <kristianmandrup> why can't I concatenate a string? I need to use `$name` ? |
17:34:05 | narimiran | oh, and it is vice-versa! `gd` on line 503, `C-o` puts you on line 630 |
17:34:25 | FromDiscord_ | <Clyybber> Araq: Can I merge https://github.com/nim-lang/Nim/pull/13320 ? |
17:34:26 | disbot | ➥ build_all.sh update |
17:34:38 | FromDiscord_ | <Clyybber> when the CI's have finished of course |
17:35:00 | narimiran | nvm, it is a coincidence, because that's where i was |
17:35:13 | leorize | narimiran: reproduced |
17:35:49 | narimiran | it seems like C-o takes you two steps back (where you were before `gd`), not one |
17:36:24 | leorize | it appears to me that my changes to the ' mark wasn't sticking |
17:38:55 | FromGitter | <kristianmandrup> https://play.nim-lang.org/#ix=2aLH |
17:44:06 | * | ptdel joined #nim |
17:46:13 | FromGitter | <kennymalac> any reason there isn't a decodeQuery counterpart to https://nim-lang.org/docs/uri.html#encodeQuery%2CopenArray%5B%5D ⏎ uri |
17:46:38 | leorize | dom96 wrote one but it got stuck in the pr queue iirc |
17:46:42 | leorize | !search decodeQuery |
17:46:44 | disbot | https://github.com/smola/galimatias/issues/31 -- 3Add encoding/decoding utils 7& 29 more... |
17:46:51 | leorize | !search decodeQuery nim-lang/Nim |
17:46:52 | disbot | no results 😢 |
17:46:55 | FromGitter | <kristianmandrup> How can I make the `StrLit` dynamic |
17:47:03 | leorize | !search decode query nim-lang/Nim |
17:47:03 | disruptek | !pull decodeQuery |
17:47:03 | disbot | no results 😢 |
17:47:04 | disbot | https://github.com/nimterop/nimterop/issues/120 -- 5recursion: undeclared identifier 7& 2 more... |
17:47:46 | FromGitter | <Vindaar> @kristianmandrup what do you mean dynamic? a `StrLit` is a string *literal* and thus static by definition |
17:48:44 | FromGitter | <kristianmandrup> https://play.nim-lang.org/#ix=2aLH |
17:48:54 | leorize | #7761 |
17:48:54 | disruptek | the !search is for any issue in any nim repo, with fallback to any issue anywhere. !issue(s) is for nim issue; !pull(s) is for nim PRs. |
17:48:55 | disbot | https://github.com/nim-lang/Nim/pull/7761 -- 3Implements parseQuery in uri module. |
17:49:39 | leorize | kennymalac: ^ you can try to base a new PR over that to get it into the stdlib |
17:49:58 | FromGitter | <Vindaar> @kristianmandrup I don't understand the problem. Give an example of what you want to do |
17:51:22 | FromGitter | <kennymalac> I'll comment on the issue |
17:51:43 | FromGitter | <kennymalac> not sure I'm comfortable enough to be merging into and devving on the stdlib XD |
17:52:22 | FromGitter | <kristianmandrup> @Vindaar I want to replace the pragma emit output with AST nodes in the macro |
17:52:47 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39af6f433e1d40399612d2] |
17:53:29 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39af9958f02e3497621dbd] |
17:53:41 | FromGitter | <kristianmandrup> Playground keeps crashing on my end :P |
17:54:30 | FromGitter | <Vindaar> you mean you want the value of the string literal `name` and not `"name"`, right? have you looked at the code I posted further up? |
17:57:11 | FromGitter | <kristianmandrup> yes exactly, I used your code as a foundation, but I need the AST nodes, not emit, as I need to integrate the "decorator AST" with the `body` arg, ideally |
17:59:37 | FromGitter | <kristianmandrup> I guess I need to use the `nnk` functions |
17:59:44 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39b110bfe65274eadd00b6] |
18:00:19 | * | jjido joined #nim |
18:00:55 | FromGitter | <Vindaar> ```code paste, see link``` ⏎ ⏎ you mean this? [https://gitter.im/nim-lang/Nim?at=5e39b157bfe65274eadd0100] |
18:01:24 | FromGitter | <Vindaar> otherwise I don't get what you mean, sorry :| |
18:02:15 | madprops | how can I get the last n items of a seq? |
18:02:45 | narimiran | s[s.len-n ..< s.len] |
18:03:07 | FromGitter | <kristianmandrup> Thanks @Vindaar - getting close |
18:03:08 | FromGitter | <kristianmandrup> /usercode/in.nim(2, 19) Error: undeclared identifier: 'quote' |
18:03:17 | madprops | I think there's a shortcut |
18:03:17 | FromGitter | <Vindaar> @kristianmandrup you have to `import macros` |
18:03:31 | FromGitter | <Vindaar> @madprops `s[^n .. ^1]` |
18:03:53 | narimiran | yep, what @Vindaar said |
18:04:46 | madprops | that's the one. It's hard to remember |
18:04:58 | madprops | i find stuff like ..-n or something more natural |
18:05:28 | madprops | im guessing ^1 means: start at the very end |
18:05:42 | FromDiscord_ | <Recruit_main_70007> yep |
18:07:08 | narimiran | madprops: you can't use `-3..-1` in nim, because we have arrays with custom indices |
18:07:24 | narimiran | e.g. array[-5..5, int] |
18:07:56 | FromGitter | <kristianmandrup> @Vindaar yes, got it to run and output AST locally |
18:09:15 | * | drewr joined #nim |
18:11:39 | FromGitter | <kristianmandrup> But I would still like the `info` (decorator name) to be dynamic, ie. passed as an argument to a template, macro or similar |
18:12:09 | madprops | is there a variation of [^n..^1] that doesn't fail depending on the number of items? |
18:12:26 | madprops | like get 4 items if n is 10 and the list has 4 items |
18:12:34 | FromGitter | <Vindaar> @kristianmandrup when you say dynamic, do you mean dynamic in the sense of "at runtime" or just taken as a variable? The former isn't possible, but the latter should be easy |
18:13:08 | FromGitter | <Vindaar> but keep in mind that the value of that variable has to be defined at compile time too! |
18:13:58 | FromGitter | <kristianmandrup> compile time macro function with argument? |
18:14:31 | FromGitter | <kristianmandrup> yes, compile time dynamic |
18:15:26 | FromGitter | <kristianmandrup> Here example from react binding lib |
18:15:27 | FromGitter | <Vindaar> yeah, that's fine. ⏎ But just a tip from me: before you start writing macros, write the exact code you want to generate by hand. When you have a couple of cases where you do the same, with exchangeable parts *then* start thinking about a macro. If you don't know exactly what code to generate there's no hope to succeed |
18:15:43 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39b4ceea9ba00b84afc0b6] |
18:15:47 | FromGitter | <Vindaar> (unless you know exactly in your head what you want to generate and know it's possible of course) |
18:16:17 | FromGitter | <kristianmandrup> I wan't sth very similar, just with decorator syntax in output (or `@` prefix for identifier essentially) |
18:17:29 | FromGitter | <Vindaar> but again, are you sure you know how to generate the correct JS code given some Nim code? |
18:17:53 | FromGitter | <Vindaar> that is fix the decorator to the proc in the way it's required |
18:25:26 | FromGitter | <kristianmandrup> @Vindaar no, Im not sure. I'm trying and learning... |
18:26:13 | FromGitter | <kristianmandrup> but a js decorator call is just a normal function call, with a prefix `@` on the function name (identifier) |
18:26:38 | FromGitter | <Vindaar> @kristianmandrup I'm not trying to criticize you, sorry if I sound harsh. I'm just trying to tell you that templates and macros are not a magical solution. They help to reduce boilerplate, but only if one understands the problem |
18:27:46 | leorize | narimiran: fixed |
18:27:47 | FromGitter | <kristianmandrup> ok, I just realised all I need is a macro/template to prefix a Nim function call (identifier) with a `@` so that `x(2)` becomes `@x(2)` |
18:27:52 | FromGitter | <Vindaar> wait, it's like a function call? I thought it was something similar to python's @ decorators |
18:28:54 | narimiran | leorize: thanks! |
18:28:58 | FromGitter | <kristianmandrup> Just need to transform the function call identifier (first node of body) |
18:30:10 | FromGitter | <kristianmandrup> ```if body.children[0].kind === Ident: ⏎ # transform Ident so that x becomes @x``` [https://gitter.im/nim-lang/Nim?at=5e39b832ea9ba00b84afcbe2] |
18:30:53 | FromGitter | <Vindaar> if it's only (!) for a call, even: |
18:31:01 | FromGitter | <Vindaar> ```code paste, see link``` ⏎ ⏎ is enough [https://gitter.im/nim-lang/Nim?at=5e39b86540da694c5e097997] |
18:31:22 | FromGitter | <Vindaar> generates ⏎ ⏎ ```var x_94285 = 5; ⏎ @someProc(5)``` [https://gitter.im/nim-lang/Nim?at=5e39b87adc52c34ace466856] |
18:31:36 | FromGitter | <kristianmandrup> cool :) |
18:31:43 | FromGitter | <Vindaar> oh, weird, that the 5 is inserted there |
18:31:51 | FromGitter | <Vindaar> haha |
18:31:53 | FromGitter | <Vindaar> nvm |
18:32:06 | FromGitter | <Vindaar> should have been `someProc(x)` of course in the arg |
18:34:10 | FromGitter | <kristianmandrup> VERY NICE |
18:34:26 | FromGitter | <kristianmandrup> Can you do sth similar for `import`? `import { Store } from '@datorama/akita';` |
18:35:43 | * | Pqzcih5 quit (Ping timeout: 240 seconds) |
18:36:23 | FromGitter | <kristianmandrup> My previous "attempt" ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39b9a7f6945f41ef5b508f] |
18:37:24 | * | Pqzcih5 joined #nim |
18:40:33 | FromGitter | <Vindaar> you mean like this? ⏎ ⏎ ```import { Stuff } from '@aba/bcb';``` [https://gitter.im/nim-lang/Nim?at=5e39baa1594a0517c26852d7] |
18:43:18 | FromGitter | <kristianmandrup> yes |
18:43:30 | FromGitter | <kristianmandrup> exactly, except without the `@` |
18:46:30 | Zevv | damn ix.io is so flaky |
18:48:17 | FromGitter | <kristianmandrup> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e39bc71fe0e6f74e9007470] |
18:48:28 | FromGitter | <kristianmandrup> I get `Error: cannot evaluate at compile time: name` |
18:51:09 | FromGitter | <kristianmandrup> ah yes, needs to be a template to be called compile time ;) |
18:52:38 | FromGitter | <Vindaar> well you could make the args be `static string`, but then it'd still be a proc and the emitted code would be emitted inside of that proc. But I assume you want to emit it globally |
18:53:06 | * | Ckatt joined #nim |
18:54:08 | disruptek | you guys are making my teeth hurt. |
18:56:14 | FromGitter | <kristianmandrup> @Vindaar https://play.nim-lang.org/#ix=2aLY |
18:56:32 | * | Ckat quit (Disconnected by services) |
18:56:32 | * | Ckatt is now known as Ckat |
18:56:38 | FromDiscord_ | <itmuckel> Hey guys! When I'm executing this code, it throws an OS error (invalid argument or so, it's in german unfortunately). I can't figure out which argument is wrong. I thought this would block until a udp packet was received. 🤔 |
18:56:38 | FromDiscord_ | <itmuckel> https://cdn.discordapp.com/attachments/371759389889003532/674327466697031690/unknown.png |
18:56:41 | FromGitter | <kristianmandrup> Error: invalid pragma: "# = x_" |
18:57:33 | FromDiscord_ | <itmuckel> (it fails in the recvFrom-line) |
18:58:53 | FromGitter | <Vindaar> @kristianmandrup where is that `importjs` pragma defined? |
18:59:13 | FromGitter | <Vindaar> in any case there has to be a `:` after `importjs` |
18:59:46 | FromDiscord_ | <Recruit_main_70007> @itmuckel try to do: |
18:59:46 | FromDiscord_ | <Recruit_main_70007> socket.connect(add, port) |
18:59:46 | FromDiscord_ | <Recruit_main_70007> |
18:59:46 | FromDiscord_ | <Recruit_main_70007> and then just socket.recv(2) |
18:59:48 | * | pigmej quit (*.net *.split) |
19:00:30 | * | Kaivo quit (*.net *.split) |
19:00:31 | * | jwm224 quit (*.net *.split) |
19:00:32 | * | silvernode[m] quit (*.net *.split) |
19:00:32 | * | BitPuffin quit (*.net *.split) |
19:00:32 | * | skelett quit (*.net *.split) |
19:01:57 | * | pigmej joined #nim |
19:02:15 | * | Kaivo joined #nim |
19:02:15 | * | jwm224 joined #nim |
19:02:15 | * | silvernode[m] joined #nim |
19:02:15 | * | BitPuffin joined #nim |
19:02:15 | * | skelett joined #nim |
19:03:34 | FromDiscord_ | <Clyybber> huh why is it in german tho |
19:03:47 | FromDiscord_ | <itmuckel> Okay, now it hangs indefinitely, and my message doesn't arrive |
19:04:07 | FromDiscord_ | <itmuckel> That's the sending code |
19:04:07 | FromDiscord_ | <itmuckel> https://cdn.discordapp.com/attachments/371759389889003532/674329353688973364/unknown.png |
19:05:01 | FromDiscord_ | <itmuckel> And why must I connect? I thought UDP is connectionless and I can just recv from any address and sendTo any address without setup. |
19:05:42 | FromDiscord_ | <itmuckel> @Clyybber 😏 |
19:06:23 | FromDiscord_ | <Clyybber> ah deshalb |
19:06:53 | FromGitter | <kennymalac> Anyone looking for nim gigs? Looking for some devs to do some cool stuff. |
19:07:28 | FromDiscord_ | <Clyybber> @itmuckel you are not using the deprecated sockets module are you? |
19:07:31 | narimiran | @kennymalac can you be more specific than "some cool stuff"? :) |
19:07:52 | FromGitter | <kristianmandrup> @Vindaar Still struggling :P |
19:08:14 | FromGitter | <kristianmandrup> https://play.nim-lang.org/#ix=2aM2 |
19:09:00 | FromDiscord_ | <Clyybber> @itmuckel ~you are not using the deprecated sockets module are you?~ nevermind |
19:09:13 | FromDiscord_ | <Clyybber> @itmuckel ~~you are not using the deprecated sockets module are you?~~ nevermind |
19:09:19 | FromDiscord_ | <itmuckel> @Clyybber `import net` |
19:09:27 | FromDiscord_ | <Clyybber> ok |
19:09:28 | FromGitter | <Vindaar> @kristianmandrup what kind of code do you need for the import of variables? |
19:11:04 | FromGitter | <kennymalac> @namiran web service pieces for a Big Data visualiztaion startup |
19:11:09 | FromGitter | <kennymalac> visualization* |
19:12:06 | FromGitter | <kristianmandrup> @Vindaar I need to dynamically link (assign) a Nim `var x` to the emitted imported JS identifier `x$$` or whatever I decide to name it (shadowed var) |
19:12:30 | FromGitter | <kristianmandrup> ie. `var x = x$$` while being able to access `x` as a Nim variable |
19:15:49 | FromDiscord_ | <itmuckel> @Clyybber @Recruit_main_70007 got it working. Had to replace `socket.connect()` with `socket.bindAddr(Port(1234), address)`. |
19:16:38 | FromDiscord_ | <itmuckel> The sender didn't had to call bindAddr, but it probably will once it wants to recv messages too. 🤷♂️ |
19:20:36 | FromGitter | <kristianmandrup> JSFFI, JQuery example no longer works |
19:20:37 | FromGitter | <kristianmandrup> https://play.nim-lang.org/#ix=2aM6 |
19:21:13 | FromGitter | <kristianmandrup> Complains about unescaped `$` Error: invalid extern name: '$(#)'. (Forgot to escape '$'?) |
19:21:29 | FromGitter | <kristianmandrup> From https://nim-lang.org/docs/jsffi.html |
19:23:40 | FromGitter | <Vindaar> no clue about that. I'm don't know the syntax of the `importcpp` pragma. Also not sure how you'd want to refer to an imported statement by a Nim var, since we use emit and thus the nim compiler doesn't really know anything about what you import |
19:32:50 | FromDiscord_ | <Clyybber> @itmuckel nice |
19:37:02 | * | nsf quit (Quit: WeeChat 2.7) |
19:38:13 | * | leorize quit (Quit: WeeChat 2.6) |
19:42:13 | FromDiscord_ | <Lantos> are fosdem videos up yet? |
19:44:50 | Araq | some |
19:44:59 | Araq | not mine tough... |
19:45:06 | FromDiscord_ | <Clyybber> @Lantos Two of them: https://video.fosdem.org/2020/AW1.125/nimoneverything.mp4 and https://video.fosdem.org/2020/AW1.125/asyncawaitnim.mp4 |
19:45:30 | FromDiscord_ | <Lantos> thanks clyybber |
19:45:35 | FromDiscord_ | <Clyybber> @mratsim You had a talk too right? |
19:45:39 | FromDiscord_ | <Clyybber> np |
19:45:44 | FromGitter | <mratsim> I did |
19:45:58 | FromGitter | <mratsim> but I guess I’m supposed to validate some stuff so that it’s published |
19:46:23 | FromDiscord_ | <Lantos> hmmm mirror is dead will have to try again leter |
19:47:15 | FromDiscord_ | <Clyybber> works for me |
19:47:16 | FromDiscord_ | <Lantos> ahh *.webm works |
19:47:18 | FromDiscord_ | <Lantos> just me |
19:58:17 | * | tane joined #nim |
19:59:44 | Araq | http://stratus3d.com/blog/2020/01/20/applying-the-let-it-crash-philosophy-outside-erlang/ |
20:01:00 | FromDiscord_ | <Lantos> nice talk dom! |
20:08:47 | * | rockcavera joined #nim |
20:09:39 | disruptek | --exceptions:teflon |
20:10:01 | disruptek | we run finally: clauses but not except: clauses. |
20:10:03 | * | jjido quit (Quit: Connection closed for inactivity) |
20:11:17 | FromDiscord_ | <Clyybber> Araq: Whats the operator precedence of `.` ? |
20:15:17 | Araq | OP6, see the manual |
20:15:41 | FromDiscord_ | <Clyybber> Araq: Yeah, I mean the method call dot |
20:15:48 | FromDiscord_ | <Clyybber> I guess its above OP10 |
20:16:05 | Araq | yes, it's part of 'primary expression' iirc |
20:16:39 | FromDiscord_ | <Clyybber> I see, What I was about to suggest is that we introduce OP11 for operators that start with `.` but not `..` ? |
20:16:44 | Araq | rule 'primarySuffix' |
20:16:52 | FromDiscord_ | <Clyybber> so that we can have the right precedence for the outplace operator |
20:17:28 | Araq | ask mratsim about it |
20:17:50 | disruptek | ^ |
20:18:00 | Araq | if you don't touch .. nor ..* it should work out fine |
20:18:06 | FromDiscord_ | <Clyybber> Nice |
20:18:10 | FromDiscord_ | <Clyybber> @mratsim ping |
20:18:42 | Araq | I think "slice like" vs "dot like" makes sense |
20:18:47 | FromDiscord_ | <Clyybber> nice |
20:18:51 | FromDiscord_ | <Clyybber> I'll make a PR |
20:19:29 | Araq | can't you take over my "scope based destructor injections" |
20:19:49 | Araq | in principle thanks to your refactoring it's rather simple, only 4 different cases |
20:20:11 | Araq | and some bail out mechanism is required for 'or' and 'elif cond' |
20:20:12 | FromDiscord_ | <Clyybber> I can, I'm kinda busy rn. but can work on big things again in 2 weeks or so |
20:20:18 | disruptek | is the cfg a separate representation of the ast or is it a logical view of same? |
20:20:26 | Araq | disruptek, separate |
20:20:39 | disruptek | kk thanks |
20:20:47 | Araq | and it's stable enough IME, usually you don't have to touch it |
20:20:47 | disruptek | so it's phase-specific? |
20:21:00 | Araq | yeah, only destructor injection uses it |
20:21:43 | disruptek | currently. 😏 |
20:25:03 | * | actuallybatman joined #nim |
20:26:24 | Zevv | mratsim: what was this list of benchmarks of various implementations you showed at the end of your talk? |
20:32:38 | FromDiscord_ | <Chiqqum_Ngbata> Araq's talk posted yet? |
20:33:59 | FromDiscord_ | <Chiqqum_Ngbata> A: Doesn't look like it |
20:34:36 | dom96 | If it's up you will see it on the event page, like you can see it on mine: https://fosdem.org/2020/schedule/event/asyncawaitnim/ |
20:34:53 | * | actuallybatman left #nim (#nim) |
20:36:51 | zedeus | I've been getting openssl double free segfaults when closing httpclients pretty often lately, obv it causes a program crash which is unfortunate. Any idea? I was hesitant to open an issue yet as it's very undeterministic |
20:36:53 | zedeus | *** Error in `./nitter': free(): invalid pointer: 0x0000561a5506f3e0 *** |
20:40:01 | Araq | zedeus, openssl update? |
20:41:39 | zedeus | it happens with latest version (1.1.1.d) and 1.1.0 |
20:41:52 | zedeus | ah here it is, doesn't always print, Error: unhandled exception: error:140E0197:SSL routines:SSL_shutdown:shutdown while in init [SslError] |
20:42:39 | zedeus | might be a separate error even, no clue. when searching for that you can find various issues in other projects, but they all seemed to fix it |
20:43:30 | zedeus | hmm https://github.com/dom96/choosenim/issues/61 |
20:43:31 | disbot | ➥ `choosenim update devel` results in "Error: unhandled exception: error: ... [SslError]" |
20:44:45 | zedeus | https://github.com/nim-lang/Nim/issues/9867#issuecomment-473902394 |
20:44:47 | disbot | ➥ Long-lived application occasionally dies with SIG_PIPE when calling httpclient.request ; snippet at 12https://play.nim-lang.org/#ix=2aMk |
20:45:22 | disruptek | zedeus: that looks like a similar issue to one that treeform struggled with. |
20:45:43 | disruptek | where did you escape to after the nim talks, anyway? missed you that evening. |
20:45:50 | shashlick | zedeus: https://github.com/nim-lang/Nim/issues/9419#issuecomment-580994111 |
20:47:03 | zedeus | disruptek: talked to mratsim for a bit then said hello to the group, I was with a friend so had to leave and catch a bus a few hours later |
20:47:25 | zedeus | I'll try to stay around longer next year |
20:48:56 | zedeus | shashlick: that looks like a different issue, this is on shutdown and only happens once every ~1k(?) requests, according endragor in the comment I linked it's when the server closes the connection first |
20:49:27 | FromDiscord_ | <Clyybber> Araq: Should I add OP11 to the operator precedence table? It doesn't currently have any operators that use it, so the operators field would be empty |
20:53:19 | Araq | let's use BearSSL instead, I'm tired of this |
20:53:44 | Araq | openssl is security by obscurity |
20:54:59 | xace | https://blog.discordapp.com/why-discord-is-switching-from-go-to-rust-a190bbca2b1f # does anyone know if nim would suffer the same consequences as Go did in this scenario? |
20:55:19 | * | Pqzcih5 quit (Remote host closed the connection) |
20:56:22 | FromDiscord_ | <Clyybber> I read it |
20:56:24 | FromDiscord_ | <Clyybber> It wouldn't |
20:56:32 | FromDiscord_ | <Recruit_main_70007> maybe it would have, but with gc:arc i think that problem is sloved if its as good as i am hearing, since it even runs no bare metal now |
20:58:13 | FromDiscord_ | <Clyybber> They are also using an old go version |
20:58:34 | xace | I see |
20:58:41 | FromDiscord_ | <Recruit_main_70007> bruh, if they are changing, why not just update lol |
20:58:54 | FromDiscord_ | <Recruit_main_70007> or use Nim :p |
21:01:40 | Araq | yeah, with --gc:arc we've become "hard realtime" capable |
21:02:15 | Araq | and narimiran is working on our secret weapon on top of that *cough* |
21:02:22 | FromDiscord_ | <Recruit_main_70007> nim 1.0.6 comes with it? |
21:02:28 | * | narimiran no pressure |
21:02:43 | FromDiscord_ | <Recruit_main_70007> at all, i will love you anyway |
21:02:58 | Araq | no, 1.0.6 is a bugfix release |
21:03:05 | Araq | we will have arc in 1.2 |
21:03:05 | FromDiscord_ | <Recruit_main_70007> :/ |
21:03:17 | Araq | still scheduled for Q1 2020 |
21:03:53 | FromDiscord_ | <Recruit_main_70007> will it make echo and things like that work on, lets say, a kernel? |
21:04:32 | Araq | yes, maybe Zevv will ask for .weak symbols first |
21:04:35 | Araq | but yes |
21:05:20 | FromDiscord_ | <Clyybber> Araq: So the last round is ./ vs .~ |
21:05:39 | FromDiscord_ | <Clyybber> I guess .~ is a bit more distinct from path operators |
21:05:39 | Araq | x.~sort() |
21:05:43 | Araq | x./sort() |
21:05:44 | FromDiscord_ | <Clyybber> yep |
21:06:03 | Araq | for me ~ is either for negation or for "ropes" |
21:06:09 | Araq | or for "approx." |
21:06:12 | FromDiscord_ | <Clyybber> yeah |
21:06:14 | FromDiscord_ | <Clyybber> alright |
21:06:29 | Araq | x|>sort |
21:06:38 | Araq | some arrow like thing could also work |
21:06:43 | narimiran | oooh, nice |
21:06:55 | Araq | lol |
21:06:56 | FromDiscord_ | <Clyybber> hmm, I guess so |
21:07:17 | narimiran | (for those new here, i really like pipes :)) |
21:07:17 | Araq | x |> insert(10) |> sort |
21:07:42 | zedeus | |> looks like separate (copy) and redirect, which is basically what outplace does |
21:07:48 | zedeus | so +1 from me |
21:07:54 | narimiran | +10 from me :D |
21:08:02 | FromDiscord_ | <Clyybber> Maybe we can combine it with a dot somehow |
21:08:20 | Araq | x .> insert(10) .> sort |
21:08:40 | FromDiscord_ | <Clyybber> Yeah, in fact I originally envisioned .< for outplace |
21:08:48 | FromDiscord_ | <Clyybber> But .> is alright too |
21:08:56 | Araq | I don't really care all that much as long as Leibniz and Newton used the same notation for their "inplace vs outplace" problems |
21:09:07 | narimiran | :D |
21:09:54 | FromDiscord_ | <Clyybber> .| could also work, but its a bit high |
21:10:13 | narimiran | does it have to use the dot? |
21:10:19 | FromDiscord_ | <Clyybber> yeah |
21:10:22 | FromDiscord_ | <Clyybber> for operator precedence |
21:10:34 | FromDiscord_ | <Clyybber> and also for mimicking UFCS |
21:10:35 | Araq | because new syntax should be reserved for the 1600ies |
21:11:10 | narimiran | foo .|> bar .|> baz ? |
21:11:21 | FromDiscord_ | <Clyybber> is a bit long |
21:11:26 | FromDiscord_ | <Clyybber> two chars would be best no? |
21:11:27 | FromDiscord_ | <exelotl> I like .> |
21:11:39 | narimiran | another case of "& is too hard to type"? :D |
21:11:46 | FromDiscord_ | <Clyybber> hehe |
21:12:02 | FromDiscord_ | <Clyybber> nah, more about the visuals |
21:12:08 | FromDiscord_ | <Clyybber> .> I like too |
21:12:27 | narimiran | "best nim meme of 2019" award definitely goes to "& is too hard to type" if you ask me :) |
21:12:31 | Araq | I like .> too, |> in F# does something different anyway |
21:12:58 | narimiran | foo .> bar .> baz |
21:13:06 | Araq | but .> introduces a new problem: spaces around it or not? |
21:13:09 | narimiran | ok, it looks ok, and it is very easy to type |
21:13:16 | narimiran | dot, shift+dot |
21:13:33 | FromDiscord_ | <Clyybber> Araq: Shouldn't matter? |
21:13:37 | FromDiscord_ | <Clyybber> But normally no spaces |
21:13:41 | FromDiscord_ | <Clyybber> for dot-like operators |
21:14:02 | FromDiscord_ | <Clyybber> I guess |
21:14:14 | Araq | foo.>insert(10).>sort() |
21:14:20 | Araq | maybe, ok |
21:15:34 | FromDiscord_ | <Clyybber> foo./insert(10)./sort() vs foo.>insert(10).>sort() vs foo.!insert(10).!sort() vs foo.|insert(10).|sort() vs foo.~insert(10).~sort() |
21:15:36 | FromDiscord_ | <Clyybber> hmm |
21:15:46 | FromDiscord_ | <Clyybber> I think .> really is the best |
21:19:04 | FromDiscord_ | <Recruit_main_70007> Error: unhandled exception: packedjson.nim(771, 9) `node.kind == JArray` |
21:19:04 | FromDiscord_ | <Recruit_main_70007> pls help. |
21:20:04 | Araq | use j[i] for json arrays |
21:20:17 | Araq | and j["foo"] for json objects |
21:20:43 | Araq | it's usually not that hard to understand, field names are not integers and indexes are not strings |
21:22:02 | * | narimiran quit (Ping timeout: 260 seconds) |
21:26:19 | FromDiscord_ | <exelotl> now that we've got all that bikeshedding out the way, I have to say say I'd rather use cascade lol |
21:26:28 | FromDiscord_ | <Recruit_main_70007> i dont know whats wrong, i have this message: |
21:26:28 | FromDiscord_ | <Recruit_main_70007> {"type":"Update", ... } |
21:26:28 | FromDiscord_ | <Recruit_main_70007> |
21:26:28 | FromDiscord_ | <Recruit_main_70007> and then: |
21:26:28 | FromDiscord_ | <Recruit_main_70007> if packet["type"].getStr() == "Update": |
21:29:14 | FromDiscord_ | <exelotl> need more info tbh, can you reduce it to a minimal example that runs in the playground? |
21:29:42 | FromDiscord_ | <Recruit_main_70007> hmm, i can give you only that function |
21:30:57 | FromDiscord_ | <Recruit_main_70007> https://play.nim-lang.org/#ix=2aMr |
21:30:57 | FromDiscord_ | <Recruit_main_70007> i gave you two just in case |
21:31:32 | FromDiscord_ | <Recruit_main_70007> broken... |
21:31:39 | FromDiscord_ | <Recruit_main_70007> wait a sec |
21:33:02 | Araq | exelotl: cool but now "your opinion is more valuable once you understood the problem" applies again :P |
21:34:00 | FromDiscord_ | <Recruit_main_70007> https://pastebin.com/0fqsv9xz |
21:37:02 | FromDiscord_ | <Clyybber> @timotheecour Are you there? |
21:37:11 | FromGitter | <timotheecour> ya |
21:37:18 | FromDiscord_ | <Clyybber> sup |
21:37:26 | FromDiscord_ | <Clyybber> in your outplace PR |
21:37:35 | FromDiscord_ | <Clyybber> you don't need to deprecated outplace |
21:37:38 | FromDiscord_ | <exelotl> in particular I think chaining outplace seems like it would be really wasteful, you're cloning the seq every time when you most likely only needed to clone it once |
21:37:44 | FromDiscord_ | <Clyybber> its `since (1, 1)` anyways |
21:37:54 | FromDiscord_ | <Clyybber> @exelotl I have an idea on how to optimize that |
21:38:52 | FromDiscord_ | <Clyybber> But its gonna be moved anyways |
21:39:21 | FromDiscord_ | <Clyybber> @timotheecour Then you can use std/outplace instead of std/outplaces as a module name |
21:39:41 | FromDiscord_ | <Clyybber> Also .> is now the operator :p |
21:39:42 | disruptek | ~& |
21:39:42 | disbot | &: 11unreachable |
21:39:48 | FromDiscord_ | <Clyybber> classic |
21:39:56 | FromDiscord_ | <exelotl> lmao |
21:40:37 | disruptek | anything with ligature is a win. 😁 |
21:46:16 | * | marmotini_ quit (Remote host closed the connection) |
21:46:19 | Zevv | oh yes, .weak symbols FTW \o/ |
21:46:51 | * | marmotini_ joined #nim |
21:46:54 | shashlick | nim compiled binaries are blocked by IT |
21:47:00 | disruptek | nice. |
21:47:14 | FromGitter | <timotheecour> > you don't need to deprecated outplace ⏎ ⏎ => https://github.com/nim-lang/Nim/pull/13309#issuecomment-581367385 (and i agree) |
21:47:15 | disbot | ➥ new outplace operator: `doAssert @[2,1,3].@sort() == @[1,2,3]` ; snippet at 12https://play.nim-lang.org/#ix=2aLi |
21:47:43 | disruptek | shashlick: time to send out resumes. |
21:48:03 | Zevv | "secret weapon" (*cough*)? |
21:48:46 | FromGitter | <timotheecour> ( i mean i agree with araq that we shouldn’t have 2 ways to do same thing; so i deprecated outplace; the operator is always more conventient for this particular feature as it avoids 1 level of nesting and is shorted) |
21:48:49 | FromGitter | <timotheecour> *shorter |
21:49:01 | FromGitter | <Clyybber> Yeah, I meant instead of deprecating it |
21:49:05 | FromGitter | <Clyybber> just remove it outright |
21:49:09 | Araq | yup |
21:49:15 | Araq | it's Nim devel |
21:49:41 | FromGitter | <Clyybber> its freedom!! |
21:50:07 | FromDiscord_ | <exelotl> {.deprecated.} is now deprecated |
21:50:57 | FromDiscord_ | <Recruit_main_70007> then add two of them |
21:50:58 | FromGitter | <timotheecour> so @araq; shall i remove sugar/outplace or keep it as deprecated |
21:51:07 | FromDiscord_ | <Clyybber> remove it |
21:51:24 | * | marmotini_ quit (Ping timeout: 265 seconds) |
21:51:37 | FromDiscord_ | <Clyybber> > it's Nim devel |
21:52:00 | FromGitter | <Clyybber> araq just seconds ago :p |
21:52:14 | FromGitter | <timotheecour> personally i like the philosophy of: whatever hasn’t been released yet (only in devel) can be removed IF (big IF) it can be easily replaced by something better; which is the case here |
21:52:22 | FromGitter | <Clyybber> yep |
21:53:00 | FromGitter | <Clyybber> I like your _ thing. Great solution! |
21:54:35 | FromGitter | <timotheecour> thx ya, was better than an index; ok will update pr with removed std/outplace, now left to do is decide bw `.^` (my favorite, see my latest PR msg) vs alternatives like (`.>` which isn’t bad either but a bit less obvious visually) |
21:55:03 | FromGitter | <Clyybber> .^ doesn't "point" to the right |
21:55:30 | FromGitter | <kaushalmodi> @timotheecour Yep, I don't see a reason to "deprecate" it.. it's only on devel |
21:55:36 | * | Vladar quit (Quit: Leaving) |
21:56:15 | FromGitter | <Clyybber> @timotheecour .> looks a bit like "inserting" something (the intermediate) into the rhs (the inplace) proc |
21:56:37 | FromGitter | <Clyybber> thats why IMO it fits just perfectly :) |
21:57:24 | * | marmotini_ joined #nim |
22:00:58 | FromGitter | <Varriount> I say keep outplace |
22:01:36 | FromGitter | <Varriount> shashlick: Windows laptop? |
22:01:38 | * | marmotini_ quit (Ping timeout: 240 seconds) |
22:01:49 | FromGitter | <Varriount> Any idea what they are using? Group policy? Fireeye? |
22:03:09 | FromGitter | <Clyybber> @Varriount Its gonna be replaced by its operator |
22:07:04 | * | greenfor` quit (Read error: Connection reset by peer) |
22:08:29 | FromDiscord_ | <exelotl> lol at school I would work around the executable restrictions by putting the exe inside zip file and double clicking on it from there |
22:08:32 | FromDiscord_ | <Rika> it will be removed no matter what |
22:08:59 | FromDiscord_ | <Rika> but which operator it gets replaced by is mainly the choice of the community |
22:10:13 | FromDiscord_ | <exelotl> system behaviour was to extract the exe to a temporary folder on the C drive, which evidently didn't have the same restrictions as the network drive |
22:10:38 | FromDiscord_ | <exelotl> it was so dumb but it worked great for self-contained programs such as putty |
22:10:43 | * | greenfor` joined #nim |
22:18:42 | * | filcuc joined #nim |
22:19:36 | * | natrys quit (Ping timeout: 265 seconds) |
22:29:17 | * | ptdel quit (Ping timeout: 265 seconds) |
22:33:16 | * | tane quit (Quit: Leaving) |
22:34:36 | * | icebattle joined #nim |
22:34:44 | FromGitter | <Varriount> exelotl: I remember doing something similar to retrieve a JAR file |
22:34:52 | FromGitter | <Varriount> But in reverse |
22:37:49 | * | marmotini_ joined #nim |
22:48:57 | FromDiscord_ | <exelotl> another funny thing was when I managed to install opera on one of the computers |
22:50:04 | FromDiscord_ | <exelotl> first I used the zip trick above to launch the installer |
22:51:23 | FromDiscord_ | <exelotl> but I got stuck at the part where it asked to choose an install directory, because some policy would cause the directory text field to be emptied immediately |
22:52:01 | FromDiscord_ | <exelotl> I worked around it by... clicking really fast |
22:52:07 | shashlick | Varriount: windows |
22:52:15 | shashlick | McAfee and defender |
22:52:30 | shashlick | Not clear what's blocking, nothing in their logs |
22:52:41 | shashlick | Even with admin access |
22:54:05 | leorize[m] | you're in for a bad time then |
22:54:07 | FromDiscord_ | <Recruit_main_70007> @exelotl it’s hilarious the number of places you can do that, I did it in eve online w/ a bad connection, I felt so intelligent that it actually worked XD |
22:54:35 | FromDiscord_ | <Recruit_main_70007> (Not installing it, but within the game) |
22:56:41 | * | skrylar quit (Quit: WeeChat 2.7) |
22:56:48 | * | solitudesf quit (Ping timeout: 268 seconds) |
22:57:05 | * | ftsf joined #nim |
22:58:48 | * | Trustable quit (Remote host closed the connection) |
23:05:41 | * | filcuc quit (Quit: Konversation terminated!) |
23:24:31 | * | Kaivo_ joined #nim |
23:24:38 | * | Kaivo_ quit (Client Quit) |
23:24:56 | * | Kaivo_ joined #nim |
23:27:32 | * | Kaivo quit (Ping timeout: 248 seconds) |
23:32:32 | * | ptdel joined #nim |
23:39:48 | * | Sembei joined #nim |
23:43:03 | * | disrupteq quit (Ping timeout: 265 seconds) |
23:43:28 | * | disrupteq joined #nim |
23:46:10 | FromGitter | <jyapayne> @timotheecour I found out how to compile libffi to a dll for Windows 32 bit and 64 bit |
23:46:32 | FromGitter | <kristianmandrup> @jyapayne :) |
23:47:09 | FromGitter | <kristianmandrup> I wish someone in the community could do an in-depth macro/templates tutorial |
23:47:38 | * | disrupteq quit (Ping timeout: 240 seconds) |
23:48:33 | FromGitter | <jyapayne> @timotheecour I followed the instructions here: https://proj.goldencode.com/projects/p2j/wiki/Building_and_Installing_libffi_on_Windows ⏎ Making sure to configure using the MSYS as suggested. But I used the tar.gz from https://github.com/libffi/libffi/releases/download/v3.3/libffi-3.3.tar.gz |
23:49:48 | * | disrupteq joined #nim |
23:50:59 | FromGitter | <jyapayne> @timotheecour also, the command to configure for 32 bit (via MSYS terminal) is: ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e3a0363f301780b836798c8] |
23:51:21 | FromDiscord_ | <Rika> kristianmandrup treeRepr is your best friend |
23:51:45 | FromGitter | <jyapayne> @timotheecour Not sure if the libs are portable or not, but I could upload them if needed |
23:52:32 | FromGitter | <jyapayne> Also @kristianmandrup Rika is right. treeRepr and toStrLit are the best way to learn |
23:58:28 | * | disrupteq quit (Ping timeout: 268 seconds) |