00:10:14 | * | stefanos82 quit (Quit: Quitting for now...) |
00:15:03 | * | krux02 quit (Remote host closed the connection) |
00:24:42 | * | skrylar joined #nim |
00:40:43 | AlexMax | wow, turns out the problem was mine |
00:40:51 | AlexMax | I had forgotten to set up the vertex program offsets |
00:41:54 | AlexMax | https://puu.sh/BwJzY/d6e2f6a2d4.png |
00:41:58 | AlexMax | Got em! |
00:42:05 | AlexMax | Rendered with Nim |
00:42:18 | AlexMax | (it also crashes, need to figure out why...) |
00:43:20 | FromGitter | <zetashift> @AlexMax nicely done! |
00:43:44 | AlexMax | (also need to convert over all the optional widgets) |
00:44:04 | * | ASEV18 joined #nim |
00:48:55 | * | ASEV18 quit (Remote host closed the connection) |
00:56:28 | * | skrylar quit (Quit: http://quassel-irc.org - Chat comfortably. Anywhere.) |
00:59:43 | AlexMax | hrm, what the fuck happened to steam |
00:59:58 | AlexMax | used to be you could copy some gcf files from windows to linux and save on the download |
01:00:08 | AlexMax | now I can't find those files anywhere |
01:01:04 | FromGitter | <zetashift> Didn't they get replaced with vpk's? |
01:01:14 | AlexMax | oh wow I'm in the wrong channel |
01:01:21 | AlexMax | sorry about that |
01:02:09 | FromGitter | <zetashift> haha p |
01:02:10 | FromGitter | <zetashift> np |
01:02:22 | AlexMax | anyway, booted into linux because running the demo app under gdb in windows causes....something...to go nuts |
01:04:03 | * | ritchie_ quit (Ping timeout: 244 seconds) |
01:15:37 | * | ritchie_ joined #nim |
01:39:54 | * | Sabaku3 joined #nim |
01:40:32 | * | Sabaku3 quit (Remote host closed the connection) |
01:55:24 | * | noonien quit (Quit: Connection closed for inactivity) |
02:32:43 | * | dddddd quit (Remote host closed the connection) |
03:07:40 | shashlick | @AlexMax: looks like you are making good progress |
03:11:25 | shashlick | any reason why you couldn't use a single generic regex to do the `struct nk_*` replacement? |
03:11:38 | AlexMax | I didn't want to do one too many |
03:11:47 | AlexMax | Anyway, the demo app now works perfectly |
03:12:28 | AlexMax | well, there's more demo stuff to port |
03:12:57 | AlexMax | shashlick: How wbout adding arbitrary code to the nim file? |
03:13:18 | AlexMax | can i put some stuff into a file and then have it combined or included in the resulting nim file? |
03:13:31 | AlexMax | I have an iterator replacement for nk_draw_foreach |
03:13:36 | shashlick | ya you can do a prepend/append |
03:13:57 | shashlick | or use execute perhaps |
03:15:30 | shashlick | we need to reduce the number of search/replace eventually since it gets more delicate, that's why I was asking about the struct |
03:15:44 | shashlick | anyway, create a PR when you are satisfied and i'll merge |
03:37:49 | * | din23 joined #nim |
03:38:35 | * | din23 quit (Remote host closed the connection) |
03:45:45 | * | xet7 joined #nim |
03:48:46 | * | xet7 quit (Remote host closed the connection) |
04:48:49 | * | miran joined #nim |
04:52:33 | * | zachcarter quit (Ping timeout: 245 seconds) |
05:30:29 | * | nsf joined #nim |
05:40:16 | * | erratic quit (Ping timeout: 252 seconds) |
06:07:25 | * | rauss joined #nim |
06:14:07 | * | miran quit (Ping timeout: 240 seconds) |
06:16:12 | FromGitter | <alehander42> @Araq is it impossible to write |
06:16:17 | * | rauss quit (Quit: WeeChat 2.2) |
06:16:23 | FromGitter | <alehander42> ```macro: ⏎ "ewre" ⏎ .. ⏎ ``` [https://gitter.im/nim-lang/Nim?at=5ba098361ee2ca650231b4ff] |
06:16:32 | FromGitter | <alehander42> it seems nim always complains about discarding |
06:17:49 | FromGitter | <alehander42> ugh |
06:18:07 | FromGitter | <alehander42> it's because of name clashing, nvm |
06:19:09 | * | rauss joined #nim |
06:19:54 | FromGitter | <alehander42> so the issue is that i wanted to have a write macro |
06:20:00 | FromGitter | <alehander42> but it clashes with system |
06:20:24 | FromGitter | <alehander42> probably with the one with varargs, because all others have 2 args |
06:24:00 | FromGitter | <alehander42> i'll just rename it |
06:31:16 | FromGitter | <alehander42> how do you pass args to https://github.com/nim-lang/Nim/blob/master/lib/core/macros.nim#L396 |
06:31:34 | FromGitter | <alehander42> i mean `quote do: .. ` I can't possibly add an argument after the `do` |
06:31:48 | FromGitter | <alehander42> so I guess I should add it like `quote("@@") do: ` |
06:31:52 | FromGitter | <alehander42> but it doesn't seem to work |
06:38:11 | * | rauss quit (Quit: WeeChat 2.2) |
06:47:10 | * | mcc quit (Quit: Connection closed for inactivity) |
07:36:57 | * | smt_ quit (Ping timeout: 252 seconds) |
07:36:58 | * | smt joined #nim |
07:48:51 | * | Vladar joined #nim |
07:49:01 | * | heishabi joined #nim |
07:55:19 | * | heishabi quit (Ping timeout: 244 seconds) |
08:00:03 | * | leorize quit (Quit: WeeChat 2.2) |
08:01:12 | * | PMunch joined #nim |
08:03:30 | * | gmpreussner_ quit (Quit: kthxbye) |
08:03:45 | * | gmpreussner joined #nim |
08:10:12 | * | floppydh joined #nim |
08:15:04 | * | Jesin quit (Ping timeout: 240 seconds) |
08:16:07 | * | Jesin joined #nim |
08:19:10 | * | philippirrip27 joined #nim |
08:21:57 | * | philippirrip27 quit (Remote host closed the connection) |
08:50:44 | * | zachcarter joined #nim |
09:23:24 | * | c15ade4 quit (Quit: WeeChat 2.0) |
09:27:34 | * | stiell11 joined #nim |
09:28:04 | FromGitter | <codenoid> morning ✨ |
09:30:24 | * | stiell11 quit (Remote host closed the connection) |
09:37:16 | * | navin joined #nim |
09:39:08 | * | leorize joined #nim |
09:41:22 | * | kapil___ joined #nim |
09:48:12 | * | dddddd joined #nim |
10:11:43 | * | erratic joined #nim |
10:13:01 | * | PMunch quit (Ping timeout: 246 seconds) |
10:23:56 | * | Fluor27 joined #nim |
10:24:35 | * | Fluor27 quit (Remote host closed the connection) |
10:31:46 | * | PMunch joined #nim |
10:37:46 | * | TheLemonMan joined #nim |
10:39:27 | * | problame_ joined #nim |
10:40:01 | * | erratic quit (Ping timeout: 252 seconds) |
10:42:24 | * | problame_ quit (Remote host closed the connection) |
10:43:26 | * | dograt6 joined #nim |
10:45:04 | * | erratic joined #nim |
10:45:23 | * | dograt6 quit (Killed (TheMaster (Spam is not permitted on freenode.))) |
10:48:54 | * | PMunch quit (Ping timeout: 252 seconds) |
10:49:53 | * | PMunch joined #nim |
10:52:56 | * | navin quit (Remote host closed the connection) |
10:57:22 | * | navin joined #nim |
10:59:42 | * | zachcarter quit (Ping timeout: 272 seconds) |
11:18:39 | * | stefanos82 joined #nim |
11:20:54 | * | TheLemonMan quit (Quit: "It's now safe to turn off your computer.") |
11:21:48 | * | Linuxpower joined #nim |
11:24:26 | * | Linuxpower quit (Remote host closed the connection) |
11:25:53 | * | sn0w17 joined #nim |
11:26:07 | * | seni joined #nim |
11:28:44 | * | sn0w17 quit (Remote host closed the connection) |
11:32:51 | * | navin quit (Remote host closed the connection) |
11:33:15 | * | navin joined #nim |
11:33:29 | stefanos82 | hey dom96. Last night I tried to play a bit with jester and had a problem with httpbeast; it was version 0.4.0 and realized it was problematic due to "string not supporting null" changes. I then checked for updates and indeed version 0.4.1 was available. I installed it and my example worked as expected. My question is: how can I uninstall 0.4.0 without breaking jester? It would not let me and had to remove jester first, then the two |
11:33:29 | stefanos82 | httpbeast versions |
11:33:45 | * | noonien joined #nim |
11:41:00 | * | cfillion joined #nim |
11:41:41 | * | navin1 joined #nim |
11:45:05 | * | cfillion quit (Remote host closed the connection) |
11:57:07 | * | SenasOzys quit (Ping timeout: 244 seconds) |
12:13:23 | Araq | stefanos82: just remove $nimbleDir/pkgs/whatever |
12:13:40 | stefanos82 | Araq: from where, nimble file? |
12:13:49 | Araq | via 'rm' or del, depending on your OS |
12:13:51 | stefanos82 | oh you mean the directory |
12:13:56 | Araq | yeah |
12:14:25 | stefanos82 | does nimble follows the stack concept? |
12:17:52 | * | dddddd quit (Ping timeout: 250 seconds) |
12:22:40 | * | erratic quit (Ping timeout: 272 seconds) |
12:24:23 | * | dddddd joined #nim |
12:26:50 | FromGitter | <alehander42> ah this macro vs defined proc thing is killing me |
12:27:00 | FromGitter | <alehander42> new rename :D |
12:33:53 | * | navin quit (Remote host closed the connection) |
12:37:39 | * | navin joined #nim |
12:45:17 | Araq | stefanos82: what's a stack concept? |
12:45:28 | stefanos82 | LIFO packaging? |
12:45:45 | stefanos82 | it would not allow uninstall 0.4.0 unless I uninstall 0.4.1 first |
12:46:23 | Araq | no idea, I dislike all package managers |
12:46:46 | stefanos82 | typical Araq as usual :D hahahaha that's why I love you brother! ^_^ |
12:46:55 | FromGitter | <alehander42> why is `{.base.}` required everywhere |
12:47:16 | FromGitter | <alehander42> haha |
12:53:47 | Araq | base methods have to be annotated with .base |
13:11:35 | * | navin quit (Remote host closed the connection) |
13:12:02 | * | navin joined #nim |
13:12:58 | * | SenasOzys joined #nim |
13:15:33 | FromGitter | <alehander42> yeah, but I wondered why |
13:15:51 | FromGitter | <alehander42> it seems to me nim can recognize that a method is base one |
13:16:01 | FromGitter | <alehander42> (given it can give me a warning about it) |
13:16:15 | FromGitter | <alehander42> are methods without base not overriden ? |
13:25:11 | FromGitter | <mratsim> no |
13:25:17 | FromGitter | <mratsim> it just raises a warning |
13:34:53 | * | nsf quit (Quit: WeeChat 2.2) |
13:35:51 | * | Pisuke joined #nim |
13:36:46 | * | MyMind quit (Ping timeout: 272 seconds) |
13:39:12 | FromGitter | <Bennyelg> @narimiran |
13:41:46 | * | TheLemonMan joined #nim |
13:43:31 | Araq | thanks for reminding me, we need yet another RFC |
13:43:39 | Araq | "turn multi methods into single methods" |
13:45:59 | TheLemonMan | ng0, have you seen http://zbar.sourceforge.net/api/zbar_8h.html ? |
13:51:16 | FromGitter | <Bennyelg> How to get last key from the OrderedTable |
13:58:15 | * | navin quit (Remote host closed the connection) |
13:58:46 | TheLemonMan | Araq, the type checker doesn't catch the error node because tyProxy has this comment near its definition "as an errornous node should match everything" |
13:59:03 | TheLemonMan | and git blame tells me you wrote that (back in 2012) |
13:59:06 | Araq | yeah I know |
13:59:44 | Araq | the question is now: what code path uses errorNode() without also emitting an error |
14:02:07 | * | navin1 quit (Ping timeout: 240 seconds) |
14:02:20 | TheLemonMan | the ones that hope(d) an error was already emitted by the time they're executed |
14:03:07 | TheLemonMan | whether that's right or wrong is up for debate |
14:05:22 | * | navin1 joined #nim |
14:06:10 | Araq | well put writeStackTrace() in there, run 'koch temp' and looks for where these come from? |
14:09:31 | * | navin1 quit (Client Quit) |
14:12:14 | FromGitter | <narimiran> yes @Bennyelg ? |
14:12:33 | FromGitter | <narimiran> oh, now i see pm :) |
14:14:08 | TheLemonMan | Araq, semExprWithType -> semExpr, as I told you in the ticket thats where the error type is produced |
14:15:27 | FromGitter | <Quelklef> Do macros work with UFCS? ala `value.macro(argument)` |
14:15:33 | TheLemonMan | what do you think about raising an error when efWantValue is required? |
14:15:34 | FromGitter | <Quelklef> Seems to be no, but I'd expect it to work |
14:16:20 | FromGitter | <arnetheduck> periodical reminder that nim ranges make little sense, being closed: https://www.cs.utexas.edu/users/EWD/transcriptions/EWD08xx/EWD831.html - half-open ranges pre-1.0, ftw - (@tersec reminded me of this dijkstra gem) |
14:16:48 | FromGitter | <Quelklef> @arnetheduck I've read that post, I come from Python, and I prefer Nim ranges |
14:16:53 | FromGitter | <Quelklef> /shrug |
14:18:46 | Araq | arnetheduck, has been "debunked" by me, summary of it: half open ranges only work when you have a sentinel that is not part of the range |
14:19:01 | Araq | and that's not true for enums, 'char', bool, integers, ... |
14:19:35 | Araq | Dijkstra was completely wrong here. |
14:20:20 | FromGitter | <arnetheduck> doesn't alter the fact that they're easier to work with, from a mathematical point of view - ie on a continuum, you can't readily express two ranges that meet with closed ranges |
14:20:39 | Araq | they are only "easier" to work with when you |
14:20:44 | Araq | a) start from 0, not from 1. |
14:20:48 | Araq | b) never count backwards. |
14:20:52 | FromGitter | <Quelklef> Funny that Nim ranges are discrete rather than continuous @arnetheduck |
14:25:08 | PMunch | Quelklef, macros works with UFCS |
14:25:59 | Araq | TheLemonMan: ok, so why does semExpr return nil/empty without producing an error message? |
14:26:28 | FromGitter | <Quelklef> @PMunch hmmmm, something's fishy then. Lemme make a minimal example |
14:26:37 | FromGitter | <arnetheduck> @Quelklef imagine for a second draw two ranges that meet, even discreet ones - what's the "natural" way of drawing that? do the ends meet on the intersection line or not? |
14:26:38 | TheLemonMan | Araq, because it gets a nkEmpty node |
14:27:12 | FromGitter | <Quelklef> @arnetheduck Your argument is grounded in abstraction and while I agree with it I have found that actually, really, pragmatically, closed ranges are nicer to use simply because they tend to require less conginition to work with |
14:27:22 | FromGitter | <Quelklef> They're more intuitive, if perhaps abstractly less elegant |
14:29:59 | FromGitter | <Quelklef> @PMuch, what's up with this: https://pastebin.com/raw/LG2U2Eif |
14:30:08 | FromGitter | <Quelklef> Intended behavior |
14:30:27 | Araq | TheLemonMan: it "gets" it from? |
14:30:52 | FromGitter | <Quelklef> "Intended behavior?"* |
14:30:53 | TheLemonMan | Araq, the lovely macro |
14:31:34 | Araq | what happens when we patch semExprWithType to produce an error? |
14:32:33 | PMunch | @Quelklef, ah yes. That is a strange case |
14:33:01 | FromGitter | <Quelklef> I realized this isn't an actual problem for my use case, but seems odd. Bug? Should I open an issue? |
14:33:11 | FromGitter | <arnetheduck> @Quelklef granted - I guess that also depends a little on what kind of code you typically end up working with. |
14:33:18 | Araq | they are also utterly broken since you cannot iterate over every integer with them |
14:33:44 | PMunch | Ask Araq, I've seen it before and I think someone explained why it does that once, but I've forgotten if it's indented or not |
14:33:55 | FromGitter | <Quelklef> @arnetheduck Correct, it depends on the use case, as is the case with all language design |
14:34:35 | FromGitter | <Quelklef> Araq, https://pastebin.com/raw/LG2U2Eif: intended behavior? Or should I open a GitHub bug? |
14:34:57 | * | PMunch quit (Quit: Leaving) |
14:35:39 | Araq | documented behaviour, to resolve a dot-call, the compiler cannot with undeclared identifiers |
14:36:35 | FromGitter | <Quelklef> Because it can be function call or attribute lookup? Either way, got it; thanks. |
14:39:19 | FromGitter | <arnetheduck> @Quelklef and it's not so much abstraction, but rather visualization - ie how would two ranges that meet be drawn? if I count from 0, how do I get 1 element exactly (ie if I were to cover 1 element on a number line, would that be a line from 0 to 1 or a dot on 0?) it's this visualization that I want to capture in my code most often |
14:41:19 | Araq | I don't draw lines when programming, I know I can do countup(a, b) and reverse it with countdown(b, a) (symmetry!) and the number elements is b - a + 1 |
14:41:34 | FromGitter | <Quelklef> With discrete values, "covering one element" is indistinguishable from a dot. I think your visualization applies well to continuous concepts and poorly to discrete concepts, and most of the time ranges are going to be used in a discrete context. |
14:42:41 | FromGitter | <Quelklef> Araq's countdown example is what solidified, to me, that closed ranges are better; using open ranges, counting down from N to 0, inclusive, looks like: `[N, -1)` (in Python, `range(N, -1, -1)`, which is super ugly IMO. |
14:42:48 | Araq | but "intuitive" behaviour aside, half open ranges are strictly less expressive than inclusive ones and that seals the deal. |
14:47:18 | TheLemonMan | Araq, the only test that "breaks" is texplain due to the new error being emitted |
14:49:10 | Araq | and don't let me get started on how these "intuitive" half open ranges produce a clusterfuck of the C spec. so a[N] is an address distinguishable from any other address (and must exist) derived from a but it cannot be dereferenced. That's not elegant, that's patching a broken design. |
14:49:11 | copygirl | What the..? Why do Options don't have a `or` or `else` proc? |
14:49:39 | FromGitter | <Quelklef> copygirl, IIRC they're currently under development but there's some discussion surrounding them. |
14:50:04 | copygirl | Oh..? Is it on the issue tracker? I'll take a look. |
14:51:54 | FromGitter | <mratsim> @copygirl, it’s a can of worms |
14:53:18 | FromGitter | <mratsim> see here: https://github.com/nim-lang/Nim/pull/8358 |
15:03:12 | * | miran joined #nim |
15:13:51 | Araq | TheLemonMan: that's fine then |
15:14:04 | copygirl | Mhh I really did enjoy Maybe types (was it?) in Rust, so.. I'm looking forward to this being resolved. It's a powerful and neat little thing you can use.. |
15:14:26 | pigmej | Hey, do we have any decimal / decimal like lib that is working? (I've found two, none is finished, added to nimble) |
15:15:57 | FromGitter | <kaushalmodi> Just curious, what does a "decimal / decimal like" lib do? |
15:16:27 | * | SenasOzys quit (Ping timeout: 240 seconds) |
15:16:32 | * | invisiblek0 joined #nim |
15:16:34 | * | invisiblek0 quit (Remote host closed the connection) |
15:19:23 | * | SenasOzys joined #nim |
15:19:37 | pigmej | It can safely do math operations like "12.43 * 3453.124" |
15:19:43 | pigmej | without problem with float rounding |
15:20:04 | Araq | pigmej: I wrote one but can't find the code... |
15:20:09 | FromGitter | <kaushalmodi> that sounds something like in @mratsim's domain |
15:20:35 | pigmej | Yeah the minimal thingy is not super hard, the problem is that all that I've found are full blown beasts with tons of not implemented stuff and work in progress "everywhere" |
15:24:44 | Araq | I found mine, interested? |
15:25:33 | pigmej | Araq: sure |
15:25:51 | pigmej | I was trying to find it on your github but didn't succeed |
15:26:06 | Araq | it's pretty old but the tests are still green |
15:26:17 | pigmej | Math is also pretty old ;d |
15:27:31 | Araq | https://gist.github.com/Araq/c71b764b94188337b24c6180b239229d |
15:27:48 | pigmej | perfect |
15:27:54 | pigmej | Thank you very much |
15:27:55 | Araq | well it's also full of "not implemented" stuff :-) |
15:27:59 | pigmej | well |
15:28:22 | pigmej | basic math is there that's all that I need |
15:29:40 | Araq | it assumes that 'Decimal' is effectively in a currency |
15:29:50 | pigmej | including C libs with low level wrappers ;-) |
15:30:03 | Araq | so Decimal * Decimal is not possible, you can only multiple with a scalar |
15:30:06 | pigmej | including C libs with low lever wrappers would be less complete anyway |
15:30:56 | Araq | no need to wrap C for this, it's simple enough |
15:31:01 | pigmej | yeah |
15:31:25 | pigmej | https://github.com/status-im/nim-decimal :P this one have c libs included |
15:31:41 | pigmej | (not blaming what so ever) |
15:33:28 | Araq | pigmej: feel free to create a nimble package out of this |
15:33:47 | pigmej | yeah maybe "simple decimal" makes sense or something like that |
15:33:52 | Araq | yup |
15:37:37 | FromGitter | <mratsim> @kaushalmodi a decimal library allows proper rounding of decimal floating point operations |
15:38:12 | FromGitter | <mratsim> default floating point uses binary rounding, hence why 0.1 + 0.2 != 0.2 in old Python |
15:38:12 | FromGitter | <kaushalmodi> Thanks. This was new lingo for me (not into software development) |
15:38:24 | FromGitter | <mratsim> != 0.3* sorry |
15:38:42 | FromGitter | <mratsim> because 0.3 cannot be represented exactly in binary |
15:38:42 | FromGitter | <kaushalmodi> ah yes, I have faced that issue |
15:38:53 | FromGitter | <mratsim> just like we have 0.333333333 issues in decimal rounding |
15:38:55 | FromGitter | <kaushalmodi> I resorted to checking the value of the float sums within limits |
15:39:26 | FromGitter | <mratsim> decimal libraries are key for currencies because obviously in accounting/finance we use decimal rounding. |
15:39:49 | FromGitter | <mratsim> aka, everyone using Excel or database floating point for accounting is wrong. |
15:40:43 | pigmej | I've seen sooooooo many "financial like" systems with floats for values.... |
15:41:41 | Araq | I think some "standards" now require IEEE floating point maths for currency calculations |
15:41:54 | Araq | because this error is everywhere |
15:42:24 | pigmej | yeah sure let's fix user errors with standards... |
15:42:49 | * | Trustable joined #nim |
15:43:38 | FromGitter | <mratsim> As long as people are using Excel to verify stuff, it will be broken. |
15:48:04 | * | ritchie_ quit (Ping timeout: 244 seconds) |
15:51:33 | FromGitter | <arnetheduck> IEEE floating point spec also contains decimal floating points - not one but two variants! |
15:52:13 | TheLemonMan | Araq, wrt #8955 do you have a better idea about how to declare the "standard" js exceptions? I see PJSError is defined in jssys and that's the same as `Error` (that I've wrapped as JsError) |
15:53:37 | TheLemonMan | and if you're done with the docgen stuff I can rebase #8886 |
16:01:08 | * | nsf joined #nim |
16:01:15 | * | ritchie_ joined #nim |
16:10:13 | * | kapil___ quit (Quit: Connection closed for inactivity) |
16:12:51 | * | SenasOzys quit (Ping timeout: 252 seconds) |
16:14:07 | * | Trustable quit (Remote host closed the connection) |
16:26:04 | * | icebattle joined #nim |
16:39:34 | * | SenasOzys joined #nim |
16:43:25 | AlexMax | I've seen nim complain at me about ambiguous definitions of true before, and suggest bool.true to disambiguate it |
16:43:44 | AlexMax | But when I do that, I get another error - undeclared field true |
16:53:10 | * | Jesin quit (Quit: Leaving) |
16:56:17 | * | xet7 joined #nim |
17:00:07 | * | Jesin joined #nim |
17:03:51 | * | riidom joined #nim |
17:08:35 | * | darithorn joined #nim |
17:15:03 | pigmej | Ok, in nim-mode original company backend was much faster and had much better functionality (including flx match) |
17:15:25 | pigmej | if I'll have a while I'll find a way how to bring it back as optional configuration |
17:21:30 | * | TheLemonMan quit (Quit: "It's now safe to turn off your computer.") |
17:22:10 | * | Jesin quit (Quit: Leaving) |
17:24:31 | * | Jesin joined #nim |
17:36:45 | * | WorkGroup1 joined #nim |
17:37:20 | * | WorkGroup1 quit (Remote host closed the connection) |
17:43:28 | * | jxy joined #nim |
18:16:40 | * | gangstacat quit (Quit: Ĝis!) |
18:22:45 | * | monofuel[m] joined #nim |
18:23:13 | FromGitter | <zetashift> How is nim-mode currently? I just reinstalled spacemacs |
18:24:21 | * | gangstacat joined #nim |
18:25:50 | * | xet7 quit (Quit: Leaving) |
18:27:19 | monofuel[m] | One fun decimal problem I've had before- taking a number and dividing it into many parts, such that all the parts still sum up to the original number. |
18:27:48 | monofuel[m] | to some number of desired precision (eg: 2 or 3 decimal places) |
18:31:59 | FromGitter | <brentp> can anyone point me to a simple example of using channels and threads or spawn? the last stuff I can find from the forum is from 2015 and it recommends using a global TChannel. |
18:35:54 | Araq | brentp: that's still true, except that TChannel is now Channel and really soon now (TM) we'll get a better system based on destructors |
18:37:19 | FromGitter | <brentp> ok. should I wait for that? or is there a simple parallelization pattern I can use? |
18:39:57 | Araq | depends on what you need to do |
18:42:03 | Araq | https://github.com/nim-lang/Nim/blob/devel/tests/parallel/tpi.nim shows how to use 'spawn' |
18:42:40 | Araq | https://github.com/nim-lang/Nim/blob/devel/tests/parallel/tparfind.nim parallel find operation |
18:44:04 | FromGitter | <brentp> I have some code using spawn, but that splits the work into $n mostly even pieces and uses awaitAny on a seq of FlowVarBase . but now I have heterogeneous chunks of work. where some will be slow and some fast. so I want many small chunks sent to a few workers. |
19:02:42 | * | TheLemonMan joined #nim |
19:11:53 | * | xet7 joined #nim |
19:12:57 | * | xet7 quit (Remote host closed the connection) |
19:13:37 | * | xet7 joined #nim |
19:32:26 | * | Vladar quit (Remote host closed the connection) |
19:45:03 | * | miran quit (Ping timeout: 245 seconds) |
19:45:59 | FromGitter | <arnetheduck> btw @Araq, on the topic of channels, any idea what the test fail in https://travis-ci.org/nim-lang/Nim/jobs/429291231 might be? smells of memory corruption in the channel usage.. |
20:13:09 | * | erratic joined #nim |
20:19:31 | * | xet7 quit (Quit: Leaving) |
20:27:49 | * | nioc28 joined #nim |
20:27:50 | Araq | thr.add Thread[void]() # suspicious |
20:28:26 | * | nioc28 quit (Remote host closed the connection) |
20:34:30 | * | Jesin quit (Quit: Leaving) |
20:34:56 | FromGitter | <arnetheduck> oh, why?.. I'm not passing anything to the thread function, just using a global `channel[T]` |
20:37:38 | Araq | you cannot move/copy threads, but I'm not saying that's the real issue here |
20:37:53 | Araq | would be nice to extract a test program from this to take a closer look |
20:37:58 | Araq | also your logic is wrong, I think |
20:38:11 | Araq | let (ok, item) = jobs.tryRecv() |
20:38:11 | Araq | if not ok: |
20:38:11 | Araq | break |
20:38:44 | Araq | ^ just because the thread currently got nothing in the 'jobs' channel doesn't mean it can stop |
20:39:09 | * | Lord_Nightmare quit (Quit: ZNC - http://znc.in) |
20:39:27 | TheLemonMan | Araq, I've updated #9000, the error messages are shit because nkEmpty is rendered as "" but one cannot have everything |
20:42:17 | * | Lord_Nightmare joined #nim |
20:50:36 | * | ritchie_ quit (Ping timeout: 252 seconds) |
20:56:04 | * | Jesin joined #nim |
21:00:03 | FromGitter | <Epictek> Still having issue with sockets :/ |
21:00:40 | stefanos82 | Araq: you mean it's not possible to move or copy a thread to another? |
21:01:51 | * | nsf quit (Quit: WeeChat 2.2) |
21:04:23 | FromGitter | <arnetheduck> @Araq ⏎ ⏎ > you cannot move/copy threads, but I'm not saying that's the real issue here ⏎ that's pure copy-pasting from some example I found - besides, if it's not allowed, shouldn't the compiler prevent it? ⏎ > let (ok, item) = jobs.tryRecv() ... [https://gitter.im/nim-lang/Nim?at=5ba16856be4f300626b358d1] |
21:04:38 | * | ritchie_ joined #nim |
21:06:03 | FromGitter | <Epictek> When compiling on arm64 sun_path ends up as `@"termux-input\0\0"` |
21:06:27 | TheLemonMan | Epictek, because sizeof(cint) - sizeof(cushort) = 2 |
21:09:30 | FromGitter | <Epictek> is it an easy fix? |
21:11:35 | TheLemonMan | yes, it just requires a lot of boring type changes |
21:11:41 | dom96 | huh, problems on arm64 only? |
21:11:49 | dom96 | Are you doing some unsafe things with sockets? |
21:13:15 | FromGitter | <Epictek> nope, just connecting to a socket on arm64 |
21:14:18 | TheLemonMan | as a temporary workaround patch the connectUnix function in the stdlib |
21:18:17 | dom96 | Please make sure you report this if you haven't already |
21:21:00 | * | TheLemonMan quit (Quit: "It's now safe to turn off your computer.") |
21:25:12 | Araq | arnetheduck: yes, the compiler should prevent this, overloaded assignment and moves are in development and will allow us to prevent this |
21:25:52 | Araq | and yeah, it's an interesting bug, I would like to see a trimmed down example that reproduces the problem |
21:26:12 | FromGitter | <Epictek> @dom96 reported it as an issue on github |
21:28:12 | FromGitter | <arnetheduck> moves, is that going to be an under-the-hood optimization or something users are expected to know about? I remember the confusion and years I spent explaining the concept to myself then colleagues when it made its way to c++ - perhaps it's easier now though that it's a little bit more familiar, at least for c++/rust folk |
21:41:06 | dom96 | Epictek: Please include a code sample |
21:44:52 | * | brainproxy joined #nim |
22:06:20 | * | Sembei joined #nim |
22:08:24 | FromDiscord | <exelotl> I'm getting this issue where names are mangled when I try to add to a stmtlist using `quote` or `getAst` |
22:08:30 | * | Pisuke quit (Ping timeout: 272 seconds) |
22:08:36 | FromDiscord | <exelotl> seems to be the same problem as here: https://forum.nim-lang.org/t/3253 |
22:13:28 | * | inire0 joined #nim |
22:14:15 | * | inire0 quit (Remote host closed the connection) |
22:15:55 | * | ebx1000 joined #nim |
22:34:28 | * | erratic quit (Ping timeout: 272 seconds) |
22:44:08 | * | zachcarter joined #nim |
22:52:03 | AlexMax | man |
22:52:15 | AlexMax | kind of a shame the vscode-nim extension has been untouched since feb |
23:04:20 | * | erratic joined #nim |
23:08:52 | * | seni quit (Quit: Leaving) |
23:10:10 | * | noonien quit (Quit: Connection closed for inactivity) |
23:11:20 | * | c15ade4 joined #nim |
23:11:46 | c15ade4 | Is the full list of nim grants in the github issues? |
23:14:18 | * | abm joined #nim |
23:35:19 | * | ant_25 joined #nim |
23:38:08 | * | ant_25 quit (Remote host closed the connection) |