00:00:41 | FromDiscord | <pyolyokh> it's not magically empty, but it has the last value it was assigned in the loop, and the procs that are called all reference that same location. If your last col is "x" instead, they'll all be "x" instead of "" |
00:01:39 | FromDiscord | <pyolyokh> c.f. <https://nim-lang.org/docs/manual.html#closures-creating-closures-in-loops> |
00:02:39 | FromDiscord | <pyolyokh> sent a code paste, see https://play.nim-lang.org/#ix=4kWy |
00:08:36 | FromDiscord | <ted__> sent a long message, see http://ix.io/4kWv |
00:09:03 | * | ltriant joined #nim |
00:33:47 | FromDiscord | <Nilts> sent a code paste, see https://play.nim-lang.org/#ix=4kWE |
00:36:56 | FromDiscord | <Girvo> sent a long message, see https://paste.rs/3lf |
00:38:04 | FromDiscord | <Girvo> To add to that, it would be ideal if I could store the thread ID next to it as well, but that's less of an issue -- the threads are always unique/theres only ever one X thread, so I can store that in standard vars anyway |
00:38:50 | FromDiscord | <Elegantbeef> `set[MyThreadNames]`? |
00:40:43 | FromDiscord | <Girvo> Yeah thats basically the conclusion I came to |
00:40:56 | FromDiscord | <Elegantbeef> So why did you mention `std/sets`? |
00:41:18 | FromDiscord | <Girvo> Because I have the docs open right now and need another coffee? š |
00:44:13 | FromDiscord | <Girvo> Built-in set doesn't require unique/only-one-of-this-enum hey? Not a great stress, the way the config handling works it shouldn't be an issue |
00:45:46 | FromDiscord | <Elegantbeef> It's a bitset for the ordinal range |
00:48:29 | FromDiscord | <Girvo> š sweet |
00:52:35 | * | ltriant quit (Ping timeout: 255 seconds) |
00:52:47 | FromDiscord | <Girvo> sent a code paste, see https://paste.rs/emL |
00:56:55 | FromDiscord | <Elegantbeef> Without any hashing or similar! š |
01:00:58 | * | jjido quit (Quit: My laptop has gone to sleep. ZZZzzzā¦) |
01:12:43 | FromDiscord | <jos> i just ran into an issue where i'm passing around a lot of `type X = pointer` types and i had the order swapped in an argument list |
01:12:55 | FromDiscord | <jos> two types defined like that are considered covariant by the nim compiler i guess |
01:13:04 | FromDiscord | <jos> so i was passing them in lieu of each other and it wasn't giving me an error, took me forever to figure out |
01:13:11 | FromDiscord | <jos> how can i avoid that |
01:13:40 | FromDiscord | <pyolyokh> `type X = distinct pointer` |
01:14:36 | FromDiscord | <jos> ok cool |
01:14:44 | FromDiscord | <jos> a lot of my c ffi dependencies aren't doing that |
01:14:51 | FromDiscord | <jos> š¦ |
01:18:41 | FromDiscord | <Elegantbeef> Or `type X = ptr object` |
01:18:42 | FromDiscord | <Elegantbeef> `type X = pointer` is just an alias |
01:25:49 | FromDiscord | <T0lk1en> Is there a reason why random would generate the same numbers over and over again? |
01:27:34 | FromDiscord | <Elegantbeef> You didnt call randomise |
01:29:28 | FromDiscord | <T0lk1en> Wdym |
01:30:31 | FromDiscord | <T0lk1en> Nvm |
01:30:34 | FromDiscord | <T0lk1en> Ty |
01:30:50 | FromDiscord | <Elegantbeef> Like did you even look at `std/random`'s manual? |
01:37:08 | * | crem quit (Ping timeout: 260 seconds) |
02:05:11 | FromDiscord | <jtv> If you're using it for crypto, it's going to be easily broken. |
02:05:32 | FromDiscord | <jtv> Instead, you want std/sysrand |
02:16:44 | FromDiscord | <!!sharpcdf!!> sent a code paste, see https://paste.rs/GOo |
02:17:28 | FromDiscord | <Elegantbeef> do you deinit illwill? |
02:17:44 | FromDiscord | <!!sharpcdf!!> at the end of my program yes i do |
02:18:21 | FromDiscord | <!!sharpcdf!!> oh wait not in all cases |
02:23:06 | FromDiscord | <!!sharpcdf!!> yea no it doesnt show the second prompt still |
02:36:19 | * | ltriant joined #nim |
02:42:10 | FromDiscord | <Elegantbeef> well the code you shared doesnt give much insight |
03:12:34 | * | crem joined #nim |
03:55:12 | FromDiscord | <T0lk1en> What is the best way to shift an array |
03:55:26 | FromDiscord | <T0lk1en> In reply to @Elegantbeef "Like did you even": Overlooked it |
04:32:33 | FromDiscord | <Gumbercules> In reply to @sharpcdf "yea no it doesnt": I'd get rid of `choosing` and instead do `while true` with `break` |
04:33:26 | FromDiscord | <Gumbercules> not that I think it will fix your problem, but then at least you know that `choosing` isn't being modified elsewhere |
04:34:00 | FromDiscord | <Gumbercules> unless you need to modify `choosing` outside of the `case` statement |
04:34:45 | FromDiscord | <Gumbercules> posting a more complete example would certainly help though, as beef pointed out, there's not much to go on |
04:37:40 | FromDiscord | <pyolyokh> In reply to @T0lk1en "What is the best": shift how? probably you want algorithm.rotateLeft or the like.āµbest how? if you're doing this a lot, and if you're rotating all the elements, the best way to use another data structure because this will be very costly. |
04:38:21 | FromDiscord | <T0lk1en> I want to shift array right. For example |
04:38:39 | FromDiscord | <T0lk1en> 12345 ā> |
04:38:46 | FromDiscord | <T0lk1en> 51234 |
04:40:11 | FromDiscord | <pyolyokh> then, algorithm. |
04:52:51 | FromDiscord | <T0lk1en> Got it |
04:59:34 | FromDiscord | <Mustache Man> it's late and brain isn't working well. how should I delete a sequence of items, or known non-contiguous indices, from a sequence? |
05:01:21 | FromDiscord | <Mustache Man> sent a code paste, see https://play.nim-lang.org/#ix=4kX9 |
05:51:56 | * | azimut quit (Ping timeout: 255 seconds) |
06:10:48 | FromDiscord | <iffy (Matt Haggard)> How do I truncate a file I'm writing to? |
06:26:25 | FromDiscord | <demotomohiro> @iffy Read and save the content of a file you want to keep, then open that file with `fmWrite` (this clear the file) and write the saved content. |
06:29:50 | FromDiscord | <demotomohiro> It seems there is no procedure that remove a part of file content. You can only clear file content by opening it with `fmWrite`. |
06:48:21 | FromDiscord | <Gumbercules> you could wrap posix's `truncate` / `ftruncate` |
06:50:10 | FromDiscord | <Gumbercules> sent a code paste, see https://play.nim-lang.org/#ix= |
07:03:02 | * | kenran joined #nim |
07:20:18 | * | kenran quit (Remote host closed the connection) |
07:37:24 | * | ltriant quit (Ping timeout: 260 seconds) |
08:03:46 | * | ltriant joined #nim |
08:04:02 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! |
08:04:05 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:05 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:07 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:08 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! |
08:04:08 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:09 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:10 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! |
08:04:13 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:15 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:15 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:16 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:16 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:18 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:18 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:21 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:21 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:24 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:25 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:27 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:28 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:29 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyoneJOIN discord.gg/ yunjin NOW! @everyoneJOIN discord.gg/ yunjin NOW! @everyoneJOIN discord.gg/ yunjin NOW! @everyoneJOIN discord.gg/ yunjin NOW! @everyoneJOIN discord.gg/ yunjin NOW! @everyoneJOIN discord.gg/ yunjin NOW! @everyoneJOIN discord.gg/ yunjin NOW! @everyoneJOIN discord.gg/ yunjin NOW! @everyoneJOIN discord.gg/ yunjin NOW! @everyone |
08:04:29 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @everyone |
08:04:36 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @everyone |
08:04:38 | FromDiscord | <rĀ”n> JOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @not_everyoneeJOIN discord.gg/ yunjin NOW! @everyone |
08:04:40 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXJ |
08:04:45 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXJ |
08:04:48 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXJ |
08:04:48 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXJ |
08:04:51 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXJ |
08:04:51 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXK |
08:04:52 | FromDiscord | <rĀ”n> sent a long message, see https://paste.rs/s9L |
08:04:52 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXJ |
08:04:59 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXL |
08:04:59 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXJ |
08:05:00 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXJ |
08:05:00 | FromDiscord | <rĀ”n> sent a long message, see https://paste.rs/rAs |
08:05:04 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXM |
08:05:06 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXL |
08:05:15 | FromDiscord | <rĀ”n> who the hell is not everyonne |
08:05:23 | FromDiscord | <rĀ”n> idk |
08:05:24 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXL |
08:05:38 | FromDiscord | <rĀ”n> sent a long message, see http://ix.io/4kXJ |
08:05:48 | FromDiscord | <ElegantBeef> <@&371760044473319454> spam isnt from matrix this time |
08:05:53 | FromDiscord | <ElegantBeef> Welp... |
08:06:16 | FromDiscord | <impbox [ftsf]> nice surprise when it's from discord and we can ban+delete easily |
08:08:03 | FromDiscord | <Elegantbeef> It's rare |
08:08:17 | FromDiscord | <Elegantbeef> Though matrix spam has gone down tremendously |
08:21:12 | FromDiscord | <Phil> Maybe enough of the bot-spammer-networks count our server as unprofitable enough to not be worth the CPU cycles |
08:21:18 | FromDiscord | <Phil> We can only hope |
08:41:50 | * | PMunch joined #nim |
08:41:57 | * | crem quit (Ping timeout: 255 seconds) |
08:45:06 | * | crem joined #nim |
08:46:15 | FromDiscord | <PMunch> Federico set up some automatic measures against spam as well. |
09:12:28 | * | cyraxjoe quit (Quit: No Ping reply in 180 seconds.) |
09:13:45 | * | cyraxjoe joined #nim |
10:06:09 | FromDiscord | <cow> more and more matrix home servers have added a verified email as a requirement for an account š |
10:09:04 | FromDiscord | <Elegantbeef> Dont tell the spammers they can host their own |
10:10:10 | FromDiscord | <cow> their homeserver will just get blacklisted |
10:10:38 | FromDiscord | <cow> and domain names cost money |
10:11:05 | FromDiscord | <cow> I think they'd rather get a million emails than a million domains |
10:11:31 | FromDiscord | <leetnewb> plenty of free ddns domains |
10:12:35 | FromDiscord | <cow> you can block the parent domain |
10:12:55 | FromDiscord | <cow> some email spam filters mark entire TLDs as spam |
10:14:10 | FromDiscord | <cow> especially that notorious one that asks you to pay to get unblocked |
10:14:17 | FromDiscord | <Elegantbeef> I'm not going to be pro spam, but ostensibly spamming has to be profitable enough to get a few $3 domains š |
10:18:28 | FromDiscord | <cow> then we're heading to a home server whitelist era soon š |
10:18:42 | FromDiscord | <cow> which would be sad |
10:19:50 | FromDiscord | <Elegantbeef> Would defeat the whole federated part |
10:20:11 | FromDiscord | <cow> doesn't mastodon already operate that way? |
10:20:49 | FromDiscord | <Elegantbeef> Sure but still feels like it defeats the point |
10:20:53 | FromDiscord | <cow> there's already a big blocklist of "bad" servers being maintained |
10:22:13 | FromDiscord | <cow> and extremism qualifies to get there |
10:22:33 | FromDiscord | <cow> so wouldn't be such a big step to make |
10:22:57 | FromDiscord | <cow> especially if good servers could share the list of good servers, and there would be an application form, where anyone could easily join |
10:23:37 | FromDiscord | <Elegantbeef> I think a blacklist and a whitelist are vastly different when it comes to federated communites |
10:24:40 | FromDiscord | <Elegantbeef> A vast majority of homeservers are not going to host large swathes of people that 'misbehave' |
10:25:40 | FromDiscord | <Elegantbeef> A small amount of homeservers will host the type of people most people would rather not interact with |
10:26:41 | FromDiscord | <Elegantbeef> I especially think mastadon is a bit different due to the fact everyone can see eachother |
10:26:57 | FromDiscord | <Elegantbeef> I mean there is a whole federated feed that you can see content |
10:27:34 | FromDiscord | <Elegantbeef> Anyway I really should put some effort into expanding the matrix sdk, just so much tedious work |
10:37:02 | FromDiscord | <federico3> please use #offtopic for this |
11:16:07 | * | azimut joined #nim |
11:23:26 | FromDiscord | <whosent> anyone else having the issue of choosenim downloading x32 distributions? |
11:27:21 | FromDiscord | <ShalokShalom> In reply to @cow "then we're heading to": Matrix.org makes up for the most accounts anyway |
11:27:42 | FromDiscord | <ShalokShalom> Sorry, #offtopic |
11:31:50 | * | jjido joined #nim |
11:44:40 | Amun-Ra | is there nim template that returns the current proc/func name? |
11:45:55 | FromDiscord | <Phil> In reply to @Amun-Ra "is there nim template": I had a similar question a couple months ago, the answer was no back then |
11:46:39 | FromDiscord | <Phil> needed the name of the proc from inside the proc though I don't remember anymore for what purpose, wasn't doable |
11:51:05 | FromDiscord | <!!sharpcdf!!> In reply to @Gumbercules "I'd get rid of": OH WAIT |
11:51:20 | FromDiscord | <!!sharpcdf!!> CHOOSING IS A GLOBAL VARIABLE I DONT THINK ITS BEING RESET TO TRUE LMAO |
11:53:48 | Amun-Ra | Phil: oh, thanks |
12:00:10 | PMunch | @Phil, well it is doable |
12:00:20 | PMunch | Use instantiationInfo and read the file manually |
12:00:57 | PMunch | You can apparently also use some hacks: https://stackoverflow.com/questions/48686642/how-can-i-get-the-name-of-procedure-in-nim |
12:09:19 | FromDiscord | <Phil> Huh, wasn't aware of that one back then |
12:15:26 | Amun-Ra | I ended up with this: https://play.nim-lang.org/#ix=4kYT |
12:18:20 | Amun-Ra | I know there's logging module in std, but it lacks some features I needed |
12:29:26 | PMunch | What features would that be? |
12:29:36 | PMunch | Asking in case I ever get around to improve superlog |
12:30:58 | Amun-Ra | I wanted another level of debugging, plus one of my target is non-posix non-windows one and I can't rely on std/os |
12:31:12 | Amun-Ra | targets* |
12:32:03 | Amun-Ra | and I automagically add module:line to the log entry |
12:32:47 | * | ltriant quit (Ping timeout: 246 seconds) |
12:33:03 | * | ltriant joined #nim |
12:33:52 | Amun-Ra | ā¦and I wanted every debug/info/trace/notice to have {.raises: [].} |
12:43:07 | PMunch | I see |
12:43:26 | PMunch | All of that should be achievable with superlog |
12:43:49 | FromDiscord | <luteva> In reply to @PMunch "Basically if you set": ok as far as i understand, there should be a logfile, generated by nimlsp_debug. but i can't find it. where is it supposed to be? |
12:44:31 | PMunch | The point of superlog is essentially that you can litter log statements everywhere, and log any type you'd like. Then in your main module you define what log statements should expand to, based on module and type |
12:45:58 | PMunch | So e.g. your module could log a JsonNode and some tuples of LogLevel and string. Then in my module which uses your module I can say that only the log statements that log JsonNodes should actually do anything, and they should expand to whatever thing I want them to expand to (so you could have all your {.raises: [].} and os-aware stuff. |
12:49:34 | Amun-Ra | hmm |
12:50:07 | FromDiscord | <iffy (Matt Haggard)> Okay, thanks. Guess it's not built-in to stdlib.āµ(@Gumbercules) |
12:52:46 | PMunch | @luteva, the logs are stored in `getTempDir() / "nimlsp-" & $getCurrentProcessId() & "/nimlsp.log"` |
12:55:58 | FromDiscord | <luteva> yes! that was exactly what i was searching for! thx |
12:56:13 | FromDiscord | <luteva> (edit) "yes! that was exactly what i was searching for! thx ... " added "@PMunch" |
12:58:24 | FromDiscord | <luteva> cool! can see it logging e.g. on hover š |
12:58:52 | PMunch | Amun-Ra, @Phil, here is some more stuff for getting the proc name: https://github.com/nim-lang/Nim/pull/17641 |
12:59:48 | PMunch | @luteva, if you only want the communications going back and forth you can build manually with -d:debugCommunications |
13:00:19 | PMunch | (It's recommended to still use -d:release otherwise it's quite slow) |
13:03:20 | * | jjido quit (Quit: My laptop has gone to sleep. ZZZzzzā¦) |
13:21:43 | Amun-Ra | PMunch: great find, it works |
13:23:55 | FromDiscord | <luteva> thx again @PMunch i can now do, what i wanted to!āµI have one more question about the lsp: My understanding is that the editor and the lsp server open the file and they both keep a separate copy of the file in a buffer. The editor then sends each update, made to the file, directly the the lsp server which updates its own buffer. This is how the editor and the lsp server keep themselves up-to-date.āµIs that correct? |
14:10:04 | PMunch | @luteva, not quite. The editor opens the file, then sends a notification to the LSP server with the entire contents of the file |
14:10:38 | PMunch | Then the editor sends edited versions of the file at whichever interval it sees fit |
14:10:57 | PMunch | So the server doesn't really read the input file at all |
14:11:29 | PMunch | Of course it still serves you the paths and such, so that the server can find imports and other things like that |
14:35:52 | FromDiscord | <luteva> but it only sends the changes, right? or does it send the whole file (including the changes)? |
14:42:12 | PMunch | @luteva, https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#textDocument_synchronization |
14:42:26 | PMunch | NimLSP uses TextocumentSyncKind.Full |
14:47:51 | FromDiscord | <luteva> ok. i see. there is a "range and text" OR a (full) "text only". |
14:48:40 | * | PMunch quit (Quit: Leaving) |
15:11:23 | * | arkurious joined #nim |
15:57:47 | * | kenran joined #nim |
16:00:36 | * | kenran quit (Remote host closed the connection) |
16:16:16 | FromDiscord | <pyryrin> if the rule is whenever you can use a proc instead of template, then why is `assert` a template? |
16:17:46 | FromDiscord | <Rika> because it needs the template? |
16:18:01 | FromDiscord | <pyryrin> why? |
16:19:34 | FromDiscord | <Rika> because it uses instantiationInfo to point to the correct line when an error occurs, or so |
16:19:51 | FromDiscord | <pyryrin> oh |
16:23:27 | FromDiscord | <pietroppeter> interesting bug in integer division found in bigints library thanks to a fuzzer: https://github.com/nim-lang/bigints/issues/123 |
16:24:06 | * | fallback quit (Remote host closed the connection) |
16:59:13 | FromDiscord | <pietroppeter> @planetis you want to try DrChaos against bigints? š |
17:11:03 | * | jjido joined #nim |
17:22:12 | * | fallback joined #nim |
17:22:14 | FromDiscord | <pyryrin> sent a code paste, see https://paste.rs/ljZ |
17:23:47 | FromDiscord | <Rika> `template š¤¬(): File = stderr` |
17:23:53 | FromDiscord | <Rika> need to have return type |
17:24:04 | FromDiscord | <pyryrin> oh oops |
17:24:10 | FromDiscord | <pyryrin> forgot basic nim |
17:24:18 | FromDiscord | <Rika> thats fine |
17:24:28 | FromDiscord | <Rika> common forgotten thing i would say |
17:26:30 | FromDiscord | <pyolyokh> and Nim is a relatively bad language when half-remembered. It accepts nonsense instead of erroring on it, and it errors on bad code but not in a useful way (evergreen: fake indentation errors). |
17:32:37 | FromDiscord | <ā¶ Zeno> hello people, how can i change a node into another node ?āµi did `.body=` but that gives me "Invalid node king nnkCommand for macros.body="āµāµi am trying to do var assignment of apl, so like `h ā [1, 2]` is equivalent to `var h = [1, 2]` for fun https://media.discordapp.net/attachments/371759389889003532/1063148506182848643/image.png |
17:32:52 | FromDiscord | <ā¶ Zeno> i am new to macros by the way |
17:32:56 | FromDiscord | <ā¶ Zeno> (edit) "fun" => "fun, if theres a way to do this without macros, let me know" |
17:33:46 | FromDiscord | <pyolyokh> well, just like templates, macros have a return value |
17:33:52 | FromDiscord | <ā¶ Zeno> oh yeah |
17:34:27 | FromDiscord | <ā¶ Zeno> well i still get same result even if i `return ast` assuming `child.body=tree` does exactly what i want it to do |
17:34:34 | FromDiscord | <pyolyokh> although a void return is now the old `typed` return I guess. They return the new AST structure |
17:34:55 | FromDiscord | <pyolyokh> well, you don't get the same result, because you wouldn't be using body= anymore |
17:35:10 | FromDiscord | <ā¶ Zeno> well so i have to make my own ast structure without editing original ? |
17:37:03 | FromDiscord | <pyolyokh> yes. because stuff like body= aren't even defined |
17:37:12 | FromDiscord | <ā¶ Zeno> alright then, thanks for help |
17:37:15 | FromDiscord | <ā¶ Zeno> (edit) "help" => "info" |
17:38:53 | FromDiscord | <pyolyokh> Mastering Nim language is "A macro receives ASTs in its parameters and returns a new AST.", and even the manual examples that don't have an apparent return type, they use `result.add` to build an AST to return |
17:40:31 | FromDiscord | <demotomohiro> You can copy `ast` param, modify it and return |
17:40:42 | FromDiscord | <ā¶ Zeno> and how would i do modifying ? |
17:40:45 | FromDiscord | <ā¶ Zeno> thats what im trying to do |
17:40:51 | FromDiscord | <ā¶ Zeno> except its on original ast but eh |
17:41:00 | FromDiscord | <ā¶ Zeno> (edit) "its" => "i was modifying it" |
17:42:34 | FromDiscord | <demotomohiro> You can modify copy of `ast` just by adding new node or replace exisiting node. |
17:43:17 | FromDiscord | <ā¶ Zeno> i'd prefer if i could replace existing nnkCommand, can you tell me more about it ? |
17:43:19 | * | jjido quit (Quit: My laptop has gone to sleep. ZZZzzzā¦) |
17:47:24 | FromDiscord | <Tanguy> sent a code paste, see https://play.nim-lang.org/#ix=4l0x |
17:47:30 | FromDiscord | <demotomohiro> You can set specific child of `NimNode` like `foo[i] = newNode`. https://nim-lang.org/docs/macros.html#%5B%5D%3D%2CNimNode%2Cint%2CNimNode |
17:48:41 | FromDiscord | <demotomohiro> There is `pairs` iterator to get the index of a NimNode: https://nim-lang.org/docs/macros.html#pairs.i%2CNimNode |
17:50:15 | * | xet7 quit (Quit: Leaving) |
17:50:19 | FromDiscord | <ā¶ Zeno> thanks tanguy and demotomohiro |
17:50:23 | FromDiscord | <ā¶ Zeno> i did it š„³ https://media.discordapp.net/attachments/371759389889003532/1063152976820183040/image.png |
17:51:32 | FromDiscord | <pyolyokh> what's your final code? |
17:51:36 | FromDiscord | <ā¶ Zeno> oh and thanks to pyolyokh too |
17:51:45 | * | xet7 joined #nim |
17:51:46 | FromDiscord | <ā¶ Zeno> In reply to @pyolyokh "what's your final code?": https://media.discordapp.net/attachments/371759389889003532/1063153326591582318/image.png |
17:52:00 | FromDiscord | <pyolyokh> nah, that shows I was wrong |
17:52:24 | FromDiscord | <ā¶ Zeno> what do you mean you were wrong |
17:52:28 | FromDiscord | <ā¶ Zeno> im sure you were correct |
17:52:38 | FromDiscord | <pyolyokh> you're able to modify the tree in place like you wanted |
17:52:48 | FromDiscord | <ā¶ Zeno> ah |
17:52:54 | FromDiscord | <ā¶ Zeno> that |
17:52:58 | FromDiscord | <scipio> https://forum.nim-lang.org/t/4758 |
17:52:59 | FromDiscord | <Tanguy> You can modify the tree, but you still need to return, AFAIK |
17:53:03 | FromDiscord | <ā¶ Zeno> In reply to @Tanguy "You can modify the": yup |
17:53:05 | FromDiscord | <scipio> How about V lang now??? |
17:53:27 | FromDiscord | <ā¶ Zeno> code itself doesnt run if you dont return |
17:58:53 | FromDiscord | <scipio> https://media.discordapp.net/attachments/371759389889003532/1063155117911707688/image.png |
17:59:08 | FromDiscord | <scipio> this looks pretty cool to me tbh, V has a stdlib UI even |
17:59:14 | FromDiscord | <pyolyokh> sent a long message, see http://ix.io/4l0A |
17:59:30 | * | xet7 quit (Quit: Leaving) |
17:59:55 | FromDiscord | <scipio> https://media.discordapp.net/attachments/371759389889003532/1063155374401802250/image.png |
18:00:20 | FromDiscord | <scipio> I've spent 2 full days on Nim hunting down the best way to do this . Any idea how much more welcoming V comes across to new devs? |
18:00:26 | FromDiscord | <demotomohiro> sent a code paste, see https://paste.rs/cdy |
18:00:46 | FromDiscord | <scipio> The community here on Nim is absolutely one of a kind tho... |
18:00:54 | FromDiscord | <pyolyokh> I did a little flash card program in v, with its gui, before rewriting it in Nim and illwill. I think v's not bad at all as a language, and I prefer that kind of syntax to Nim's even. |
18:01:12 | FromDiscord | <scipio> But tbh, I fell off my chair multiple times seeing the Nim founder reply to community efforts |
18:01:29 | FromDiscord | <ā¶ Zeno> In reply to @demotomohiro "You can use `<-`": oh damn thanks for giving me non-macro way, which turned out to be simple |
18:01:35 | FromDiscord | <scipio> https://media.discordapp.net/attachments/371759389889003532/1063155794633298080/image.png |
18:01:36 | FromDiscord | <ā¶ Zeno> i'll try to use templates next time, thanks again |
18:01:44 | FromDiscord | <scipio> https://media.discordapp.net/attachments/371759389889003532/1063155836077232258/image.png |
18:01:46 | FromDiscord | <scipio> ehh.... wtf? |
18:02:06 | FromDiscord | <scipio> You think seeing this makes me want to immediately invest > 1 month of my time in Nim? |
18:02:32 | FromDiscord | <ā¶ Zeno> (edit) "In reply to @demotomohiro "You can use `<-`": oh damn thanks for giving me non-macro way, which turned out to be simple ... " added "(although not same identifier, but thats fine)" |
18:02:51 | FromDiscord | <Tanguy> https://nim-lang.org/docs/manual.html#syntax-precedence the "First character" column is the list of first char you can use for the kind of template that @demotomohiro sent |
18:02:53 | FromDiscord | <scipio> It doesnt matter if this comment is right or wrong, on a technical perspective: Owlkettle improves his product Nim. Responding like this to an announcement in public is "not done", period. |
18:02:59 | FromDiscord | <Tanguy> I think |
18:03:18 | FromDiscord | <pyolyokh> He thinks a particular design feature is ugly. Why does that bother you? If we're comparing dev community engagement, v is pretty scandalous as "vapoware" with a "lying dev" thanks to its initial handling. Anyway if that's the core issue, I don't care to discuss it. |
18:03:56 | * | xet7 joined #nim |
18:04:00 | FromDiscord | <Tanguy> Who cares about the language creator, if everything goes well, you will never have to talk to him |
18:04:11 | FromDiscord | <pyolyokh> I think I had a pretty useful reply above to the language, rather than to the personalities. |
18:04:58 | FromDiscord | <scipio> @pyolyokh I am equally neutral to V as I am to Nim at this point in time, I don't know either founders so I cannot tell if one is lying or not. What I am saying, is that I have been researching Nim UI development for 2 days straight and I only came across abandonded or half-baked solutions. And I am _very open_ to embracing Nim |
18:05:26 | FromDiscord | <scipio> But I'm not looking at a language from a technical perspective only |
18:05:58 | * | xet7 quit (Remote host closed the connection) |
18:06:22 | FromDiscord | <demotomohiro> Nim allows you to define operators with some combination of charators: https://nim-lang.org/docs/manual.html#lexical-analysis-operators |
18:06:31 | FromDiscord | <pyolyokh> that's fair. I haven't look at either language's GUI offerings, just terminal for both (decent in both cases) and raylib for Nim. |
18:07:31 | FromDiscord | <ā¶ Zeno> In reply to @demotomohiro "Nim allows you to": yeah i was aware of that, but i was mainly trying to do `ā` thats why i resorted to not doing \`<-\` |
18:07:34 | FromDiscord | <scipio> In reply to @Tanguy "Who cares about the": I do. When I dedicate my time into mastering a language or framework, I want to assess the potential ROI on my time spent on it, commercially, as well.āµHow many job advertisements do you currently see on Nim? How many companies have embraced it into their tech stack? āµāµ--- this is no Pun: I'd love Nim to succeed. It's an honest assessment. |
18:07:52 | FromDiscord | <pyolyokh> for GUIs I'd start with <https://nimble.directory/search?query=gui> and, unfortunately since that doesn't have any kind of way to sort by metrics, I'd check each repository until I found something that looks reasonably baked. It wouldn't take two days. |
18:08:37 | FromDiscord | <Tanguy> How does the commercial success of the language depends on the creator of the languages responses on a forum |
18:09:29 | FromDiscord | <scipio> If you need to ask that I don't have time to answer |
18:09:38 | FromDiscord | <scipio> Tl;DR: a lot |
18:10:22 | FromDiscord | <Tanguy> How often do you read the responses of the creator of python, or C++ on forums? Never, because the community took over |
18:10:50 | FromDiscord | <scipio> When I see Andre von Auck talk about Nim, I love it: want to dive into it immediately. When I read a toxic reply or see a book author getting bashed, I don't. See the difference? |
18:11:46 | FromDiscord | <scipio> There's a ton of competition among new languages |
18:11:55 | FromDiscord | <scipio> They're all fighting for developer attention |
18:12:25 | FromDiscord | <scipio> That was not the case when my fellow-countryman Guido van Rossum developed Python |
18:13:35 | FromDiscord | <scipio> In reply to @pyolyokh "for GUIs I'd start": I did exactly that. Check the repos mentioned in there. Most of them aren't actively being developed. |
18:13:37 | FromDiscord | <cow> dutch person detected |
18:13:52 | FromDiscord | <pyolyokh> indeed, Python was grossly inferior to Perl in both technical and social capital senses for the first 15 years of its life, so saying "only technicals matters" would be wrong. And although probably Tim Peters is more responsible for the propaganda than Guido, Guido still started it and set the direction of the language. |
18:13:56 | FromDiscord | <scipio> Absoluut, je kunt de Groeten uit Brabant krijgen š |
18:14:00 | FromDiscord | <scipio> @cow |
18:14:40 | * | jjido joined #nim |
18:15:17 | FromDiscord | <Tanguy> Let's be honest, the reason rust or go took of compared to nim is because they are backed by massive companies, not for their syntax, features or creators activity on forums (imo) |
18:15:48 | FromDiscord | <scipio> Don't get me wrong here, Nim has a ton of very cool stuff baked in, I'd love Nim to succeed. I do. āµI do miss a lot of focused attention for UI development in Nim. Should be 1st class citizen. It's not, face the facts. |
18:15:51 | FromDiscord | <cow> they advertise themselves as solving a problem that pains many companies |
18:15:58 | FromDiscord | <pyolyokh> there's a lot to say there but none of it very interesting. |
18:16:59 | FromDiscord | <Tanguy> scipio: Nim tries to be "good at everything", thus not 1st class citizen for anything, thus almost everything is average š |
18:18:13 | FromDiscord | <mratsim> In reply to @scipio "<@803214225002463283> I am equally": TBH, apart from Delphi and JS, all languages have half-backed OR overengineered UI solutions. |
18:18:35 | FromDiscord | <mratsim> because a good solution will tend to attract people that demand more and more features and then "bloat" |
18:18:47 | FromDiscord | <pyolyokh> In reply to @scipio "Don't get me wrong": everybody thinks that the thing they care about should be the #1 priority. This is a good difference that I already noted above: Araq doesn't care about selling the language himself on its third party support, but V's author has a wishlist that he's actively pursuing. But then Araq knows what type an array index should have. They're both decent examples of how language development might need mo |
18:19:43 | FromDiscord | <cow> In reply to @mratsim "TBH, apart from Delphi": Flutter and .NET UI platforms are pretty good |
18:20:04 | FromDiscord | <mratsim> I remember trying flutter in 2017, it was no man's land. |
18:20:24 | FromDiscord | <pyolyokh> I've had the most fun with J's UI support, which is a very limited DSL. |
18:20:45 | FromDiscord | <scipio> @mratsim which is EXACTLY why I am looking at V (and Jai) and bringing it up here in Nim.āµWhy did "the web" succeed? html, js .... āµ==> it's because if you perceive "a webpage" as an app, html/css/js is "UI first". New devs get immediate results from dabbling in it.. That's very rewarding to explore the language further. |
18:21:37 | FromDiscord | <Tanguy> The web succeeded because you can just go on a page and use a program, instead of having to install it. And it works "everywhere"āµNot because of dev confort. Dev confort came from the need of building web apps |
18:21:47 | FromDiscord | <cow> arguably Vala and Dart are languages that exist because of a good UI library written for the language specifically |
18:22:02 | FromDiscord | <cow> the former case shows that a language can be good for UI even if its selling point is just a binding |
18:22:07 | FromDiscord | <mratsim> In reply to @scipio "<@570268431522201601> which is EXACTLY": I think you are inverting causality. JS succeeded because it was the only language available on the web (if we ignored java applet and Flash/ActionScript).āµāµThe web succeeded because it filled a need. |
18:22:50 | FromDiscord | <cow> In reply to @Tanguy "The web succeeded because": also, it's cross platform and JS devs are cheap |
18:23:09 | FromDiscord | <pyolyokh> and I've made very nice web apps with a Nim backend, using only the 'cgi' module to take care of some chores, and printing `"""<!doctype html>"""` strings. Not a very high effort-floor, to make something useful. |
18:23:10 | FromDiscord | <mratsim> In reply to @cow "also, it's cross platform": are they? |
18:23:18 | FromDiscord | <cow> compared to desktop devs, I think so |
18:23:32 | FromDiscord | <mratsim> what's a desktop dev? |
18:23:52 | FromDiscord | <cow> a .NET dev for example who makes windows native apps |
18:23:56 | FromDiscord | <pyolyokh> In reply to @mratsim "what's a desktop dev?": I believe those are called "electron devs" these days |
18:24:12 | FromDiscord | <cow> or a C++ dev using Qt |
18:24:16 | FromDiscord | <scipio> Irrelevant for this discussion.āµMy point is, language competition is intense now and without a modern native UI framework out of the box, the language will only attract the most hardcore of devs, not ideal for mainstream adoption. |
18:24:22 | FromDiscord | <mratsim> ah, I feel like no one makes native apps anymore :p |
18:24:39 | FromDiscord | <Tanguy> If JS devs are cheap, it's because everyone needs JS devs, so everyone learns JS, so the market is floodedāµAgain, JS is only here because it has(had) monopoly on a very popular platform |
18:25:06 | FromDiscord | <pyolyokh> In reply to @scipio "Irrelevant for this discussion.": Nim isn't going to have a "modern native UI framework out of the box". It'll have the nimble libraries that people make for it. Those that are just wrappers might completely work for you despite not seeming to be actively developed, because wrappers don't need a lot of development. |
18:25:11 | FromDiscord | <cow> it's also a factor that JS is easy to get into (while might be painful in the long run) |
18:25:25 | FromDiscord | <mratsim> In reply to @scipio "Irrelevant for this discussion.": Python doesn't really have a nice UI story, many bindings all over the place as well. |
18:25:30 | FromDiscord | <cow> python' |
18:25:36 | FromDiscord | <scipio> JS is about the only language that becomes harder to write the better you get at it |
18:25:48 | FromDiscord | <mratsim> ==="foo" |
18:25:59 | FromDiscord | <mratsim> (but PHP has it too AFAIK) |
18:26:00 | FromDiscord | <cow> (edit) "python'" => "python found a niche for itself without a UI library" |
18:26:17 | FromDiscord | <pyolyokh> In reply to @scipio "JS is about the": with a strong willpower, you can write `function foo() {}` and not use semicolons, no matter what the crazy people add to it |
18:26:18 | FromDiscord | <mratsim> Rust doesn't have an UI library either |
18:26:22 | FromDiscord | <scipio> Iced |
18:26:48 | FromDiscord | <scipio> Well it's not in the std lib no if that's your point |
18:26:49 | FromDiscord | <cow> there's definitely languages that are successful without a very good UI developing experience |
18:26:55 | FromDiscord | <pyolyokh> Rust doesn't have a UI library in core, "out of the box". It's in the exact same position of Nim, where that stuff is something that a library developer wanted. |
18:26:57 | FromDiscord | <cow> stdlib or not |
18:27:22 | FromDiscord | <mratsim> What about Go? |
18:27:26 | FromDiscord | <scipio> Sure, but if nobody in the language really cares about a focused UI framework that's truly cross-platform and well maintained ... hmmm ... no bueno |
18:27:43 | FromDiscord | <cow> but it would be amazing if nim had an easy to use, mature UI library... but who has the time to make one |
18:27:53 | FromDiscord | <scipio> In reply to @cow "there's definitely languages that": But Rust does have commercial Mozilla backing. That is also lacking for Nim |
18:27:56 | FromDiscord | <T0lk1en> Gtk? |
18:27:57 | FromDiscord | <scipio> No UI, no commercial backing |
18:28:10 | FromDiscord | <scipio> Then how are you going to attract adoption? |
18:28:22 | FromDiscord | <mratsim> other way around again. You don't develop an UI if you don't have a commercial need. |
18:28:23 | FromDiscord | <nixfreak> Owlkettle is pretty fun to write in. I really want to learn more about Karax |
18:28:27 | FromDiscord | <nixfreak> The examples are ok , but I'm having to dig everywhere to find decent Vcomponent examples and ajax examples |
18:28:38 | FromDiscord | <scipio> Where the language founder doesnt want to publish a digital version of his book because people might pirate it |
18:28:43 | FromDiscord | <scipio> I mean wtf |
18:28:46 | FromDiscord | <mratsim> if it's only hobbyist, with no use-case you just don't know the problem you want to fix |
18:28:53 | FromDiscord | <T0lk1en> In reply to @scipio "Where the language founder": What lang is this |
18:28:57 | FromDiscord | <cow> I think there's a commercial need to move away from electron, it's just not big and it's only gonna happen if companies get to keep their cross platform uniform apps |
18:29:09 | FromDiscord | <scipio> In reply to @T0lk1en "What lang is this": this one |
18:29:12 | FromDiscord | <Tanguy> Anyway, it's all chicken and egg, if you are here for a language with big commercial capacity, just go look at the languages with highest salaries and opportunities or whateverāµNim, V, and to some extent rust, are not gonna be on top of that list any time soon |
18:29:17 | FromDiscord | <T0lk1en> Ohā¦ |
18:29:40 | FromDiscord | <Tanguy> if ever |
18:30:14 | FromDiscord | <Tanguy> I'm here because I enjoy using Nim, and been lucky enough to find a job using Nim |
18:30:28 | FromDiscord | <scipio> In reply to @Tanguy "I'm here because I": care to elaborate on that? |
18:31:02 | FromDiscord | <Tanguy> [..] not because I did a business analysis |
18:31:06 | FromDiscord | <Tanguy> On what exactly? |
18:31:13 | FromDiscord | <scipio> On getting a job as Nim dev |
18:31:24 | FromDiscord | <mratsim> same. I liked writing Nim, so i wrote more and more Nim then found a Nim job |
18:31:53 | FromDiscord | <Tanguy> Well, there are basically two ways, you find one of the few companies that use nim, or you try to introduce a bit of nim at your companyāµHad success with both |
18:32:21 | FromDiscord | <Tanguy> But ngl, very few companies use Nim |
18:32:35 | FromDiscord | <scipio> And what was your angle to introduce Nim at your current company? Which primary use case does Nim solve for your company? |
18:33:29 | FromDiscord | <pyolyokh> sent a long message, see http://ix.io/4l0O |
18:33:56 | FromDiscord | <Tanguy> That was at a previous company, I started something that was supposed to be a small project, wanted to try it out in Nim, so I didāµThe project grew, and at no point we had to rewrite it in something else (was still a fairly small project, with ~1.5 FTEs) |
18:34:06 | * | jjido quit (Quit: My laptop has gone to sleep. ZZZzzzā¦) |
18:35:09 | FromDiscord | <scipio> sent a long message, see http://ix.io/4l0P |
18:35:33 | FromDiscord | <Tanguy> Everything becomes a technical challenge once it reaches a certain scale & number of users (including libraries). If it was that straightforward, it would already exist |
18:36:02 | FromDiscord | <scipio> I need to quickly buy some groceries before the store closes, brb |
18:41:48 | FromDiscord | <cow> In reply to @scipio "> _Nim is a": my impression is that the godot and qt bindings are the most mature way to make UI apps in nim |
18:42:07 | FromDiscord | <cow> or possibly other bindings, but I haven't seen those used in production |
18:42:38 | FromDiscord | <cow> maybe just reducing the entry barrier and improving those bindings is the best way to go |
18:43:30 | FromDiscord | <nixfreak> Gintro is very mature for GK3/4 |
18:44:18 | FromDiscord | <nixfreak> Its really too bad nimx isn't getting the help or documentation it needs. |
18:45:15 | FromDiscord | <nixfreak> Fidget was going to be nice because it was (declarative). |
18:47:38 | FromDiscord | <pyryrin> when you do `nimble run` can you just put falgs like `-d:release --gc:orc` after it |
18:48:23 | FromDiscord | <pyolyokh> In reply to @pyryrin "when you do `nimble": yeah. |
18:48:25 | FromDiscord | <scipio> sent a long message, see http://ix.io/4l0U |
18:48:54 | FromDiscord | <cow> In reply to @scipio "just stand still for": no there is definitely a barrier |
18:49:18 | FromDiscord | <scipio> In reply to @nixfreak "Gintro is very mature": Exactly my point: there's a ton of half-baked, in essence very promising but still not finished, attempts, but NONE is mature / production ready |
18:49:21 | FromDiscord | <pyolyokh> >accept your GUI won't look nativeāµwe live in the post-electron world. Nobody cares.āµOr rather, the only people who care are Tk devs who are spinning in their graves about how much their #1 enemy no longer matters. |
18:49:34 | FromDiscord | <nixfreak> In reply to @scipio "just stand still for": Yeah if your new at godot and nim and especially bindings , I would not use godot |
18:49:35 | FromDiscord | <cow> unless you're on mobile |
18:49:51 | FromDiscord | <cow> I think iOS users still want a iOS touch to their apps |
18:50:23 | FromDiscord | <pyryrin> what does gui "not looking native" even mean |
18:51:11 | FromDiscord | <cow> that it doesn't look like your file explorer and settings app š |
18:51:15 | FromDiscord | <pyolyokh> In reply to @pyryrin "what does gui "not": back in 1995, Windows apps had a particular look and feel, and Tcl/Tk apps (and python using Tkinter, having all of scipio's problems above, but mitigated with good documentation) didn't have that look and feel |
18:51:17 | FromDiscord | <nixfreak> In reply to @pyryrin "what does gui "not": Good point , to me its , ios native GUI framework , cocoa , windows winforms and linux Qt, or GTK. |
18:51:47 | FromDiscord | <ambient> I guess there's some UX design principles that some OS in theory have as goal. But on Windows and Linux there are at least 3 different, often more, so it doesn't really matter. |
18:51:52 | FromDiscord | <cow> I think WPF deprecated winforms by now š |
18:52:26 | FromDiscord | <nixfreak> lol I couldn't remember the windows framework , sorry I don't use windows |
18:53:07 | FromDiscord | <ambient> You could build perfectly functional applications with visual basic 3 in minutes. People just want the latest new shiny things, even when they don't make any practical sense |
18:53:40 | FromDiscord | <nixfreak> yeah the visual builder made it pretty simple to create something |
18:54:14 | FromDiscord | <scipio> Show me one user friendly TUTORIAL on making a decent Nim GUI app from scratch |
18:54:31 | FromDiscord | <pyolyokh> I've had <https://nappgui.com/en/start/hello.html> open in a tab for the last week. I invite you to read its starting quote, which is pretty good, and then to read the code that follows. |
18:54:54 | FromDiscord | <nixfreak> Well , lol it depends how in debt you want the application to do |
18:55:02 | FromDiscord | <planetis> Slightly offtopic, I had to write a GUI in java swing, I am curious how owlkettle and Gtk compares. |
18:55:13 | FromDiscord | <ambient> In reply to @scipio "Show me one user": https://github.com/StefanSalewski/gintro#a-few-basic-examples |
18:55:27 | FromDiscord | <nixfreak> (edit) "in debt" => "much" | "do" => "do." |
18:55:50 | FromDiscord | <planetis> Easy https://youtu.be/O44x_la1o_Māµ(@scipio) |
18:55:52 | FromDiscord | <nixfreak> OwlKettle isn't bad to work in , accept when you can't do something |
18:56:12 | FromDiscord | <nixfreak> niup is pretty easy to get into |
18:56:21 | FromDiscord | <nixfreak> OwlKettle, NIgui |
18:56:41 | FromDiscord | <nixfreak> Even NimX you can create things |
18:57:29 | FromDiscord | <planetis> You mean this? https://github.com/dariolah/niup I will check it out.āµ(@nixfreak) |
18:57:55 | FromDiscord | <scipio> In reply to @ambient "https://github.com/StefanSalewski/gintro#a-few-basi": decent attempt, looks promising, but I'm not seeing installation steps targeting macOS |
18:57:56 | FromDiscord | <nixfreak> yep , I created some stuff |
18:58:25 | FromDiscord | <ambient> In reply to @scipio "decent attempt, looks promising,": On Windows, it was just about installing GTK and letting the C compiler know where it was located IIRC |
18:58:59 | FromDiscord | <ambient> Mac should be easier, for example with brew |
19:00:16 | FromDiscord | <planetis> Come on don't be like that, he's donating his free time to make something and share it with the community. If you want macos support work on it.āµ(@scipio) |
19:00:17 | FromDiscord | <scipio> But don't you realize what's happening here?āµ- how does Gintro compare to Owlkettle? It both targets GTK3/4 right? It's confusing to have _too many options_. Without concerted efforts to creating one _de facto solution_ that is agreed on should be "standard", even these two similar solutions rival eachother |
19:00:39 | FromDiscord | <pyolyokh> what I realize what just happened, in the last moment, is goal shifting |
19:01:12 | FromDiscord | <nixfreak> OwlKettle is "declarative" |
19:01:14 | FromDiscord | <scipio> In reply to @planetis "Come on don't be": I don't understand why you'd conclude I'm dissing his attempts; I'm not. I'm applauding them. I'm only pointing out both solutions are re-inventing the wheel and none target macOS |
19:01:22 | FromDiscord | <ambient> yes, one great solution would be excellent, however outside somebody writing industry leading Qt bindings, I don't think that will happen |
19:01:26 | FromDiscord | <pyolyokh> and this is a chilling dilemma that someone has to have already overcome in order to choose Nim at all, which is a language that is not the "one defacto solution" in a world with "too many options" |
19:01:49 | FromDiscord | <ambient> In reply to @pyolyokh "and this is a": Both Rust and Python have/had serious issues with desktop GUI workflows |
19:02:29 | FromDiscord | <scipio> In reply to @pyolyokh "what I realize what": its not. I'm on macOS, I want to build cool stuff including modern UI apps in Nim. Show me the way. |
19:02:47 | FromDiscord | <nixfreak> Yep , in python I really like pyjamas and it died |
19:03:03 | FromDiscord | <ambient> well, both Apple and Microsoft make their desktop application build process very much a walled garden. You should go knock on their door |
19:03:24 | FromDiscord | <pyolyokh> no, what you want to happen is for an official announcement that Nim is backing a single GUI framework as the defacto one, and that's not going to happen, so you should be happy when you ask a for a good tutorial and are given one. |
19:03:26 | FromDiscord | <scipio> It is absolutely mindboggling Python never had a native proper UI framework. Tkinter on steroids. |
19:03:48 | FromDiscord | <ambient> it's not mind boggling at all, refer to my previous comment |
19:04:21 | FromDiscord | <scipio> In reply to @pyolyokh "no, what you want": You have it completely backwards if you want Nim to become mainstream. If you want NIm to remain obscure, a footnote in computer science 25 years from now, then you\re on track |
19:04:56 | FromDiscord | <ambient> most OSS communities aren't businesses, it's just a bunch of guys hacking together things they want to exist |
19:05:02 | FromDiscord | <pyolyokh> what I have is a good sense of what will happen and what will not happen, and the thing you want just isn't going to happen, so there's no need to keep goal-shifting to get there. |
19:05:14 | FromDiscord | <ambient> therefore there's no customer department that you can really target your complaints at |
19:05:20 | FromDiscord | <scipio> I'm merely asking the right questions for Nim to succeed. And you assume I am looking for a dev job in Nim. You're wrong. I'm a serial entrepreneur in tech and a coding auto-didact. |
19:05:46 | FromDiscord | <scipio> I'm asking why there aren't any jobs in Nim if it's so good |
19:06:03 | FromDiscord | <scipio> I'm asking why there are like 40 half baked UI framework attempts |
19:06:10 | FromDiscord | <planetis> I had a summer job in nim last summer |
19:06:17 | FromDiscord | <jtv> I'm new to the community too. Great language, some helpful people, but in general, seems like it's not culturally geared toward giving engineers a good onramp. |
19:06:34 | FromDiscord | <pyolyokh> OK, the answer to that question is: no, Nim won't have a "nim ui" in the same way that V has a "v ui". This is an interesting difference between the two languages that I was interested to talk about above, and I think it's overshadowed by core competency as mentioned above.āµThe jobs question I don't care to talk about. |
19:06:36 | FromDiscord | <planetis> Will keep working for them when i find time |
19:06:42 | FromDiscord | <scipio> Nim is the product any dev would want to buy, you're approaching things from the other side, as if devs should kneel down and thank Nim for gracing them with its presence |
19:06:46 | FromDiscord | <jtv> It really seems to be a community issue, which has many facets. |
19:06:51 | FromDiscord | <scipio> It's borderline narcissistc to think like that |
19:07:33 | FromDiscord | <pyolyokh> No, narcissism is "wow I can't believe that my personal interest isn't the #1 priority of this community!" |
19:07:36 | FromDiscord | <planetis> What? ...does it meanāµ(@scipio) |
19:08:00 | FromDiscord | <nixfreak> I'm confused also |
19:08:50 | FromDiscord | <jtv> And that's exactly part of it, there's a lot of treating people like they need to catch up or get run over the bus, when generally good OSS projects are full of humility and grace. Not everyone is like that, but it's plenty. |
19:09:05 | FromDiscord | <scipio> In reply to @ambient "most OSS communities aren't": Exactly, my alma mater is on Eindhoven Tech University (tue.nl ). There's a computer club called Stack there. In 1995 when I was in my first year there at Industrial Management, you should have seen the types of people at Stack. And arguably those people are exceptionally good in writing working code, but not in devleoping products people actually want to use and become a huge success. |
19:10:05 | FromDiscord | <jtv> Oh yeah, I have a friend from Eindhoven, pretty sure he was in that computer club around that time frame. Rings a huge bell |
19:10:08 | FromDiscord | <nixfreak> If you want to support Nim , by the books, create something and publish it, help others. If you want a "GUI" library that you can use , then create it or start developing and show others why you think your GUI library will be the best? ... Its really easy to talk about this and talk about that but the end of the day its action. |
19:10:28 | FromDiscord | <planetis> Can't agree more with pyolyokh on that one. If you're an entrepreneur as you claim and won't get your hands dirty but want the community make libraries for free then whatever |
19:10:38 | FromDiscord | <scipio> In reply to @jtv "Oh yeah, I have": We created Ilse and later Vindex pre-Google. |
19:10:45 | FromDiscord | <ambient> here, go create Nim bindings for this https://github.com/rochus-keller/LeanQt š |
19:10:53 | FromDiscord | <planetis> I mean everyone has their goals.. I understand it but good luck |
19:11:04 | FromDiscord | <nixfreak> Talk is cheap |
19:11:37 | FromDiscord | <nixfreak> Create decent bindings for "Nuklear" gui library |
19:11:54 | FromDiscord | <scipio> In reply to @planetis "Can't agree more with": Apparently you completely misinterpret me or my intentions. Read back my chat history in here the past 3 days |
19:12:06 | FromDiscord | <jtv> And do you all even feel like you need to say anything negative, instead of appreciating that more people are here wanting to use Nim?? Seriously, might this person not have a day job? And if they intro Nim into it, might help it spread which will improve it? The whole, "participate or we're going to answer every question with 'you should be participating' is hardly welcoming. |
19:12:12 | FromDiscord | <cow> In reply to @nixfreak "Create decent bindings for": hell yeah nuklear seems so fun |
19:12:24 | FromDiscord | <nixfreak> I really like it |
19:12:46 | FromDiscord | <scipio> In reply to @nixfreak "If you want to": Having a decent thought provoking discussion is among that. It's highly needed I think |
19:13:04 | FromDiscord | <scipio> That doesnt mean I would like to trashtalk Nim, it's the exact opposite |
19:13:16 | FromDiscord | <scipio> I'm trying to figure out what's missing to turn it into a success |
19:13:18 | FromDiscord | <ambient> In reply to @scipio "Having a decent thought": Complaining that there are no great GUI libraries isn't exactly that š |
19:13:18 | FromDiscord | <nixfreak> but I can't create bindings to save my life and I would like to look for more tutorials on that to help out create cool bindings rather then complain about the "half-baked" repos out there. |
19:13:30 | FromDiscord | <scipio> What would make Rust and Go and FLutter devs join Nim |
19:13:31 | FromDiscord | <pyolyokh> sent a code paste, see https://paste.rs/p3j |
19:13:56 | FromDiscord | <nixfreak> I really like OwnKettle also |
19:14:01 | FromDiscord | <ambient> In reply to @scipio "What would make Rust": The biggest Rust GUI atm seems to be Tauri, which is just lets do Electron with Rust. It doesn't not fill me with joy |
19:14:04 | FromDiscord | <scipio> I also like Owlkettle |
19:14:06 | FromDiscord | <jtv> Well, Rust is pretty hard to write and master, Nim's the opposite. Go isn't a real systems language. |
19:14:14 | FromDiscord | <hector> In reply to @scipio "What would make Rust": Bribery? |
19:14:23 | FromDiscord | <ambient> (edit) "doesn't" => "does" |
19:14:37 | FromDiscord | <jtv> But Go's got a massive ecosystem, and that generally is a big advantage |
19:14:39 | FromDiscord | <ā¶ Zeno> sent a code paste, see https://paste.rs/aHx |
19:15:04 | FromDiscord | <hector> I'm still mad at Rob Pike. Or whoever told him to make Go |
19:15:10 | FromDiscord | <cow> In reply to @jtv "Well, Rust is pretty": many people just want statically compiled binaries with the impression that their language is "fast" |
19:15:11 | FromDiscord | <leetnewb> In reply to @jtv "But Go's got a": That's really the core of everything discussed here, right? Nim is a great language with a thin community. |
19:15:17 | FromDiscord | <ā¶ Zeno> (edit) "https://play.nim-lang.org/#ix=4l13" => "https://play.nim-lang.org/#ix=4l12" |
19:15:28 | FromDiscord | <ā¶ Zeno> (edit) "https://play.nim-lang.org/#ix=4l12" => "https://play.nim-lang.org/#ix=4l14" |
19:15:40 | FromDiscord | <jtv> Yeah, agreed, @cow. But MORE people don't gaf until it matters, which is why lack of performance never slowed down Python's adoption |
19:15:42 | FromDiscord | <nixfreak> sent a code paste, see https://paste.rs/FBA |
19:15:56 | FromDiscord | <pyolyokh> \`\`\`nimāµ\`\`\`āµto syntax-highlight |
19:16:09 | FromDiscord | <nixfreak> Hell I remember when python was hated |
19:16:28 | FromDiscord | <jtv> Yup, and my point about the Nim community is, the existing community is responsible for attracting the future community, and right now it's not doing a good job of that |
19:16:36 | FromDiscord | <jtv> I don't, and I first used it in 1994 š |
19:16:43 | FromDiscord | <nixfreak> How about a great GUI component library LCL (Lazarus Component Library) its created from Open Pascal. |
19:16:56 | FromDiscord | <cow> why do we even worry about adoption |
19:17:04 | FromDiscord | <nixfreak> good question |
19:17:08 | FromDiscord | <hector> "Avoid success at all costs" is a good motto |
19:17:12 | FromDiscord | <jtv> Well, it could be a non-goal. |
19:17:24 | FromDiscord | <scipio> In reply to @ambient "The biggest Rust GUI": https://media.discordapp.net/attachments/371759389889003532/1063174878255132752/image.png |
19:17:25 | FromDiscord | <pyolyokh> In reply to @leetnewb "That's really the core": the relevant thinness though is more documentation and direction. To the "v ui" vs. Nim's options, Nim would get 90% of the practical result of having a "v ui" nim-lang.org had a "want a GUI?" link to some discussion about what's available and some guidance on which to go for. |
19:17:37 | FromDiscord | <jtv> But for people trying to use it for real work, no ecosystem worth noting is a challenge |
19:17:40 | FromDiscord | <nixfreak> probably because of the "press" about a language ... lol stop looking at reddit, tickTok, twitter , youtube |
19:18:01 | FromDiscord | <pyolyokh> (edit) "In reply to @leetnewb "That's really the core": the relevant thinness though is more documentation and direction. To the "v ui" vs. Nim's options, Nim would get 90% of the practical result of having a "v ui" ... nim-lang.org" added "if" |
19:18:34 | FromDiscord | <nixfreak> It doesn't matter what language you use , because you need to spend a ton of time learning it if you want to do anything usefull |
19:18:37 | FromDiscord | <nixfreak> (edit) "usefull" => "useful" |
19:18:50 | FromDiscord | <scipio> In reply to @ambient "The biggest Rust GUI": Tauri is a lot more as just some webview wrapper. It has "sidecar" but Nim bindings are not high priority right now for Tauri and why would it? |
19:19:06 | FromDiscord | <nixfreak> lol I hate electron |
19:19:20 | FromDiscord | <jtv> The whole reason Python did so well is because it made it pretty EASY to do interesting stuff w/o a lot of programming experience |
19:19:27 | FromDiscord | <nixfreak> make system's slow and blah |
19:19:31 | FromDiscord | <jtv> And some of that was the syntax, but mostly it was the ecosystem |
19:19:47 | FromDiscord | <scipio> "Electron / Tauri" is primary aimed at JS frontend devs who want a better backend language as nodeJS |
19:19:48 | FromDiscord | <jtv> Lots and lots of modules in the standard libraries before there were package managers |
19:19:51 | FromDiscord | <cow> In reply to @jtv "And some of that": how did it get popular before its ecosystem existed though? |
19:19:55 | FromDiscord | <ambient> Python got big because of Numpy is 50% correct statement |
19:20:00 | FromDiscord | <cow> In reply to @jtv "Lots and lots of": ah okay yeah |
19:20:13 | FromDiscord | <nixfreak> python go adopted because of the "press it got it" from regular users |
19:20:32 | FromDiscord | <nixfreak> like "Watch me do this! in python" , Python is so easy to use ... |
19:20:46 | FromDiscord | <jtv> Yeah, I used Python 1.0 in 1994, and got tons and tons of people hooked on it |
19:20:56 | FromDiscord | <scipio> In reply to @jtv "The whole reason Python": Yup. And Python devs would IMHO be the #1 audience to port over to Nim. |
19:21:11 | FromDiscord | <nixfreak> what? |
19:21:22 | FromDiscord | <cow> and that would set the bar as low as having better UI thank tkinter š |
19:21:35 | FromDiscord | <nixfreak> I would C / C++ devs are more to follow Nim then python devs |
19:21:36 | FromDiscord | <jtv> IDK, I have done more C than Python in my career, it replaces both quite well for me |
19:21:47 | FromDiscord | <ambient> I don't really think this is the right way to think about things. It's not language A vs. language B zero-sum games. It's what tradeoffs are the best for your usecase and communicate them effectively. |
19:22:16 | FromDiscord | <scipio> In reply to @cow "and that would set": No. Because Pythonistas with an interest in UI have accepted to write html/css/js frontend BECAUSE Tkinter fucked up / isnt modern |
19:22:23 | FromDiscord | <jtv> But I cannot recommend it to anyone else. The people who I have raved about it to who checked it out think it's cool but no ecosystem, and won't adopt it for that reason |
19:22:47 | FromDiscord | <nixfreak> In reply to @scipio "No. Because Pythonistas with": What about all the other UI's you can use with python? |
19:22:52 | FromDiscord | <jtv> Anyone remember tcl? Tk was originally written in tcl |
19:23:09 | FromDiscord | <scipio> I'm also involved with the "Flet" https://flet.dev/ project and literally eveyr day new Python devs flow in. |
19:23:19 | FromDiscord | <nixfreak> wxPython, kivy, Qt, GTK, FLTK, EFL, etc.... |
19:23:29 | FromDiscord | <scipio> Flet is a JSON serialized declarative Flutter lib/framework, targeted at Python and/or other languages |
19:23:35 | FromDiscord | <hector> Don't worry people, our soon-to-be AI globalist overlords will handle all the nitty-gritty programming details anyway. |
19:23:46 | FromDiscord | <pyolyokh> there should really be a #python chat for all the discussion that's inevitably about it |
19:23:47 | FromDiscord | <nixfreak> I don't take about flutter |
19:23:51 | FromDiscord | <scipio> Why is Flet so successful? Because Python devs are STILL struggling with a decent Python UI |
19:23:54 | FromDiscord | <nixfreak> (edit) "take" => "care" |
19:24:24 | FromDiscord | <pyolyokh> although the meme would be, "what are your opinions on v?" -> "ask in #python" |
19:24:29 | FromDiscord | <nixfreak> Google promisses a lot and usually disappoints |
19:24:34 | FromDiscord | <hector> Former coder humans will be entertained by plugging in colored blocks to other colored blocks to get animated cats to move around |
19:24:35 | FromDiscord | <scipio> In reply to @nixfreak "What about all the": Can use? Or are actively being used? |
19:24:40 | FromDiscord | <ambient> Python has no GUIs? PyQt is fine. FastAPI is fine. |
19:24:55 | FromDiscord | <ā¶ Zeno> In reply to @ambient "Python has no GUIs?": since when was fastapi a gui- |
19:24:56 | FromDiscord | <Phil> At this point I've talked nearly as much about wanting to use nimqml than actually spend time learning qml, but that's basically what I'm looking into in that regard, particularly because I think the scope where nim-code matters is smaller and thus easier to achieve, so I have higher hopes. |
19:24:57 | FromDiscord | <nixfreak> What do you mean "has no gui's" |
19:25:09 | FromDiscord | <ambient> In reply to @ā¶ Zeno "since when was fastapi": Since when you could graphically use it as an interface |
19:25:23 | FromDiscord | <nixfreak> You mean "built-in" |
19:25:27 | FromDiscord | <ā¶ Zeno> confused screaming |
19:25:42 | FromDiscord | <ā¶ Zeno> how does one use a webserver |
19:25:45 | FromDiscord | <ā¶ Zeno> as gui |
19:25:56 | FromDiscord | <nixfreak> what lol |
19:26:09 | FromDiscord | <pyolyokh> In reply to @ā¶ Zeno "how does one use": you make it serve HTML pages. A form that hits CGI, or a little bit of JS, and you've got an application. |
19:26:33 | FromDiscord | <ā¶ Zeno> yea that would make sense, i was more of confused at wording |
19:27:54 | FromDiscord | <Phil> In reply to @ā¶ Zeno "how does one use": Easy, you make the frontend a PWA and make it installable. Then you provide a script to "install" the webserver and let it all run over localhost, boom |
19:28:18 | FromDiscord | <ā¶ Zeno> sir yes sir |
19:28:22 | FromDiscord | <scipio> In reply to @pyolyokh "you make it serve": this is what I've been doing myself with Python (Flask) for desktop apps |
19:28:49 | FromDiscord | <scipio> In reply to @pyolyokh "you make it serve": i.e. (as I dropped in here yesterday): https://media.discordapp.net/attachments/371759389889003532/1063177748027289701/image.png |
19:29:04 | FromDiscord | <Phil> ~~What I just proposed may not be a good install experience, but a functional one~~ |
19:29:32 | FromDiscord | <scipio> In reply to @pyolyokh "you make it serve": one issue however, is this app's "Charting engine", which I'n still developing (in KonvaJS, using canvas) |
19:29:39 | FromDiscord | <pyolyokh> sent a long message, see https://paste.rs/cbh |
19:30:13 | FromDiscord | <ambient> In reply to @pyolyokh "some fun things about": How did you do the sqlite static linking part? |
19:30:39 | FromDiscord | <ambient> I've been meaning to look into it |
19:31:13 | FromDiscord | <Phil> In reply to @scipio "i.e. (as I dropped": Touch UI? |
19:31:41 | FromDiscord | <guttural666> In reply to @jtv "Yeah, I used Python": sounds like heroin |
19:31:42 | FromDiscord | <scipio> Just clicks and bindings to an Elgato StreamDeck |
19:31:51 | FromDiscord | <scipio> @Phil |
19:31:59 | FromDiscord | <pyolyokh> sent a code paste, see https://play.nim-lang.org/#ix=4l1a |
19:32:11 | FromDiscord | <pyolyokh> with sqlite3.c sqlite3ext.h sqlite3.h in the directory |
19:33:01 | FromDiscord | <Phil> In reply to @scipio "<@180601887916163073>": Ahhhh, streamdeck explains the button size |
19:33:32 | FromDiscord | <Phil> The shape just looked odd to me for general design so I was puzzling over what made it necessary, so my first assumption was this was for a touch surface for easy tapping |
19:34:15 | FromDiscord | <scipio> In reply to @Isofruit "Touch UI?": it's a multi-exchange trading app, and the UI concept I created here is to eliminate human typing for order processing |
19:34:30 | FromDiscord | <pyolyokh> In reply to @ambient "How did you do": ... and I just realized that ringabout ripped all of that out, so it's not as easy anymore |
19:35:10 | FromDiscord | <scipio> In reply to @Isofruit "Ahhhh, streamdeck explains the": https://media.discordapp.net/attachments/371759389889003532/1063179349051846746/image.png |
19:35:18 | FromDiscord | <pyolyokh> that was a 6Dec2022 commit, so maybe by the time it's released you'll be able to get the same thing from nimble |
19:35:58 | FromDiscord | <Phil> In reply to @scipio "": So it's fully reliant on clicking with a mouse as the usecase I assume |
19:37:45 | FromDiscord | <scipio> In reply to @Isofruit "So it's fully reliant": No, this is just one frontend (html, css, js) module you're seeing here, the current backend is Python Flask & Dask (= distributed parallel Pandas, Numpy, Scipy, etc), i.e. there's a backend process connected to both the frontend and various exchange backend websockets assisting / computing. |
19:38:37 | FromDiscord | <Phil> In reply to @scipio "No, this is just": I wasn't talking about the backend at all so far, just about the frontend and what it's primary mode of interaction are |
19:38:50 | FromDiscord | <Phil> Which I thiiiiiiiink is clicking with a mouse? |
19:39:19 | FromDiscord | <scipio> this module here is for order processing (LB = limit buy, LS = Limit Sell, MB = Market buy, Amend = order ladder offsetting/shifting for batch orders etc) |
19:39:21 | FromDiscord | <Phil> Wait no, streamdeck is like a button thing that this is for |
19:39:50 | FromDiscord | <scipio> I use the streamdeck version as a secondary "controller" doing the same thing |
19:39:58 | FromDiscord | <Phil> So button pressing based? |
19:40:01 | FromDiscord | <scipio> both |
19:40:12 | FromDiscord | <Phil> Check |
19:41:03 | FromDiscord | <nixfreak> To make a true nim based UI framework you would have to create with on bindings only using nim to create the core components |
19:41:30 | FromDiscord | <nixfreak> (edit) "on" => "no" |
19:42:04 | FromDiscord | <Phil> Actually, might make sense to move this to offtopic |
19:42:11 | FromDiscord | <Phil> We're talking about a product and UI Experience, not nim code |
19:42:22 | FromDiscord | <cow> In reply to @nixfreak "To make a true": that's an immense task |
19:42:31 | FromDiscord | <nixfreak> I know |
19:42:45 | FromDiscord | <scipio> So, let's take this as a Nim app use case for a moment ...āµ- I could in essence replace the Python backend with Nim and drop in Nimviewāµ- or rewrite some components with faster Nim binariesāµ- but if I'd want to include a live realtime charting engine with Nim UI too, then how to proceed? |
19:42:47 | FromDiscord | <ambient> In reply to @cow "that's an immense task": eh.. https://github.com/rxi/microui |
19:42:56 | FromDiscord | <Phil> ~~The only reason Iced is getting there is out of System76's spite for gnome~~ |
19:43:16 | FromDiscord | <jtv> Generally, Nim's got a decent foreign function interface |
19:43:55 | FromDiscord | <jtv> So it depends on what language, but you could incorporate something in C++, C or JavaScript super easily, and things like Go aren't too hard |
19:44:48 | FromDiscord | <Phil> In reply to @ambient "eh.. https://github.com/rxi/microui": Without having any decent knowledge about it, one hard thing that are the main reason why imo bindings are preferrable over rewrites are accessibility features |
19:45:12 | FromDiscord | <nixfreak> The library expects the user to provide input and handle the resultant drawing commands, it does not do any drawing itself. |
19:45:13 | FromDiscord | <ambient> In reply to @Isofruit "Without having any decent": Yes, the corner cases and OS integration are 99.999% of the work |
19:45:26 | FromDiscord | <scipio> In reply to @Isofruit "~~The only reason Iced": Iced: HĆ©ctor RamĆ³n main dev, Artur Sapek Kraken tech lead, main product https://cryptowat.ch/ (however, the crypto watch code is NOT open sourced / included in Iced) |
19:45:30 | FromDiscord | <cow> In reply to @nixfreak "The library expects the": it's immediate mode GUI |
19:45:35 | FromDiscord | <nixfreak> yep |
19:45:53 | FromDiscord | <nixfreak> Just like nuklear now |
19:45:57 | FromDiscord | <jtv> Agreed, would love to have a lot more mature, well documented wrappings of important software |
19:46:00 | FromDiscord | <scipio> and egui in Rust |
19:46:00 | FromDiscord | <nixfreak> and nanoVG |
19:47:15 | FromDiscord | <sealmove> could it make sense in some context to export an object's field but not the object type itself? |
19:48:08 | FromDiscord | <scipio> To round this (interesting, to me at least) discussion off for now: what I think is Nim's main issue, is that it tries to solve a lot of stuff instead of focusing on something specific. I couldn't easily define in one sentence the Nim's USP vs other languages. āµāµ==> if you'd try to "pitch" to somebody "Why Nim??, what would you answer? |
19:48:45 | FromDiscord | <ambient> Well, give me alternative for: fast exploratory programming that generates fast executables |
19:48:58 | FromDiscord | <scipio> Slower than V |
19:49:02 | FromDiscord | <scipio> Next attempt? |
19:49:05 | FromDiscord | <scipio> š |
19:49:13 | FromDiscord | <jtv> Well, it's the best of C and Python, without their downsides as languages, with some amazingly useful bits like its macro system. |
19:49:28 | FromDiscord | <ambient> V has effortless C and C++ FFI? |
19:49:38 | FromDiscord | <nixfreak> No not really |
19:49:42 | FromDiscord | <nixfreak> just like Zig |
19:50:02 | FromDiscord | <ambient> curly braces violate the DRY principle |
19:50:06 | FromDiscord | <ā¶ Zeno> sent a long message, see http://ix.io/4l1g |
19:50:23 | FromDiscord | <scipio> In reply to @ambient "V has effortless C": That could be an angle for Nim, but then a better language name would be GLUE |
19:50:35 | FromDiscord | <ā¶ Zeno> (edit) "http://ix.io/4l1g" => "http://ix.io/4l1h" |
19:50:44 | FromDiscord | <nixfreak> what ? |
19:51:13 | FromDiscord | <nixfreak> Ok , lets take all of this #offtopic |
19:51:31 | FromDiscord | <cow> In reply to @scipio "Slower than V": doesn't V leak memory |
19:53:02 | FromDiscord | <pyolyokh> In reply to @cow "doesn't V leak memory": it doesn't do that inherently; it links with boehmgc for garbage collection. That might be a relatively recent change: one of the updates is "V no longer leaks memory". |
19:55:05 | FromDiscord | <pyolyokh> the memory management picture and the array index=int=32bits are my go-tos for explaining why I think v's development has a core-language weakness to go with its outside-language (v ui, tooling, etc.) energy |
19:56:04 | * | jjido joined #nim |
19:56:22 | * | deadmarshal_ quit (Quit: IRCNow and Forever!) |
20:17:46 | * | deadmarshal_ joined #nim |
20:33:56 | FromDiscord | <scipio> In reply to @pyolyokh "the memory management picture": If you invert this statement, you could distill Nim's strengths from it |
20:35:18 | FromDiscord | <pyolyokh> I think those are pretty generic strengths, or rather v is exceptionally poor here. |
20:36:39 | FromDiscord | <pyolyokh> D, Odin, Zig, Nim, even Go - they all get the basic stuff right. At the core they're all decent languages that you could probably live with. Nim's strengths vs. this group are more subtle. |
20:37:54 | FromDiscord | <pyolyokh> <https://nim-lang.org/blog/2022/11/11/a-cost-model-for-nim.html> and the like. |
20:46:09 | * | deadmarshal_ quit (Quit: IRCNow and Forever!) |
20:55:51 | * | dv^_^ quit (Remote host closed the connection) |
21:09:39 | * | deadmarshal_ joined #nim |
21:24:53 | FromDiscord | <deech> In reply to @scipio "To round this (interesting,": I gave a talk on just that: https://www.youtube.com/watch?v=d2VRuZo2pdA |
21:25:59 | FromDiscord | <Elegantbeef> What?āµ(@scipio) |
21:26:22 | FromDiscord | <Elegantbeef> In what world is Nim objectively slower than V? |
21:26:36 | FromDiscord | <scipio> In reply to @deech "I gave a talk": Oh hi! I literally watched your talk yesterday! Nice to meet you! |
21:27:13 | FromDiscord | <deech> In reply to @scipio "Oh hi! I literally": š Hope you liked it! |
21:27:21 | FromDiscord | <scipio> I did! A lot! |
21:27:49 | FromDiscord | <scipio> But I wouldn't per se distill an answer from that on the question I posed what would be Nim's USP |
21:27:53 | FromDiscord | <scipio> a glue language maybe? |
21:28:15 | FromDiscord | <Elegantbeef> A modern system programming language that is ergonomic and fast |
21:28:59 | FromDiscord | <pyolyokh> this "Nim has good FFI so it can do the FFI for another language like V" take is very, very strange. |
21:29:29 | FromDiscord | <Elegantbeef> Well the whole "V is faster than Nim" is a dumb take |
21:29:33 | FromDiscord | <scipio> Still, my question is left unanswered @ElegantBeef , and it's a serious question; what UI solution I should use if I wanted to code something like CryptoWatch Desktop with Nim only |
21:29:41 | FromDiscord | <scipio> @deech how would you? |
21:30:01 | FromDiscord | <scipio> https://media.discordapp.net/attachments/371759389889003532/1063208249375076443/image.png |
21:30:34 | FromDiscord | <scipio> this uses Iced btw, and Kraken Exchange (the owner of CryptoWatched) is also the main sponsor of Iced for Rust |
21:30:51 | FromDiscord | <scipio> (edit) "CryptoWatched)" => "CryptoWatch)" |
21:31:04 | FromDiscord | <pyolyokh> the good FFI lets you write code in Nim. To make the code available to another language you'd have to target the C ABI and you may as well have written a C++ header file (cor C++) and have used whatever language's C FFI. This is not a good use of Nim, you can show that by just trying it. |
21:32:20 | FromDiscord | <deech> @scipio I'm working on some GUI bindings right now. Repo's private until it's somewhat more that half baked. They are native (no Chrome runtime) and will for sure work seamlessly on Win/Lin/MacOS but no mobile support is planned. |
21:32:52 | FromDiscord | <scipio> In reply to @deech "<@376004371256836096> I'm working on": extremely interested! |
21:33:08 | FromDiscord | <deech> (edit) "that" => "than" |
21:36:25 | FromDiscord | <scipio> In reply to @pyolyokh "this "Nim has good": I've literally spent 3 days on the Nim ecosystem. I'm trying to assess how usable it could be commercially. Having no battle-hardened UI framework and seeing no job market on Nim after years, raises questions for me. āµYou only seem to approach it from a technical perspective; I take a multidimensional stance on it. |
21:37:18 | FromDiscord | <pyolyokh> What I have are things I'm interested in talking about and things I'm not interested in talking about, rather than a particular perspective. |
21:38:01 | FromDiscord | <scipio> Yet you immediately label me suggesting things as "strange". Not very openminded imho |
21:38:20 | FromDiscord | <pyolyokh> No, I said that that particular take was strange. You clearly haven't thought it through. |
21:38:25 | FromDiscord | <scipio> LOL |
21:38:29 | FromDiscord | <scipio> Okay |
21:38:51 | FromDiscord | <deech> There is no Nim job market except possibly Status. I wouldn't expect to see one for a long time if at all. So still definitely in hobbyist bucket. |
21:38:53 | FromDiscord | <scipio> You'[d be amazed what I think through but I'm not interested in a pissing contest, I've nothing to prive |
21:38:56 | FromDiscord | <scipio> (edit) "prive" => "prove" |
21:39:02 | FromDiscord | <Elegantbeef> I'm still stuck on "V is faster than Nim" |
21:39:13 | FromDiscord | <pyolyokh> "Nim has good FFI", "can Nim do the FFI for V?" are not questions you've put a lot of thought into. |
21:39:23 | FromDiscord | <Elegantbeef> As bad as V is they're both system languages so the speed is generally on the driver |
21:39:34 | FromDiscord | <scipio> In reply to @Elegantbeef "I'm still stuck on": I was referring to compile times and it's listed as such on the V website too |
21:39:48 | FromDiscord | <Elegantbeef> Ok but vlang lies on their speeds |
21:39:52 | FromDiscord | <scipio> In reply to @Elegantbeef "As bad as V": Why is V bad? |
21:39:56 | FromDiscord | <Elegantbeef> And also uses an arbitrary benchmark |
21:40:09 | FromDiscord | <Elegantbeef> They compare to C using gcc vs vlang + tcc |
21:40:14 | * | rockcavera joined #nim |
21:40:42 | FromDiscord | <scipio> In reply to @deech "There is no Nim": You'd say any CIO watching your Nim talk would get enthusiastic |
21:40:44 | FromDiscord | <pyolyokh> eh, V's compiletimes slow down a great deal with -prod, and if you set up Nim to use tcc like v does by default it'd probably be competitive. But yes the normal v experience has fast compilation. |
21:40:44 | FromDiscord | <scipio> I am |
21:41:02 | * | tiorock joined #nim |
21:41:02 | * | tiorock quit (Changing host) |
21:41:02 | * | tiorock joined #nim |
21:41:02 | * | rockcavera is now known as Guest9845 |
21:41:02 | * | tiorock is now known as rockcavera |
21:41:09 | FromDiscord | <scipio> Then why is there no job market? |
21:41:17 | FromDiscord | <deech> In reply to @scipio "You'd say any CIO": I would? š I honestly have no idea what a CIOs thought process is. |
21:41:55 | FromDiscord | <Elegantbeef> A lot of vlang was built on a promise that didnt exist, "There is no GC and no leaks" was a big thing the touted early on |
21:41:55 | FromDiscord | <Elegantbeef> It still hasnt come to fruition afaik |
21:41:59 | * | tiorock joined #nim |
21:41:59 | * | tiorock quit (Changing host) |
21:41:59 | * | tiorock joined #nim |
21:41:59 | * | rockcavera quit (Killed (tantalum.libera.chat (Nickname regained by services))) |
21:41:59 | * | tiorock is now known as rockcavera |
21:42:11 | FromDiscord | <pyolyokh> CTO thought process is "I want this tech stack", and languages are a distraction. You don't want different kinds of lego brands, you want a whole toy. |
21:42:32 | FromDiscord | <scipio> For example, I'm friends with Anatoly Yakovenko, the Solana Labs founder, a Rust advocate. Solana being a successful crypto project, an ETH challenger, built with Rust, has definitely generated a lot of attention to Rust itself. Such a driver could also spark Nim attention, yet there isn't one/ Why not? |
21:43:23 | FromDiscord | <planetis> There isn't one? Better check your sources first. there is nimbus |
21:43:28 | FromDiscord | <deech> AFAICT Nim's only major use is in the crypto space so it's already there. |
21:44:38 | FromDiscord | <scipio> In reply to @deech "I would? š I": I think there are a ton of companies struggling with their legacy C/C++ systems in need of constant patching that a language like Nim (with its meta programming facilities and cross-transpiling) would solve immediatelyāµIn this regard the 2 things I'm asking myself are the above (-1- why no solid market adoption yet for Nim?) as well as "-2- why is there no "de facto / standard" UI framework for Nim |
21:44:40 | FromDiscord | <deech> That's not a space I'm personally interested in so I don't have any more info on why it hasn't penetrated deeper. |
21:44:43 | * | Guest9845 quit (Ping timeout: 248 seconds) |
21:44:58 | FromDiscord | <enthus1ast> crypto space and malware š |
21:45:25 | FromDiscord | <scipio> "Red Team Offensive Security", sure |
21:45:50 | * | tiorock joined #nim |
21:45:50 | * | tiorock quit (Changing host) |
21:45:50 | * | tiorock joined #nim |
21:45:50 | * | rockcavera is now known as Guest9985 |
21:45:51 | * | Guest9985 quit (Killed (sodium.libera.chat (Nickname regained by services))) |
21:45:51 | * | tiorock is now known as rockcavera |
21:45:56 | FromDiscord | <scipio> In reply to @deech "That's not a space": If Nim "glues" so easily, why not ML/AI / data science hopping on the Python toolchain? |
21:46:22 | FromDiscord | <scipio> i.e. https://www.dask.org/ |
21:46:24 | FromDiscord | <deech> Good q, no idea. Does seem like a natural fit. |
21:46:50 | FromDiscord | <deech> Marketing? I'm frequently the only one in a group who's even heard of it. |
21:47:40 | FromDiscord | <auxym> zig does seem to have strong marketing compared to nim |
21:47:42 | FromDiscord | <scipio> If a language has no de facto UI framework, but rather 30 half-baked competing or abandoned repos, and zero tutorials, the entry barrier is raised higher and higher to even try it |
21:49:03 | FromDiscord | <pyolyokh> "hey guys, if you just cared about this one thing that's coincidentally something I'm interested in, you would see these wholly unrelated benefits: jobs, marketing" |
21:49:55 | FromDiscord | <enthus1ast> a good ui for nim would still be good, i think @scipio is right here |
21:50:14 | FromDiscord | <scipio> In reply to @deech "Marketing? I'm frequently the": Do you know https://flet.dev/ ? It's JSON serialized Flutter piped to Python (as first SDK). Feodor Fitsner created it, I'm active with it too.āµāµLiterally daily we get new people in the Discord |
21:50:15 | FromDiscord | <pyolyokh> of course it would be good. Lots of things would be good. It is not the thing. |
21:50:38 | FromDiscord | <scipio> https://media.discordapp.net/attachments/371759389889003532/1063213441025851412/image.png |
21:50:55 | FromDiscord | <ambient> is there any language outside javascript that in any way fills the desktop GUI demand outside the native Windows and Apple development tools? |
21:51:01 | FromDiscord | <deech> Depending how what "good" means the bar is so high that you probably need company backing. Bindings are possible but they'll always feel foreign. |
21:51:05 | FromDiscord | <ambient> I mean, it's either Electron, Qt or the native tools |
21:51:26 | FromDiscord | <deech> (edit) removed "how" |
21:51:32 | FromDiscord | <scipio> I suspect it's devs liking the Python toolchain, not versed enough for PySide6 / Qt or Flutter/Dart, looking for a decent easy modern Python UI |
21:51:33 | FromDiscord | <enthus1ast> dearimgui |
21:52:07 | FromDiscord | <scipio> i.e. a clear UI framework is absolutely essential for a language's success |
21:52:34 | FromDiscord | <scipio> ==> if Nim solves this whole, I predict a massive influx of Python devs into the Nim ecosystem |
21:52:40 | FromDiscord | <ambient> only clear UI framework is Qt, Windows or Apple. I don't see how that's connected to language |
21:53:28 | FromDiscord | <pyolyokh> In reply to @deech "Depending what "good" means": documentation's always more of an issue with bindings than any foreign feel. People don't like having to look up docs in the original project, to see how to do things with the binding. Tcl/Tk's an example that came up earlier, and there you had whole O'Reilly books on how to do things entirely from the perspective of "Perl/tk" and later Tkinter. Tcl? implementation detail, don't worry a |
21:53:40 | FromDiscord | <enthus1ast> with an ui framework you can write/sell software for consumers |
21:54:32 | FromDiscord | <scipio> A UI framework allows for schools to teach the language as it gives immediate feedback |
21:54:39 | FromDiscord | <scipio> See the success of Processing / P5.js |
21:54:45 | FromDiscord | <pyolyokh> In reply to @scipio "==> if Nim solves": thanks for at least being very direct with these predictions. That's not the norm. |
21:55:03 | FromDiscord | <ambient> Processing is not a UI framework |
21:55:57 | FromDiscord | <scipio> In reply to @pyolyokh "thanks for at least": Thanks too. I guess we both have disjunct competences and yours probably isn't with business or social skills. I told you already I'm not interested in a pissing contest. But don't push me. Understood? |
21:56:11 | FromDiscord | <scipio> I'/m extremely friendly yet asking questions that need answering |
21:56:14 | FromDiscord | <pyolyokh> In reply to @scipio "Thanks too. I guess": No, go fuck yourself. |
21:56:25 | FromDiscord | <scipio> š |
21:56:33 | FromDiscord | <ShalokShalom> In reply to @ambient "is there any language": https://medium.com/swlh/what-makes-godot-engine-great-for-advance-gui-applications-b1cfb941df3b |
21:56:41 | FromDiscord | <ShalokShalom> I am going to use it with Kotlin |
21:56:50 | FromDiscord | <ambient> In reply to @ShalokShalom "https://medium.com/swlh/what-makes-godot-engine-gre": Ok you got me there, I forgot |
21:57:41 | FromDiscord | <ambient> But why Kotlin/Godot? š¤ |
21:57:42 | FromDiscord | <enthus1ast> the godot team looked at nim a few years ago to adopt for godot (instead of gdscript) |
21:57:55 | FromDiscord | <enthus1ast> or in addition |
21:57:59 | FromDiscord | <scipio> In reply to @pyolyokh "No, go fuck yourself.": I honestly don;t know which nerve I struck. I don't care either. You do you. |
21:58:00 | FromDiscord | <ambient> In reply to @enthus1ast "the godot team looked": What did they think? |
21:58:16 | FromDiscord | <ShalokShalom> In reply to @ambient "But why Kotlin/Godot? š¤": Cause Kotlin is good supported |
21:58:16 | FromDiscord | <ShalokShalom> Godot 4 create a new API |
21:58:17 | FromDiscord | <ShalokShalom> Its either Haxe or Kotlin |
21:58:26 | FromDiscord | <pyolyokh> In reply to @scipio "I honestly don;t know": You're genuinely surprised that "But don't push me. Understood?" got a hostile response? |
21:58:38 | FromDiscord | <enthus1ast> @ambient\: no i guess |
21:58:51 | FromDiscord | <scipio> In reply to @pyolyokh "You're genuinely surprised that": Nope, not surprised. Yet you seem to be |
21:59:24 | FromDiscord | <auxym> In reply to @ambient "is there any language": rust has a lot of seemingly pretty good GUI options, eg. slint and druid |
21:59:48 | FromDiscord | <scipio> In reply to @pyolyokh "You're genuinely surprised that": I'm talking about the cause of your passive-agressive lead-up to that. |
21:59:55 | FromDiscord | <ambient> In reply to @auxym "rust has a lot": As far as I'm aware all of these are very immature and none were used to create any big & popular application |
22:00:00 | FromDiscord | <Elegantbeef> Children children it'll be ok |
22:00:21 | FromDiscord | <scipio> In reply to @auxym "rust has a lot": Druid development is pretty much absent, I think its founder is working on a new repo |
22:00:27 | FromDiscord | <ShalokShalom> Daddy solves this |
22:01:14 | FromDiscord | <pyolyokh> In reply to @scipio "I'm talking about the": ah, that's much more easily explained. People do this bit all the time. "I predict that if Nim has a first class [random thing I care about] library that people will pour in.", but they are less direct. They don't the prediction, but instead leave it unstated while talking up how a much more popular language (python) has the thing they want. |
22:01:26 | FromDiscord | <pyolyokh> (edit) "In reply to @scipio "I'm talking about the": ah, that's much more easily explained. People do this bit all the time. "I predict that if Nim has a first class [random thing I care about] library that people will pour in.", but they are less direct. They don't ... the" added "state" |
22:02:20 | FromDiscord | <sealmove> Is it possible to configure testament to use nimcache and not bloat project dir with compiled test modules? |
22:02:31 | FromDiscord | <pyolyokh> Someone honestly saying "I would like this thing", I like. Someone saying "Nim will jump five points on the TIOBE index if it has this thing." is at least a nice alternative. The norm gets old. |
22:03:04 | FromDiscord | <scipio> In reply to @pyolyokh "ah, that's much more": What you don't seem to be understanding, is that I am _not_ your enemy. I'd love Nim to succeed. It's a fact it doesnt have a job market right now, and it's been around for years. Why is there no demand? I'm asking those questions and looking for solutions. The questions I might ask via hypotheses which you seem to take personally. Don't. Won't end well, nor is it needed. I'd like Nim to succ |
22:03:35 | FromDiscord | <auxym> I'm not convinced data science and co is really the killer app compared to python. dynamic features and REPL are a real nice-to-have in that space IMO |
22:04:47 | FromDiscord | <pyolyokh> There are Nim kernels for Jupyter, which is the best thing in that space, and there's stuff like Arraymancer. |
22:04:54 | FromDiscord | <Elegantbeef> I mean python took how many years to take off |
22:05:15 | FromDiscord | <Elegantbeef> A language without massive corporate backing is in an uphill struggle |
22:05:19 | FromDiscord | <Elegantbeef> Look at Dlang |
22:05:40 | FromDiscord | <ambient> In reply to @pyolyokh "There are Nim kernels": The problem is that the entire notebook is compiled as a single file, so any change = full recompile |
22:05:44 | FromDiscord | <pyolyokh> and while python was eating perl's lunch, nobody knew ML would be the final rocket to strap to it. Early days had bioinformatics, maybe. |
22:08:32 | FromDiscord | <Elegantbeef> Yea i mean julia didnt explode |
22:08:52 | FromDiscord | <Elegantbeef> It's ostensibly a 'better python' |
22:10:05 | FromDiscord | <Elegantbeef> But then again i dont see the value in a 'better python' cause python is generally shit |
22:10:05 | FromDiscord | <jos> is there a macro that can clean up something like this? |
22:10:15 | FromDiscord | <jos> sent a code paste, see https://play.nim-lang.org/#ix=4l1X |
22:10:21 | FromDiscord | <jos> i want something more like `B(a: A())` |
22:10:29 | FromDiscord | <jos> (edit) "i want something more like `B(a: ... A())`" added "addr" |
22:10:36 | FromDiscord | <jos> like u can do in C |
22:10:53 | FromDiscord | <jos> `B { a: &A() {} }` works in C and rust |
22:11:02 | FromDiscord | <jos> so declaring big literals of nested objects is nice |
22:11:14 | FromDiscord | <jos> but in nim A() doesn't have an address yet |
22:12:23 | FromDiscord | <Elegantbeef> I can see dangling pointers in your future |
22:12:34 | FromDiscord | <jos> its a c ffi |
22:12:38 | FromDiscord | <jos> with some really large structs |
22:12:48 | FromDiscord | <jos> i just need an easier way to edit them |
22:12:53 | FromDiscord | <pyolyokh> In reply to @jos "is there a macro": not a macro, but you can do `B(a: (ref A)())` |
22:13:05 | FromDiscord | <Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=4l1Z |
22:13:11 | FromDiscord | <Elegantbeef> Works but again i dont know why you're using `addr a` |
22:13:29 | FromDiscord | <jos> it's because it's a c ffi, is there another way to pass a ptr? |
22:13:46 | FromDiscord | <pyolyokh> sent a code paste, see https://play.nim-lang.org/#ix=4l20 |
22:14:10 | FromDiscord | <Elegantbeef> `ref T` is compatible with `T` assuming you understand the GC implications |
22:14:20 | FromDiscord | <Elegantbeef> But nope there is not another way to get a pointer to stack |
22:14:34 | FromDiscord | <Elegantbeef> I'm just weary of anyone storing a pointer to a stack value in Nim |
22:15:14 | FromDiscord | <jos> the c func won't hold any refs to it, it's a guarantee |
22:15:25 | FromDiscord | <jos> sent a code paste, see https://play.nim-lang.org/#ix=4l21 |
22:15:39 | FromDiscord | <jos> In reply to @Elegantbeef "`ref T` is compatible": i actually can't get this to work for some reason |
22:16:12 | FromDiscord | <jos> https://media.discordapp.net/attachments/371759389889003532/1063219871971803228/image.png |
22:16:33 | FromDiscord | <deech> In reply to @scipio "What you don't seem": I really like GUI apps but I'm not sure where you see non-web GUI's being a blocker for adoption in this day and age. |
22:16:34 | FromDiscord | <Elegantbeef> Well i mean you need to `cast[ptr T](myRef)` |
22:16:44 | FromDiscord | <jos> oh i see |
22:16:51 | FromDiscord | <jos> well for me the whole point is to clean up the declarations |
22:16:54 | FromDiscord | <jos> so i can actually read them |
22:17:01 | FromDiscord | <jos> what it does under the hood doesn't really matter that much to me actually |
22:17:04 | FromDiscord | <deech> (edit) "In reply to @scipio "What you don't seem": I really like GUI apps but I'm not sure where you see ... non-webGUI" added "lack of" | "GUI's" => "GUI frameworks" |
22:17:04 | FromDiscord | <Elegantbeef> Well there is no way to clean this up really |
22:17:22 | FromDiscord | <jos> i was hoping there might be a macro or something already since i think this is pretty common for c ffis |
22:17:39 | FromDiscord | <Elegantbeef> There isnt any reason for a macro |
22:17:52 | FromDiscord | <jos> i have a lot of these and i edit them directly, i want them to be readable |
22:17:58 | FromDiscord | <jos> some of them are 20-30 lines long |
22:18:00 | FromDiscord | <scipio> In reply to @deech "I really like GUI": speed? with having an html/css/js frontend, the backend/midend message communication becomes a bottleneck. as well as no fullstack approach in one language |
22:18:45 | FromDiscord | <pyolyokh> I imagine the thought process isāµ1. I could clean this up with a procāµ2. but a proc would have its own stackāµ3. I could use a macro to put that logic in the caller so that the objects will live on the caller's stack |
22:18:47 | FromDiscord | <deech> In reply to @scipio "speed? with having an": I mean which business domain actually wants this? |
22:19:26 | FromDiscord | <jos> mmmm i can actually just do it with a proc i think |
22:19:32 | FromDiscord | <jos> and a closure |
22:19:56 | FromDiscord | <Elegantbeef> Let's make something simple, much more complex |
22:19:57 | FromDiscord | <deech> (edit) "this?" => "this enough that would justify the effort." |
22:20:05 | FromDiscord | <Elegantbeef> What's your entire code |
22:21:05 | FromDiscord | <Elegantbeef> if you share an image, i swear i'm sending a rocket to your house |
22:21:26 | FromDiscord | <scipio> In reply to @deech "I mean which business": let me flip that question: why would Google spend so much effort on developing and branding Flutter/Dart? |
22:22:08 | FromDiscord | <scipio> Flutter 3 isn't just targeting mobile but also Desktop |
22:22:15 | FromDiscord | <scipio> macOS, Windows |
22:23:41 | FromDiscord | <scipio> Firebase monetization? By deliberately not focusing on Dart low level? |
22:24:13 | FromDiscord | <scipio> Streaming UI as a service? |
22:24:41 | FromDiscord | <deech> In reply to @scipio "let me flip that": So, a unified API for mobile+web+desktop is a huge selling point but it takes Google resources to pull it off. No niche language community can hope to pull that off, it's hard enough to maintain even bindings. |
22:26:25 | FromDiscord | <deech> (edit) "pull that off," => "compete," |
22:27:25 | FromDiscord | <scipio> @deech off-topic, but when Google was still called Backrub I was on the losing end in web search competing with it. Stanford vs TU/Eindhoven |
22:27:30 | FromDiscord | <ShalokShalom> In reply to @scipio "let me flip that": Market dominance |
22:27:57 | FromDiscord | <!!sharpcdf!!> how can i use `walkDirRec` to copy files, following and copying folder too? |
22:27:58 | FromDiscord | <ShalokShalom> https://blog.bencope.land/flutter-state-in-f-with-fable-and-redux/ |
22:28:11 | FromDiscord | <ShalokShalom> In case you love to build a Flutter app |
22:28:24 | FromDiscord | <scipio> Well it's not that off-topic giving it some more thought. |
22:28:26 | FromDiscord | <!!sharpcdf!!> (edit) "how can i use `walkDirRec` to copy files, following and copying folder too? ... " added "ive tried using `copyFileToDir` but it just copies them all to the same dir" |
22:28:47 | FromDiscord | <Elegantbeef> if you dont need a filter `copyDir` existsāµ(@!!sharpcdf!!) |
22:28:53 | FromDiscord | <scipio> If something is novel enough, like chatGPT or stable diffusion the world can be taken by storm |
22:29:14 | FromDiscord | <ShalokShalom> You overthink this |
22:29:21 | FromDiscord | <ShalokShalom> Look how many employees they have |
22:29:30 | FromDiscord | <Elegantbeef> What are you after sharp |
22:29:36 | FromDiscord | <scipio> Back then it was just Brin and Page vs us two |
22:29:40 | FromDiscord | <ShalokShalom> Companies like Google allocate their resources different |
22:29:41 | FromDiscord | <scipio> I'm talking 1996 |
22:29:50 | FromDiscord | <ShalokShalom> They dont care about a small team like Flutter |
22:29:59 | FromDiscord | <ShalokShalom> For them, its an experiment |
22:30:33 | FromDiscord | <Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=4l26 |
22:30:36 | FromDiscord | <ShalokShalom> That's petty cash to them |
22:30:41 | FromDiscord | <deech> @scipio When my thing is in better shape I'll announce it and tag you here if you're still around. If you feel that strongly about GUI I wouldn't mind the help. |
22:30:47 | FromDiscord | <!!sharpcdf!!> In reply to @Elegantbeef "if you dont need": oh snap i never saw that |
22:30:49 | FromDiscord | <!!sharpcdf!!> thanks |
22:31:03 | FromDiscord | <scipio> In reply to @ShalokShalom "They dont care about": I don't think Flutter is merely an experiment to Google in terms of strategy |
22:31:09 | FromDiscord | <!!sharpcdf!!> but can i copy the directory with a new name? |
22:31:11 | FromDiscord | <Elegantbeef> Deech it's not the shape that matters it's what it can do |
22:31:25 | FromDiscord | <!!sharpcdf!!> oh yea i can, thanks |
22:31:32 | FromDiscord | <ShalokShalom> In reply to @scipio "I don't think Flutter": I can tell you how those things are at Microsoft |
22:31:40 | FromDiscord | <ShalokShalom> And I doubt Google is any different |
22:32:00 | FromDiscord | <ShalokShalom> They love some market share and popularity among the programming crowd |
22:32:09 | * | rockcavera quit (Remote host closed the connection) |
22:32:10 | FromDiscord | <ShalokShalom> You know why they do this? |
22:32:11 | FromDiscord | <ShalokShalom> Jobs |
22:32:12 | FromDiscord | <Elegantbeef> Fuschia isnt an experiment either amirite |
22:32:21 | FromDiscord | <planetis> like people who complain ever lift a finger |
22:32:33 | FromDiscord | <ShalokShalom> For Google, everything is an experiment |
22:32:43 | FromDiscord | <ShalokShalom> Unless it brings really money |
22:32:53 | FromDiscord | <ShalokShalom> In reply to @planetis "like people who complain": Who complains? |
22:33:04 | FromDiscord | <Elegantbeef> Hey they have to move their keys to type their strongly worded messagesāµ(@planetis) |
22:33:21 | FromDiscord | <Elegantbeef> Shalok is like "Shit are they on to me" |
22:33:27 | FromDiscord | <planetis> In reply to @ShalokShalom "Who complains?": not you |
22:33:54 | FromDiscord | <planetis> jeez wrong fish took the bait |
22:34:07 | FromDiscord | <pyolyokh> In reply to @planetis "like people who complain": if there's a boulder sitting in the middle of the road, people feel better about joining a group that's pushing, than going to push it themselves. Time isn't free, and if it's only one person the job might not even be worth doing. |
22:34:45 | FromDiscord | <Elegantbeef> pyolyokh explaining the bystander effect |
22:34:54 | FromDiscord | <planetis> no you missed the other group that shits in the side judging their form while they push |
22:35:04 | FromDiscord | <pyolyokh> I'm just saying it doesn't hurt to know who to ping, when you want help on your project that's in line with their interests |
22:35:35 | FromDiscord | <Elegantbeef> Planetis is now calling me out |
22:37:02 | FromDiscord | <planetis> don't be harsh on yourself beef, youre always helpful to others |
22:37:36 | FromDiscord | <Elegantbeef> Hey i'll use self deprecating humour if i want mom! |
22:38:52 | FromDiscord | <planetis> deprecate and rewrite away! |
22:41:59 | FromDiscord | <scipio> In reply to @pyolyokh "I'm just saying it": But serious question @pyolyokh : if you were to write an app/service like cryptowatc.ch desktop entirely in Nim, which (current) UI solution would you implement? |
22:42:58 | FromDiscord | <scipio> (edit) "cryptowatc.ch" => "cryptowat.ch" |
22:43:42 | FromDiscord | <scipio> (it being written in Rust right now, including development of Iced) |
22:44:11 | FromDiscord | <pyolyokh> sent a long message, see https://paste.rs/zQW |
22:44:24 | FromDiscord | <pyolyokh> (edit) "http://ix.io/4l2a" => "https://paste.rs/aoG" |
22:45:32 | FromDiscord | <scipio> https://cryptowat.ch/apps/desktop |
22:46:05 | FromDiscord | <scipio> it's being deployed currently as a tool to model your own dashboards, no coding required |
22:47:59 | FromDiscord | <Elegantbeef> Had to check, and oh owlkettle does have GL area so custom widgets like a graph could be made |
22:53:48 | FromDiscord | <Elegantbeef> But i guess in that case good bye mac support |
22:54:10 | FromDiscord | <pyolyokh> In reply to @scipio "it's being deployed currently": it looks good, and for something really slick there's probably a lot of performance that you can gain by having something more oriented around trading data than grafana just pairing queries with blobs of javascript to render the numbers the query gets back. |
22:59:14 | * | rockcavera joined #nim |
23:00:02 | FromDiscord | <scipio> In reply to @Elegantbeef "But i guess in": right. But CryptoWatch is also accepted in/ being distributed via the Mac AppStore |
23:00:23 | FromDiscord | <Elegantbeef> Nice, tell apple to add opengl support |
23:01:37 | FromDiscord | <Elegantbeef> Though i guess they still support opengl4.1 but idk |
23:03:51 | * | jjido quit (Quit: My laptop has gone to sleep. ZZZzzzā¦) |
23:08:37 | FromDiscord | <ambient> Isn't OGL 3.3 already decent enough if you don't want something like compute shaders |
23:08:44 | FromDiscord | <Elegantbeef> Yea |
23:08:56 | FromDiscord | <Elegantbeef> I didnt know if modern m1s supported opengl 4.1 aswell |
23:10:21 | FromDiscord | <Elegantbeef> So in closing gtk's gl area is sufficient to make graphs if someone really wanted to |
23:11:30 | FromDiscord | <jos> do you even need hardware acceleration for a graph nowadays |
23:11:57 | FromDiscord | <ambient> you never did |
23:12:03 | FromDiscord | <Elegantbeef> Well you'd want to draw text on the graph on hover and the like |
23:12:17 | FromDiscord | <Elegantbeef> So i imagine it's more intelligent to use glarea than using a drawing area |
23:12:31 | FromDiscord | <jos> u could use the os primitives too |
23:12:44 | FromDiscord | <jos> i think stuff like cairo is good |
23:12:46 | FromDiscord | <Elegantbeef> We're talking about gtk |
23:12:57 | FromDiscord | <Elegantbeef> But yea drawing area or glarea would be sufficient |
23:13:46 | FromDiscord | <T0lk1en> Hey how do you get a binary value from a string |
23:14:09 | FromDiscord | <T0lk1en> If possible^ |
23:14:59 | FromDiscord | <enthus1ast> @T0lk1en\: https://nim-lang.org/docs/strutils.html#toBin%2CBiggestInt%2CPositive |
23:16:27 | FromDiscord | <enthus1ast> sent a code paste, see https://paste.rs/zI4 |
23:17:07 | FromDiscord | <T0lk1en> That seems to only work for numbers |
23:17:30 | FromDiscord | <T0lk1en> I want to convert chars into a value I can do math on |
23:17:35 | FromDiscord | <T0lk1en> Thatās my goal |
23:17:53 | FromDiscord | <enthus1ast> then`'a'.int` |
23:18:02 | FromDiscord | <T0lk1en> Btw why does so much code have goo and bar in it |
23:18:02 | FromDiscord | <enthus1ast> 'a'.uint8 |
23:18:06 | FromDiscord | <pyolyokh> In reply to @T0lk1en "Hey how do you": as a rule, loop over the bytes of the string and build new data according to the format. For a completely random binary format you might need custom code, maybe with some help from std/endians.āµIf you have some specific binary format there might be a serialization module for it in the nimble directory, and if you want to store data to/from binary strings in general then "nimble search serial" |
23:18:39 | FromDiscord | <T0lk1en> In reply to @pyolyokh "as a rule, loop": Ty |
23:18:40 | FromDiscord | <pyolyokh> In reply to @T0lk1en "Btw why does so": it's just tradition: <https://en.wikipedia.org/wiki/Metasyntactic_variable> |
23:19:06 | FromDiscord | <T0lk1en> Funny |
23:19:32 | FromDiscord | <T0lk1en> Iām just trying to turn a char into a number I can do math on and also turn it back. Is there anything like that out there |
23:19:39 | FromDiscord | <T0lk1en> Doesnāt have to be binary |
23:20:09 | FromDiscord | <pyolyokh> for that a cast is enough, `int(c)` |
23:20:17 | FromDiscord | <T0lk1en> What is cast |
23:20:23 | FromDiscord | <T0lk1en> Wait thatās it? |
23:20:28 | FromDiscord | <pyolyokh> yep |
23:20:34 | FromDiscord | <Elegantbeef> That's a type conversion |
23:20:39 | FromDiscord | <Elegantbeef> Dont call it a cast |
23:20:50 | FromDiscord | <enthus1ast> i know it beef |
23:20:58 | FromDiscord | <enthus1ast> itched your fingers |
23:21:00 | FromDiscord | <ambient> int(c) doesn't return just the ordinal? |
23:21:04 | FromDiscord | <pyolyokh> yeah, to be clear `cast[char](300)` will be silently accepted, but `char(300)` will throw an error. type conversions are safer |
23:21:14 | FromDiscord | <Elegantbeef> It does `ord(char)` and `int(char)` should be the same |
23:21:33 | FromDiscord | <ambient> but if I want "0" to be 0, then that's not the ordinal |
23:21:39 | FromDiscord | <T0lk1en> Wtf is a cast |
23:21:45 | FromDiscord | <T0lk1en> What is ordinal |
23:21:59 | FromDiscord | <Elegantbeef> Cast in Nim reinterprets the binary data as a different type |
23:22:11 | FromDiscord | <T0lk1en> Okay |
23:22:11 | FromDiscord | <ambient> echo $("234".parseInt) |
23:22:38 | FromDiscord | <Elegantbeef> `int` and `float` are the same size on 64bit OS but `cast[int](32.2) != int(32.2)` |
23:22:49 | FromDiscord | <ambient> int is 64-bit on Mac? |
23:22:52 | FromDiscord | <pyolyokh> In reply to @T0lk1en "Wtf is a cast": programmer jargon: <https://en.wikipedia.org/wiki/Type_conversion> - a bad name for the previous conversation. The Nim manual has the terminology that Nim uses.āµordinal is math jargon: <https://en.wiktionary.org/wiki/ordinal> |
23:23:04 | FromDiscord | <Elegantbeef> On 64 bit osāµ(@ambient) |
23:23:22 | FromDiscord | <ambient> Strange, because my code breaks on mac with int, instead of int64 |
23:23:29 | FromDiscord | <pyolyokh> int is the size of the pointer on your architecture: <https://nim-lang.org/docs/manual.html#types-preminusdefined-integer-types> |
23:23:32 | FromDiscord | <ambient> On Windows it works fine with just int |
23:24:19 | FromDiscord | <T0lk1en> Wait Iām not trying to turn a valid number that is stored as a chat to an int |
23:24:32 | FromDiscord | <T0lk1en> I want to turn a letter into an int |
23:24:44 | FromDiscord | <T0lk1en> Char^ |
23:24:51 | FromDiscord | <pyolyokh> sent a code paste, see https://play.nim-lang.org/#ix=4l2n |
23:25:22 | FromDiscord | <T0lk1en> Iāll be damned |
23:25:23 | FromDiscord | <T0lk1en> Ty |
23:40:33 | FromDiscord | <T0lk1en> Hey is there a way to tell a sequence how long it should be |
23:41:13 | FromDiscord | <T0lk1en> Iām trying to run an empty sequence through a for loop howveee because it is empty I get out of bounds error |
23:41:45 | FromDiscord | <T0lk1en> This would be solved if I could tell a sequence how long it should be without filling it. However the length also changes so I canāt use an array |
23:44:36 | FromDiscord | <pyolyokh> it sounds like you want `newSeqOfCap`, but that's not going to save you from an out of bounds error. Maybe you want an initial and then a final `setLen`, initially for space to work, and finally after you've decided on a length |
23:45:32 | FromDiscord | <T0lk1en> How do you do setlen |
23:46:49 | FromDiscord | <pyolyokh> sent a code paste, see https://play.nim-lang.org/#ix=4l2q |
23:48:12 | FromDiscord | <T0lk1en> Ty |
23:48:23 | FromDiscord | <T0lk1en> You guys in this discord have helped sm |
23:50:26 | FromDiscord | <!!sharpcdf!!> how can i clear the screen of an illwill tui when it isnt fullscreen? |
23:54:16 | FromDiscord | <pyolyokh> like, to clear it on startup even if you're only going to write to part of the screen? Manually, I guess, with `echo "\e[2J"` |
23:54:56 | FromDiscord | <pyolyokh> why aren't you going fullscreen? |
23:56:16 | FromDiscord | <enthus1ast> @!!sharpcdf!!\: setting the cursor to 0 , 0 then overwrite stuff should work |
23:56:31 | FromDiscord | <pyolyokh> when writing to a terminal buffer the size of the screen, `illwillInit(fullscreen=true)` or =false didn't seem to make a difference. |