00:16:30 | * | Cthalupa quit (Ping timeout: 268 seconds) |
00:21:21 | * | Cthalupa joined #nim |
00:23:48 | * | gh0st[m] quit (Remote host closed the connection) |
00:23:50 | * | planetis[m] quit (Read error: Connection reset by peer) |
00:23:56 | * | Connor[m] quit (Remote host closed the connection) |
00:23:56 | * | k0mpjut0r quit (Write error: Connection reset by peer) |
00:23:56 | * | pigmej[m] quit (Write error: Broken pipe) |
00:23:58 | * | leorize[m] quit (Remote host closed the connection) |
00:23:58 | * | nergal[m] quit (Write error: Connection reset by peer) |
00:24:00 | * | meff[m] quit (Write error: Connection reset by peer) |
00:24:02 | * | narimiran[m] quit (Write error: Connection reset by peer) |
00:24:02 | * | xomachine[m] quit (Remote host closed the connection) |
00:24:03 | * | spymasterd[m] quit (Remote host closed the connection) |
00:24:06 | * | GitterIntegratio quit (Write error: Connection reset by peer) |
00:24:07 | * | Miguelngel[m] quit (Remote host closed the connection) |
00:24:07 | * | lqdev[m] quit (Remote host closed the connection) |
00:24:10 | * | disruptek o7 |
00:24:11 | * | LEdoian[m] quit (Write error: Connection reset by peer) |
00:24:12 | * | BitPuffin quit (Remote host closed the connection) |
00:24:13 | * | macsek1911[m] quit (Remote host closed the connection) |
00:24:13 | * | zielmicha[m]1 quit (Remote host closed the connection) |
00:24:13 | * | encryptize[m] quit (Remote host closed the connection) |
00:24:14 | * | TheManiac[m] quit (Read error: Connection reset by peer) |
00:24:16 | * | jaens[m] quit (Remote host closed the connection) |
00:24:16 | * | isaac[m]1 quit (Remote host closed the connection) |
00:24:16 | * | yglukhov[m] quit (Remote host closed the connection) |
00:24:17 | * | Demos[m] quit (Remote host closed the connection) |
00:24:17 | * | skrylar[m] quit (Remote host closed the connection) |
00:32:12 | * | Connor[m] joined #nim |
00:53:09 | * | Demos[m] joined #nim |
00:53:09 | * | LEdoian[m] joined #nim |
00:53:09 | * | BitPuffin joined #nim |
00:53:09 | * | k0mpjut0r joined #nim |
00:53:09 | * | isaac[m]1 joined #nim |
00:53:09 | * | GitterIntegratio joined #nim |
00:53:09 | * | planetis[m] joined #nim |
00:53:10 | * | gh0st[m] joined #nim |
00:53:10 | * | jaens[m] joined #nim |
00:53:10 | * | nergal[m] joined #nim |
00:53:10 | * | leorize[m] joined #nim |
00:53:10 | * | pigmej[m] joined #nim |
00:53:16 | * | yglukhov[m] joined #nim |
00:53:16 | * | spymasterd[m] joined #nim |
00:53:16 | * | narimiran[m] joined #nim |
00:53:16 | * | macsek1911[m] joined #nim |
00:53:16 | * | TheManiac[m] joined #nim |
00:53:17 | * | Miguelngel[m] joined #nim |
00:53:17 | * | skrylar[m] joined #nim |
00:53:17 | * | encryptize[m] joined #nim |
00:53:17 | * | meff[m] joined #nim |
00:53:18 | * | lqdev[m] joined #nim |
00:53:18 | * | xomachine[m] joined #nim |
00:53:18 | * | zielmicha[m]1 joined #nim |
01:21:45 | * | endragor joined #nim |
01:29:08 | * | endragor_ joined #nim |
01:32:08 | * | endragor quit (Ping timeout: 245 seconds) |
01:56:18 | * | endragor_ quit (Remote host closed the connection) |
02:18:17 | * | rayman22201 quit (Quit: Connection closed for inactivity) |
02:34:52 | * | actuallybatman quit (Ping timeout: 246 seconds) |
02:37:01 | * | actuallybatman joined #nim |
03:12:34 | shashlick | @mratsim this is only for custom tasks |
03:15:12 | * | fjellfras joined #nim |
03:15:38 | * | fjellfras quit (Max SendQ exceeded) |
03:16:07 | * | fjellfras joined #nim |
03:16:18 | * | fjellfras quit (Max SendQ exceeded) |
03:16:47 | * | fjellfras joined #nim |
03:17:07 | * | fjellfras quit (Max SendQ exceeded) |
03:17:30 | * | endragor joined #nim |
03:17:34 | * | fjellfras joined #nim |
03:17:54 | * | fjellfras quit (Max SendQ exceeded) |
03:24:09 | * | dddddd quit (Remote host closed the connection) |
03:25:53 | * | pbb quit (Quit: http://quassel-irc.org - Chat comfortably. Anywhere.) |
03:26:33 | * | pbb joined #nim |
03:38:49 | * | chemist69 quit (Ping timeout: 250 seconds) |
03:40:51 | * | chemist69 joined #nim |
03:50:05 | * | owl_000 quit (Ping timeout: 250 seconds) |
04:24:04 | * | alexander92 quit (Ping timeout: 246 seconds) |
04:37:41 | * | rockcavera quit (Remote host closed the connection) |
04:49:43 | * | nsf joined #nim |
05:09:40 | * | narimiran joined #nim |
05:15:21 | * | vlad1777d joined #nim |
05:17:17 | * | solitudesf joined #nim |
06:31:02 | * | PMunch joined #nim |
06:44:02 | * | krux02 joined #nim |
07:00:00 | * | gmpreussner quit (Quit: kthxbye) |
07:04:48 | * | gmpreussner joined #nim |
07:27:34 | * | Hideki_ joined #nim |
07:28:36 | * | ng0 joined #nim |
07:32:08 | Hideki_ | I placed three files: /test.nim, /model/foo.nim, /api/foo.nim. Let's assume /model/foo.nim and /api/foo.nim are empty files. I imported the two files in /test.nim like import "model/foo.nim" and import "api/foo.nim". Then, I got a compile error Error: redefinition of 'foo': previouds declaration here: ... My question is: Should I use globally unique file names in a Nim project? |
07:35:23 | * | Hideki_ quit (Remote host closed the connection) |
07:35:51 | * | Hideki_ joined #nim |
07:36:57 | solitudesf | you can do `import model/foo as foo1` or something |
07:38:02 | * | Hideki_ quit (Remote host closed the connection) |
07:38:41 | * | Hideki_ joined #nim |
07:40:33 | Hideki_ | @solitudesf Thanks. It worked. I didn't know a filename is an identifier like proc name and type name are. |
07:42:50 | * | Hideki_ quit (Remote host closed the connection) |
07:43:06 | * | Hideki_ joined #nim |
07:46:52 | * | Hideki_ quit (Remote host closed the connection) |
07:50:51 | * | Hideki_ joined #nim |
07:57:32 | * | absolutejam joined #nim |
08:05:05 | * | noonien joined #nim |
08:06:38 | noonien | hello folks! |
08:07:07 | noonien | how can i assign a string to a byte array? |
08:07:59 | narimiran | noonien: `toOpenArrayByte` ? |
08:09:43 | noonien | thanks |
08:13:59 | * | floppydh joined #nim |
08:14:55 | * | laaron quit (Quit: ZNC 1.7.1 - https://znc.in) |
08:17:04 | * | laaron joined #nim |
08:57:06 | * | Vladar joined #nim |
09:10:39 | * | ehmry joined #nim |
09:17:14 | * | skelett1 quit (Quit: WeeChat 2.4) |
09:17:40 | * | skelett joined #nim |
09:25:17 | * | absolutejam quit (Ping timeout: 244 seconds) |
09:25:25 | * | chemist69 quit (Quit: WeeChat 2.3) |
09:29:39 | * | laaron quit (Quit: ZNC 1.7.1 - https://znc.in) |
09:30:28 | * | laaron joined #nim |
09:37:12 | * | laaron quit (Quit: ZNC 1.7.1 - https://znc.in) |
09:37:33 | * | laaron joined #nim |
09:39:08 | * | absolutejam joined #nim |
10:01:32 | * | Vladar quit (Remote host closed the connection) |
10:04:59 | * | Vladar joined #nim |
10:09:34 | * | Hideki_ quit (Remote host closed the connection) |
10:19:19 | * | actuallybatman quit (Ping timeout: 246 seconds) |
10:19:34 | * | ZORR0W joined #nim |
10:27:32 | * | alexander92 joined #nim |
10:29:34 | FromGitter | <alehander42> i have |
10:29:41 | FromGitter | <alehander42> this weird error required type: Lang ⏎ but expression 'LangNim' is of type: Lang |
10:32:17 | PMunch | That does indeed look weird |
10:34:30 | alexander92 | i can workaround by changing the signature to int, and using arg.Lang in the functio |
10:34:35 | alexander92 | but it doesnt make sense to me |
10:34:52 | FromGitter | <arnetheduck> what was the reason for not going with sqlite amalgamation? it's got all kinds of reasons to use it: faster, easier to deploy, no version incompatibilities etc etc... it's literally made to be deployed this way, specially since nim already heavily relies on `C~ |
10:36:03 | alexander92 | is sqlite going to be a long-term solution? i felt it's only a temporary one |
10:36:49 | alexander92 | oh man, now i have it again with another type |
10:36:54 | alexander92 | i am doing something wrong! |
10:37:42 | FromGitter | <arnetheduck> you'll see, soon we'll have an ORM in the compiler as well :) |
10:39:10 | alexander92 | no, i remember ideas for a memory-mapped almost-no-deserialization needed format |
10:41:53 | * | Tongir joined #nim |
10:42:06 | FromGitter | <arnetheduck> regardless, that also sounds like a reason to go with the amalgamation - it's painful and causes all kinds of problems to have a separate dll, and you don't want to waste time on teaching people to deal with those problems specially if it's temporary.. |
10:42:40 | alexander92 | no, i just speculate, i dont think araq thinks it temp |
10:43:09 | Araq | I don't know, at this point I'm concerned to get the logic and algorithms right |
10:46:40 | Araq | I don't use much of sqlite though |
10:47:08 | Araq | since it's way too slow :-) |
10:48:22 | * | absolutejam quit (Ping timeout: 245 seconds) |
10:51:44 | alexander92 | exactly ; ) |
10:52:46 | FromGitter | <arnetheduck> so fwiw, even though we're probably one of the bigger nim projects out there, compile times and thus incremental compilation are quite low on our prio list, compared to correctness and other issues around tooling - library, package and module management being on the forefront of tooling and stdlib curation/quality/obsolecense on the prime spot for nim right now.. we've mostly stopped using any advanced nim compiler |
10:52:46 | FromGitter | ... features beyond 0.19.6 which is a motivating reason why we haven't made the effort to move to 0.20 as well - there' |
10:53:41 | alexander92 | is it possible that `auto` generates weird type syms |
10:54:11 | alexander92 | because when i get a "QueryNode" `query` from awaiting a `auto` await template .. it is not recognized as QueryNode |
10:54:41 | * | Hideki_ joined #nim |
10:55:28 | alexander92 | a cast works as a workaround, but it's a totally confusing error |
10:56:18 | Araq | ouch, I thought IC is feature number one |
10:56:29 | Araq | that everybody needs |
10:56:38 | Araq | or at least would benefit from |
10:57:57 | Araq | esp Status |
11:04:56 | * | absolutejam joined #nim |
11:12:58 | * | Hideki_ quit (Ping timeout: 245 seconds) |
11:18:32 | * | Tongir quit (Read error: No route to host) |
11:19:27 | FromGitter | <arnetheduck> not really - our ability to cooperate efficiently is a lot more important - between each other and with other libraries/projects really - that's why package, module and library management is such a big deal |
11:22:07 | * | Araq wispers Monorepo |
11:22:21 | FromGitter | <arnetheduck> IC is something that lends the individual developer a little convenience, but by and large it can be worked around through other means (ie buy a better PC).. |
11:24:57 | FromGitter | <arnetheduck> well yeah, monorepo solves some problems but the tooling is not ready for that either |
11:25:37 | FromGitter | <arnetheduck> and it brings others - access control / ownership of the repo to begin with |
11:28:09 | livcd | arnetheduck: what features did you stop using ? |
11:28:15 | * | absolutejam quit (Ping timeout: 244 seconds) |
11:29:16 | FromGitter | <arnetheduck> everything `--experimental`, large parts of the std lib |
11:31:00 | FromGitter | <arnetheduck> another way to look at it: there's nothing in 0.20 that we really *need* and plenty of risks like newruntime and hcr as well as real breakage |
11:32:34 | FromGitter | <alehander42> i thought they are well hidden behind flags/gates |
11:32:43 | FromGitter | <alehander42> so they shouldn't really matter if you dont use them? |
11:33:16 | FromGitter | <alehander42> i honestly guess the discussions about it take longer then actually upgrading |
11:34:24 | FromGitter | <arnetheduck> the flags/gates leak and bring complexity and bugs |
11:35:01 | FromGitter | <arnetheduck> I mean, 3-4 of our devs have tried unsucessfully to upgrade the codebase to 0.20 so I trust that it's not trivial |
11:39:08 | livcd | well good to know..if you guys are building a lot of libs that people might use it's a warning to consider |
11:40:11 | * | absolutejam joined #nim |
11:40:56 | FromGitter | <arnetheduck> mostly I think it represents churn that we're unwilling to prioritise at the moment - getting to a stable working solution to our own problems is more important |
11:41:29 | Araq | I'm looking at what it takes to build Nimbus with v1 as we speak |
11:41:34 | * | alexander92 quit (Ping timeout: 246 seconds) |
11:42:03 | livcd | hmm like chronicles-0.6.0\chronicles\topics_registry.nim(38, 5) Error: unguarded access: gActiveLogLevel |
11:43:33 | FromGitter | <arnetheduck> in general, I believe that it's better for nim itself to take the chance to cut out all obsolete stuff even if it means breakage - the sooner, the cheaper - it's really really easy to add stuff, and much harder to remove.. from status' perspective, we just don't want to follow every incremental step of that process necessarily |
11:47:05 | FromGitter | <arnetheduck> with proper package management, those kinds of decisions become easy to deal with as well - the units of breakage are smaller and come with less collateral damage |
11:47:58 | Araq | well yeah, you believe in "Proper package management", I have not found that anywhere |
11:48:36 | Araq | on this very machine if I type 'python' I'm getting 2.4.4 |
11:48:46 | Araq | stopped trying to update it |
11:49:37 | Araq | somewhere I also have the Python 2.7 that I needed |
11:50:38 | Araq | if the one OS that lacks package management has the most amount of commercial production software that doesn't break (Windows) that could tell us a lot |
11:52:04 | * | absolutejam quit (Ping timeout: 246 seconds) |
11:56:53 | * | owl_000 joined #nim |
11:59:51 | FromGitter | <arnetheduck> yes, and the banks still use cobol |
12:13:13 | * | absolutejam joined #nim |
12:17:13 | Araq | one year ago I played with Elm, its package manager told me about some incompatible version numbers, I googled the problem and made it work. Here is what happens without a PM: the Elm compiler gives me some error, I google it and can make it work. |
12:21:24 | * | Kaivo joined #nim |
12:23:22 | * | rockcavera joined #nim |
12:25:56 | owl_000 | are include and import same under the hood. i have a module contains two seperate proc. in `importer.nim` i used `from module import proc1` and use only `proc1`, in `includer.nim` `include module` and then used only proc1. i find no difference. even number of line compiled is exactly same. |
12:27:05 | PMunch | No they are not |
12:27:06 | solitudesf | include acts like literally copypasting module, so all procs types and fields are visible |
12:27:17 | Araq | https://nim-lang.org/docs/manual.html#modules-include-statement |
12:30:38 | owl_000 | i read that, i thought `from .. import ..` will import only that proc, on the other hand include will include all. but why the number of lines compiled is same. |
12:31:12 | Araq | because you don't 'include' it twice |
12:32:24 | owl_000 | let me think |
12:34:40 | owl_000 | module contains two proc, i imported only one proc in one file. in other file i included everything by include module. is it true? |
12:35:53 | owl_000 | if it is true, shouldn't i see a difference in number of lines compiled? |
12:36:51 | Araq | no, 'import' doesn't work this way, it still compiles the full module |
12:37:29 | * | vlad1777d quit (Ping timeout: 244 seconds) |
12:37:36 | narimiran | owl_000: i think the best way to see the difference between `import` and `include` is to have some not-exported proc, and to try to use it in a file where you include/import it |
12:38:47 | narimiran | and here is my rule of thumb: don't use `include` |
12:41:16 | owl_000 | the qustions arise because, after compeleting tut1, i am exploring github for nim packages. in `wnim` the compilation time is very low. i explore the source code and found that the author included everything in `wnim.nim`, i removed some of includes like `wRadioButton` and it increases compilation time. |
12:41:40 | owl_000 | --- |
12:42:25 | owl_000 | and i am testing what is the difference and found that number of compiled line is same. |
12:42:54 | owl_000 | narimiran ok i am doing it |
12:44:28 | * | Hideki_ joined #nim |
12:45:24 | * | dddddd joined #nim |
12:46:22 | owl_000 | narimiran, there is no differences in number of compiled line. i am not sure whether i followed you correctly or !. module one i remove asterisk from one proc and keep other one. |
12:47:04 | owl_000 | as Araq said it actually compiles whole module |
12:47:21 | Araq | you can remove 'include' to improve compile-times but you can also remove 'import' and would also see improved compile-times |
12:48:54 | narimiran | owl_000: from my comment "...and to try to use it..." — the difference is in the usage, not in compiled lines or time |
12:51:16 | owl_000 | `from module include proc` will include that proc and the proc and types it is using will be a good idea. |
12:52:13 | * | metadave_ joined #nim |
12:52:16 | narimiran | i had no idea that `from foo include bar` is a valid syntax |
12:52:31 | * | metadave_ quit (Client Quit) |
12:52:39 | owl_000 | it will be a good idea. not a valid syntax. lol |
12:52:44 | narimiran | ah |
12:52:58 | * | ZORR0W quit (Ping timeout: 246 seconds) |
12:56:43 | * | laaron quit (Remote host closed the connection) |
12:59:31 | * | sacredfrog joined #nim |
12:59:43 | * | chemist69 joined #nim |
13:00:44 | * | nsf quit (Quit: WeeChat 2.5) |
13:04:06 | * | endragor quit (Remote host closed the connection) |
13:06:42 | * | laaron joined #nim |
13:13:39 | * | absolutejam quit (Ping timeout: 244 seconds) |
13:27:22 | FromGitter | <awr1> i guess its kinda unfortunate that the import+import fully qualified syntax in nim are the other way around from python |
13:28:11 | narimiran | ah, that again. https://narimiran.github.io/2019/07/01/nim-import.html |
13:28:16 | Araq | oh not this again. |
13:28:26 | Araq | a module in Nim is a class in Python. |
13:29:27 | * | rockcavera quit (Remote host closed the connection) |
13:29:47 | * | rockcavera joined #nim |
13:32:42 | FromGitter | <awr1> well i know the reason nim did this was to discourage people from doing fully-qualified imports everywhere |
13:33:18 | Araq | no, the reason was we don't have 'class' |
13:33:28 | FromGitter | <awr1> hm. |
13:33:36 | Araq | and lacking classes is still hip, so ... *shrug* |
13:35:36 | FromGitter | <awr1> i mean you are right, i get the feeling if that nim encouraged OOP more i think much less people would be interested in it |
13:37:21 | FromGitter | <awr1> myself probably included |
13:37:57 | FromGitter | <awr1> (or maybe excluded? i don't know what the proper phrasing would be) |
13:38:29 | lqdev[m] | although it's minimal, the OOP paradigm used in Nim is sufficient for 99% cases. you really don't need much more than that |
13:39:27 | FromGitter | <awr1> yeah i agree |
13:39:56 | FromGitter | <awr1> in other languages OOP mentality is just forced into things that don't need it |
13:40:27 | FromGitter | <awr1> and of course, in java/C#/etc you have no choice anyway |
13:43:36 | * | absolutejam joined #nim |
13:53:36 | PMunch | Hmm, is it just me or is the parseUri procedure in the uri module not doing what it should |
13:54:33 | PMunch | Looking at this: en.wikipedia.org/wiki/File_URI_scheme it seems like a Windows path like "file:///C:/Users/moigagoo/Projects/norm/src/norm.nim" should be an empty hostname and the path C:/Users/moigagoo/Projects/norm/src/norm.nim |
13:55:06 | PMunch | But it has a leading slash on it like this: /C:/Users/moigagoo/Projects/norm/src/norm.nim |
13:55:59 | PMunch | Same for paths on Linux, paths given this way aren't actually supposed to have a leading /, they are supposed to be relative to the host, and in the case that hostname is "" then that means relative to the local file system. |
13:56:55 | Cadey | dom96: how would I define nim routers in separate modules? |
13:58:50 | Cadey | jester* |
13:58:56 | Cadey | i can't seem to figure it out |
13:59:17 | PMunch | router myrouter: <your route> |
13:59:21 | PMunch | export myrouter |
13:59:25 | PMunch | I think that might work |
14:00:43 | Cadey | nope |
14:00:52 | * | laaron quit (Remote host closed the connection) |
14:01:43 | PMunch | Works for me.. |
14:02:02 | PMunch | http://ix.io/1Ua3/ |
14:02:30 | Cadey | ah, i'm using the routes macro for my main router |
14:02:44 | PMunch | Running "nim c -r jestertest 5000" |
14:02:58 | * | laaron joined #nim |
14:03:34 | PMunch | Then you'd probably have to use this: https://github.com/dom96/jester#manual-routing |
14:04:34 | Cadey | i'll just change it over to routers :) |
14:05:35 | PMunch | Yeah, but how do you use two routers together? |
14:06:20 | PMunch | Ah, with extend: https://github.com/dom96/jester/blob/master/tests/alltest.nim#L29-L32 |
14:06:29 | PMunch | That should probably me mentioned somewhere.. |
14:09:02 | PMunch | This works, and uses the routes macro for the main route: http://ix.io/1Ua6/ |
14:09:05 | PMunch | Cadey ^ |
14:09:12 | Cadey | okay, i'll take a look |
14:09:51 | * | PMunch quit (Remote host closed the connection) |
14:13:52 | * | absolutejam quit (Ping timeout: 264 seconds) |
14:15:15 | * | absolutejam joined #nim |
14:31:49 | * | krux02 quit (Remote host closed the connection) |
14:45:07 | owl_000 | simple question when will we get nim lang v 1.0 |
14:45:43 | Zevv | "soon" |
14:48:23 | * | absolutejam quit (Ping timeout: 245 seconds) |
14:49:40 | disruptek | status can't afford to upgrade from 0.19.6 to 0.20.0 and future design changes are already difficult... i'd say nim has already passed 1.0. |
14:50:15 | Araq | http://lists.llvm.org/pipermail/llvm-dev/2016-October/106291.html interesting read |
14:50:35 | Araq | looks like tracing GC wins for LLVM too, just like it does for the Nim compiler |
14:51:22 | Araq | owl_000: fwiw https://github.com/nim-lang/Nim/milestone/2 |
14:52:44 | disruptek | that llvm thread is pretty funny. |
14:52:52 | Araq | why? |
14:52:56 | owl_000 | greeeat :O |
14:53:19 | disruptek | i love the idea that we throw out machinery. |
14:53:40 | Araq | no, what's funny about the LLVM thread? |
14:53:50 | * | absolutejam joined #nim |
14:54:23 | disruptek | the load of alloc bs. |
14:56:08 | Araq | compilers eat RAM |
14:57:41 | disruptek | i doubt the ram it ate changed to the downside. |
15:03:35 | * | ng0 quit (Remote host closed the connection) |
15:04:40 | * | ng0 joined #nim |
15:08:46 | * | absolutejam quit (Ping timeout: 246 seconds) |
15:11:57 | * | Hideki_ quit (Remote host closed the connection) |
15:16:59 | * | laaron quit (Remote host closed the connection) |
15:19:52 | * | laaron joined #nim |
15:23:13 | * | laaron quit (Client Quit) |
15:23:35 | * | laaron joined #nim |
15:26:58 | euantor | The above code results in `Mode: 511`, which is a little different to the commented `777` from https://github.com/nim-lang/Nim/blob/devel/tests/async/tioselectors.nim#L324 - shall I open an issue? https://www.irccloud.com/pastebin/DvRsYQnK/ |
15:27:01 | * | tiorock joined #nim |
15:27:01 | * | rockcavera is now known as Guest15382 |
15:27:01 | * | tiorock is now known as rockcavera |
15:27:01 | * | rockcavera quit (Changing host) |
15:27:01 | * | rockcavera joined #nim |
15:28:37 | Araq | euantor: just create a PR that removes the comment |
15:29:28 | euantor | Araq: CHMOD 511 results in `Error: unhandled exception: value out of range: 511 [RangeError]` on openBSD, so there's another issue with that block of code in that case |
15:29:32 | * | Guest15382 quit (Ping timeout: 244 seconds) |
15:31:57 | euantor | Shall I instead just pass `777` to match the comment |
15:39:27 | euantor | PR created, hopefully CI passes: https://github.com/nim-lang/Nim/pull/12120 |
15:48:40 | * | adeohluwa joined #nim |
15:54:27 | * | Trustable joined #nim |
15:56:51 | * | floppydh quit (Quit: WeeChat 2.5) |
15:59:12 | * | actuallybatman joined #nim |
16:00:44 | * | laaron quit (Quit: ZNC 1.7.1 - https://znc.in) |
16:03:08 | * | laaron joined #nim |
16:19:53 | * | Hideki_ joined #nim |
16:20:05 | * | Hideki_ quit (Remote host closed the connection) |
16:27:51 | * | adeohluwa quit (Remote host closed the connection) |
16:32:25 | * | adeohluwa joined #nim |
16:42:04 | * | matlock joined #nim |
16:43:58 | * | adeohluwa quit (Ping timeout: 246 seconds) |
17:02:00 | * | adeohluwa joined #nim |
17:19:16 | * | adeohluwa quit (Ping timeout: 264 seconds) |
17:34:17 | * | owl_000 quit (Ping timeout: 250 seconds) |
17:34:18 | * | metadave_ joined #nim |
17:43:29 | * | wildtrees joined #nim |
18:20:22 | * | nsf joined #nim |
18:29:23 | * | Trustable quit (Remote host closed the connection) |
18:30:01 | * | absolutejam joined #nim |
18:30:57 | * | krux02 joined #nim |
18:31:50 | Zevv | bwah, I was hoping hat execShellCmd("nimble install ...") would work in the playground :) |
18:54:28 | * | solitudesf- joined #nim |
18:56:43 | * | solitudesf quit (Ping timeout: 244 seconds) |
19:08:56 | * | ofelas quit (Remote host closed the connection) |
19:08:59 | * | drewr joined #nim |
19:28:14 | * | Tyresc joined #nim |
19:33:22 | * | Tyresc quit (Ping timeout: 245 seconds) |
19:33:40 | * | juturnas joined #nim |
19:34:49 | juturnas | What is the correct syntax for / is it possible to have a function pointer in a tuple or object? I've tried variations of `score: ((string) -> float)` with no success |
19:36:53 | solitudesf- | score: proc(s: string): float |
19:37:47 | solitudesf- | for arrow notation there is https://nim-lang.github.io/Nim/sugar.html#-%3E.m%2Cuntyped%2Cuntyped |
19:38:39 | juturnas | Awesome, thank you solitudesf- |
19:40:59 | * | metadave_ quit (Quit: Connection closed for inactivity) |
19:42:27 | * | Ven`` joined #nim |
19:45:17 | Cadey | I have a non-ref Snake, how do I convert it to a ref Snake? |
19:47:31 | * | Ven`` quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
19:48:57 | narimiran | Cadey: RefSnake = ref Snake ? |
19:55:24 | solitudesf- | proc toRef[T](a: T): ref T = |
19:55:25 | solitudesf- | new result |
19:55:25 | solitudesf- | copyMem addr result[], unsafeAddr a, sizeof T |
19:55:35 | solitudesf- | this works, but i dont know if thats completely retarded |
19:57:08 | Cadey | i figured out a workaround, i just marked the entire Snake type as a ref object |
20:04:12 | * | narimiran quit (Ping timeout: 245 seconds) |
20:10:00 | Araq | don't use copyMem for this |
20:10:01 | Araq | use |
20:10:06 | Araq | result[] = a |
20:10:12 | * | alexander92 joined #nim |
20:12:07 | alexander92 | Cadey, did you find out |
20:12:10 | alexander92 | the route thing |
20:12:28 | solitudesf- | ah, thats nice |
20:13:05 | alexander92 | hm, after all what does `auto` do |
20:13:10 | alexander92 | in template return-s |
20:18:44 | FromGitter | <awr1> infers the return type |
20:18:52 | juturnas | `applyInterpreter' is not GC-safe as it performs an indirect call here` <- I wasn't expecting that. Is the problem simply that I'm doing dynamic dispatch in the non-main thread? |
20:23:27 | alexander92 | awr1 ok |
20:23:29 | alexander92 | thanks! |
20:23:52 | alexander92 | but the problem i see is that i dont understand where does it resolve it |
20:23:55 | alexander92 | on the callsite |
20:23:59 | alexander92 | or in the expansion |
20:24:14 | alexander92 | because i get some expected Lang but got Lang |
20:24:17 | alexander92 | errors as a result |
20:24:53 | FromGitter | <awr1> so in templates you don't get `return` or `result` like procs, you only implicit returns. so return type is inferred from the implicit return |
20:25:10 | FromGitter | <awr1> *only get |
20:25:37 | FromGitter | <awr1> because templates are essentially a "stronger form" of copy pasting |
20:26:11 | FromGitter | <awr1> i would assume they are inferred at expansion? i think? |
20:30:15 | * | nsf quit (Quit: WeeChat 2.5) |
20:36:04 | alexander92 | yes, exactly |
20:36:22 | alexander92 | but that's what i wonder, why do i actually need to specify auto instead of untyped |
20:36:35 | alexander92 | because, they get expanded anyway |
20:36:59 | alexander92 | does it skip re-semchecking the expansion? |
20:37:28 | alexander92 | because when i do that, the resulting type is just not the same as the "same" type in the callsite |
20:44:24 | * | Ven`` joined #nim |
20:49:55 | * | Vladar quit (Remote host closed the connection) |
20:53:51 | juturnas | I've resolved the `is not GC-safe as it performs an indirect call here` error by marking the function that is called indirectly with the `{.gcsafe.}` pragma. Is that pragma checked by the compiler, or am I setting myself up for some strange GC bugs down the road? |
20:54:53 | Araq | unless you use the ugly '{.gcsafe.}:' block (note the colon), it's all checked |
20:55:23 | juturnas | Araq great, thanks |
21:03:19 | FromGitter | <awr1> so `untyped` may actually kind of be the same thing as `auto` |
21:03:21 | FromGitter | <awr1> https://play.nim-lang.org/#ix=1UbW |
21:03:42 | FromGitter | <awr1> for templates |
21:09:37 | * | juturnas quit (Remote host closed the connection) |
21:09:56 | * | juturnas joined #nim |
21:20:46 | * | cyraxjoe quit (Quit: I'm out!) |
21:29:31 | * | Ven`` quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
21:41:28 | * | solitudesf- quit (Ping timeout: 246 seconds) |
22:12:57 | * | zedeus quit (Ping timeout: 245 seconds) |
22:13:17 | * | zedeus joined #nim |
22:32:50 | FromGitter | <brentp> other than iteration, is there a way to get the 2nd most frequently seen key from a CountTable? |
22:36:54 | FromGitter | <brentp> hmm. i didn't realize that `largest` does a full scan: https://github.com/nim-lang/Nim/blob/devel/lib/pure/collections/tables.nim#L2278-L2288 |
22:43:03 | FromGitter | <awr1> you implicitly need iteration |
22:43:25 | * | laaron- joined #nim |
22:43:29 | * | laaron quit (Remote host closed the connection) |
22:44:55 | FromGitter | <awr1> the stdlib `tables` module is missing some things i think would be useful |
22:44:59 | FromGitter | <awr1> e.g. bimaps |
22:49:59 | * | dddddd quit (Remote host closed the connection) |
23:00:50 | shashlick | @brentp - can we close https://github.com/nim-lang/nimble/issues/696 |
23:06:16 | * | absolutejam quit (Ping timeout: 244 seconds) |
23:10:20 | * | absolutejam joined #nim |
23:21:34 | FromGitter | <brentp> @shashlick, it's still broken for me. I have to manually install nimble after updating nim. |
23:22:30 | FromGitter | <brentp> i'll run `git pull`, `sh build_all.sh` now and see if it's still a problem |
23:27:24 | FromGitter | <mratsim> `tables` modules is missing a BTree-backed SortedTable |
23:27:36 | * | absolutejam1 joined #nim |
23:27:58 | FromGitter | <mratsim> Araq has promised a BTree implementation in the stdlib for months :p |
23:29:41 | * | absolutejam quit (Ping timeout: 258 seconds) |
23:33:45 | * | krux02 quit (Remote host closed the connection) |
23:49:23 | * | ng0 quit (Quit: Alexa, when is the end of world?) |
23:52:45 | * | cyraxjoe joined #nim |
23:53:03 | * | jken quit (Disconnected by services) |
23:53:50 | * | jken_ joined #nim |
23:59:09 | * | jken_ is now known as jken |