00:00:20 | * | NimBot joined #nim |
00:20:01 | * | endragor joined #nim |
00:24:14 | * | endragor quit (Ping timeout: 240 seconds) |
00:39:07 | FromGitter | <ynfle> When is `bindsym` needed? |
00:53:12 | FromDiscord | <Yardanico> When you want to use some symbol from the module you imported in your macro, but don't want the user to have to import that module as well |
00:53:41 | FromGitter | <ynfle> Ohh |
00:53:46 | FromGitter | <ynfle> That makes sense!!! Thanks |
00:54:05 | FromDiscord | <Yardanico> E.g. you can do that for strutils.format, use it in your macro, and when that macro is called from another module you won't need to import strutils three |
00:54:10 | FromDiscord | <Yardanico> (edit) 'three' => 'there' |
00:56:44 | FromDiscord | <Yardanico> There's also bind useful in templates usually |
00:57:08 | FromDiscord | <Yardanico> and mixin for templates/generic procs (if I'm not mistaken) |
00:57:57 | FromDiscord | <Yardanico> https://nim-lang.org/docs/manual.html#generics-mixin-statement and https://nim-lang.org/docs/manual.html#generics-bind-statement |
00:58:00 | * | axion joined #nim |
01:00:43 | * | endragor joined #nim |
01:01:02 | * | axion left #nim (#nim) |
01:06:03 | * | audiophile joined #nim |
01:13:18 | * | MortS joined #nim |
01:21:25 | * | MortS left #nim ("Leaving") |
01:24:35 | FromDiscord | <Zachary Carter> should the dynlib pragma be used with importcpp? |
01:24:50 | FromDiscord | <Zachary Carter> I want to statically link a C++ lib but I'm not sure how... |
01:25:07 | FromDiscord | <Zachary Carter> when I use the dynlib pragma I get an invalid pragma error |
01:25:16 | FromDiscord | <Yardanico> I don't think you need dynlib when statically linking at all? |
01:25:46 | FromDiscord | <Zachary Carter> well for importc I think the pattern is to use the dynlib pragma and then dynlibOverride |
01:26:07 | FromDiscord | <Zachary Carter> but apparently this doesn't work the same for importcpp |
01:27:22 | FromDiscord | <Yardanico> ah |
01:27:29 | * | MortS joined #nim |
01:27:42 | * | oddp quit (Ping timeout: 256 seconds) |
01:29:58 | * | endragor quit (Ping timeout: 244 seconds) |
01:33:35 | * | lritter quit (Quit: Leaving) |
01:40:27 | FromDiscord | <Zachary Carter> ah my error was caused by something else - I can just passC the static library and it works |
01:44:26 | * | chemist69 quit (Ping timeout: 244 seconds) |
01:46:36 | * | chemist69 joined #nim |
01:47:10 | disruptek | we can't do this unix file permissions stuff by simply casting the set? |
01:50:51 | * | B4s1l3 joined #nim |
01:51:26 | * | opDispatch quit (Ping timeout: 260 seconds) |
01:56:42 | * | endragor joined #nim |
01:57:40 | * | vr0n joined #nim |
01:58:41 | * | arecaceae quit (Remote host closed the connection) |
01:59:04 | * | arecaceae joined #nim |
02:16:55 | * | MortS quit (Quit: Leaving) |
02:19:06 | * | sagax joined #nim |
02:33:01 | * | nikita_ joined #nim |
02:35:09 | * | muffindrake quit (Ping timeout: 272 seconds) |
02:35:37 | * | nikita` quit (Ping timeout: 264 seconds) |
02:36:35 | * | thomasross quit (Ping timeout: 256 seconds) |
02:36:51 | * | muffindrake joined #nim |
02:40:29 | leorize | disruptek: we can, just unsafe since the semantics of casting to set[T] is not fully specified |
02:40:57 | disruptek | which part isn't specified? |
02:41:07 | leorize | the casting without knowing the size part |
02:41:26 | leorize | s/knowing/specifying/ |
02:41:26 | disruptek | don't we know the size of file permission bitsets? |
02:41:50 | leorize | the manual only guarantee the behavior if you have `{.size: sizeof(cint).}` |
02:42:00 | disruptek | so put that in? |
02:42:19 | disruptek | i guess i don't see what the problem is. |
02:49:49 | disruptek | !rfc == |
02:49:49 | disbot | no results 😢 |
03:11:15 | FromGitter | <Knaque> What would be the easiest way of being able to use the Parsecfg module on a string? |
03:13:11 | FromDiscord | <juan_carlos> `loadConfig` takes a string Stream. |
03:31:29 | * | aeldemeryde[m] joined #nim |
03:43:42 | * | rockcavera quit (Remote host closed the connection) |
03:45:54 | * | pietroppeter joined #nim |
03:46:38 | * | chemist69 quit (Remote host closed the connection) |
03:47:01 | * | chemist69 joined #nim |
03:47:59 | * | vr0n quit (Ping timeout: 256 seconds) |
03:49:00 | * | waleee-cl quit (Quit: Connection closed for inactivity) |
03:53:51 | * | notandinus quit (Quit: be back in a minute) |
03:54:39 | * | team\andinus joined #nim |
03:55:58 | FromGitter | <ynfle> If I wanna use my own type for a `Table` does it have to be `distinct string` for example? |
03:56:13 | disruptek | nah. |
03:56:23 | * | team\andinus is now known as notandinus |
03:56:25 | FromGitter | <ynfle> Otherwise the calls are ambiguous for `==` and `hash` |
03:57:21 | disruptek | you don't need to reimplement `==`() or hash() for strings and implementations are already provided. |
03:57:44 | FromGitter | <ynfle> I want it to be different |
03:58:18 | FromGitter | <ynfle> ie. I want to use my own `==` and `hash` |
03:59:16 | disruptek | then you need to use a distinct string. |
03:59:43 | disruptek | see also the strtabs module. |
03:59:51 | FromGitter | <ynfle> Ya |
04:00:59 | FromGitter | <ynfle> I want to have a table that would function to compare nim ident. So the first letter matters by the rest don't for style. |
04:01:13 | FromGitter | <ynfle> `strtabs` doesn't have that |
04:01:34 | disruptek | of course it does. |
04:01:57 | disruptek | https://nim-lang.github.io/Nim/strtabs#StringTableMode |
04:02:40 | FromGitter | <ynfle> StyleInsensitive means even the first letter iirc |
04:04:10 | disruptek | you might be right. |
04:04:29 | disruptek | that means nimph has at least one bug. |
04:05:01 | FromGitter | <ynfle> 1) 2.4 has strutils methods for this |
04:06:01 | * | supakeen quit (Quit: WeeChat 2.8) |
04:06:33 | * | marnix__ joined #nim |
04:06:40 | * | supakeen joined #nim |
04:07:06 | FromGitter | <ynfle> https://nim-lang.github.io/Nim/strutils#nimIdentNormalize%2Cstring |
04:18:23 | FromGitter | <ynfle> https://play.nim-lang.org/#ix=2qKk Any idea why i'm getting this error `Error: no symbol to borrow from found`? |
04:25:26 | FromGitter | <bung87> means nothing to borrow |
04:32:53 | FromGitter | <ynfle> I know but why not? |
04:33:04 | FromGitter | <ynfle> Did you see the code snippet? |
04:34:40 | FromGitter | <bung87> I checked but am not sure the signature will match the string's as you expect |
04:34:59 | FromGitter | <ynfle> Why not? How would I change it? |
04:38:53 | FromGitter | <bung87> https://github.com/nim-lang/Nim/blob/devel/lib/system/sysstr.nim no procs like that , see |
04:40:04 | * | aeldemeryde[m] left #nim ("User left") |
04:40:38 | FromGitter | <ynfle> I don't get it |
04:44:53 | FromGitter | <bung87> no procs like that you intend to borrow ,from what I understanding |
04:46:38 | FromGitter | <ynfle> What are the rules for borrowing? |
04:46:57 | FromGitter | <ynfle> Are you pointing to a specific line in `sysstr.nim` |
04:48:59 | FromDiscord | <Technisha Circuit> How do i join a path in Nim? |
04:49:17 | FromGitter | <bung87> borrow procs from existed procs of a Type |
04:49:21 | FromDiscord | <Technisha Circuit> For a file location |
04:50:24 | FromGitter | <bung87> `/` ? |
04:50:25 | FromGitter | <ynfle> I think it's just `/` |
04:50:42 | FromGitter | <ynfle> @bung87 look in `system.in` |
04:51:00 | FromGitter | <ynfle> https://github.com/nim-lang/Nim/blob/version-1-2/lib/system.nim#L2426 |
04:51:09 | FromDiscord | <Elegant Beef> I'd say use https://nim-lang.org/docs/os.html#joinPath%2Cstring%2Cstring |
04:52:19 | FromGitter | <bung87> ah , it's in system.nim , not proc , a template |
04:52:30 | FromGitter | <ynfle> Can't borrow from templates? |
04:53:15 | FromGitter | <bung87> I havn't try borrow templates |
04:56:08 | * | marnix joined #nim |
04:56:12 | shashlick | who wants a wrapper for a C library - want a filler exercise |
04:57:14 | leorize | shashlick: you can try nghttp2 :) |
05:00:03 | shashlick | already done before |
05:02:44 | FromGitter | <ynfle> If you want a challenge try TensorFlow |
05:03:04 | leorize | that thing has a C API? |
05:03:16 | * | wgetch quit (Quit: Bye bye for now) |
05:04:01 | shashlick | https://github.com/tensorflow/tensorflow/blob/master/tensorflow/c/c_api.h |
05:04:19 | leorize | I'd be thrilled if you can completely wrap Qt, but that's not C :P |
05:05:41 | FromGitter | <ynfle> TensorFlow is a c library with python API |
05:06:31 | FromGitter | <ynfle> iirc |
05:06:39 | leorize | one of the thing I'd like to see solved is a better {.dynlib.} implementation |
05:07:25 | shashlick | the one we discussed? |
05:07:30 | leorize | yea |
05:07:49 | leorize | maybe call it {.lazylib.} :P |
05:08:17 | shashlick | i've been wondering about doing it but its yet another option and i don't know if users already understand the variety let alone another one |
05:08:45 | leorize | you can implement it as a macro and contribute that to nim-fusion |
05:09:55 | leorize | doesn't have to be nimterop specific, I can use that to deprecate the need of `-d:ssl` in nim :) |
05:10:10 | leorize | instead I can lazy load ssl stuff as needed and if I can't I just throw an error |
05:14:43 | shashlick | I think you understand that a lot better than I do |
05:16:10 | bung_ | I'd like to see a js engine wrapper |
05:16:23 | shashlick | duktape wrapper already exists |
05:16:32 | shashlick | https://gist.github.com/genotrance/51702ec94efcf7151b3d253600f6be22 |
05:17:48 | shashlick | I had also worked on a quickjs wrapper |
05:23:37 | bung_ | thanks ! is quickjs wrapper done? |
05:25:22 | shashlick | let me see where i left it |
05:26:24 | leorize | shashlick: or you can try this for a big challenge: make cmake, meson, etc. understands how to build Nim |
05:27:05 | leorize | then we can fuse other cmake/meson-based stuff with Nim |
05:27:42 | leorize | the compiler is cool and all, but it's not even close to what specialized builders can do :) |
05:29:47 | shashlick | these are too big fillers 🙂 |
05:30:05 | shashlick | i'm not very experienced with cmake and other builders honestly |
05:30:51 | bung_ | it looks like these js engine doesn't offer a api evaluate js file also handle requires ? |
05:31:30 | leorize | requires and friends are node-only stuff I think |
05:32:55 | bung_ | ah, it would be nice to have such stuff call directly from nim |
05:34:30 | shashlick | nghttp2 wrapper - https://gist.github.com/genotrance/65bcb6957b27e710f97379386c5ef5c3 |
05:35:00 | shashlick | what was next - quickjs - yes |
05:39:49 | * | audiophile quit (Quit: Default Quit Message) |
05:40:26 | FromGitter | <Knaque> Has anyone made Nim syntax highlighting for any of the HTML `<code>` highlighters out there? |
05:42:36 | FromGitter | <ynfle> https://prismjs.com/#supported-languages has nim |
05:42:37 | * | marnix quit (Ping timeout: 244 seconds) |
05:44:08 | FromGitter | <Knaque> Perfect, thank you. |
05:45:39 | FromGitter | <ynfle> 👍 |
05:46:45 | * | maier joined #nim |
05:46:50 | * | maier is now known as kenran |
05:48:37 | FromDiscord | <flywind> Btw Nim stdlib also has `highlight` modules, you can do it by self. https://nim-lang.org/docs/highlite.html |
05:51:42 | FromGitter | <ynfle> PrismJs is very simple |
05:52:05 | FromGitter | <ynfle> Just define the langauge in attr initialize in JS and you're good to go |
05:52:54 | * | solitudesf joined #nim |
05:54:35 | FromDiscord | <flywind> I know it. Someone has made a Nim static blog generator using `prismjs`. |
05:54:38 | FromDiscord | <flywind> https://github.com/muxueqz/kun/tree/master/public/static |
05:55:25 | * | pietroppeter quit (Quit: Connection closed for inactivity) |
05:56:41 | shashlick | @bung_: quickjs wrapper - https://gist.github.com/genotrance/4869d1feb53c7ec7be806a2f225d07ab |
06:03:22 | bung_ | ah I'll give a try |
06:03:38 | bung_ | it described "Almost complete ES2020 support including modules," |
06:07:38 | * | oculux quit (Ping timeout: 260 seconds) |
06:09:10 | FromDiscord | <Synth> Hello, I'm trying to `stdout.write()` colored text. Does anyone know how I could achieve this? If so, please ping me. Thank you! |
06:11:05 | shashlick | See the terminal module |
06:11:09 | shashlick | I think |
06:11:16 | FromDiscord | <Elegant Beef> Yea |
06:13:25 | FromDiscord | <Synth> I've taken a look at the module |
06:17:47 | * | FromDiscord quit (Remote host closed the connection) |
06:18:04 | * | FromDiscord joined #nim |
06:19:32 | * | go|dfish quit (Ping timeout: 256 seconds) |
06:19:39 | * | marnix__ is now known as marnix |
06:25:46 | shashlick | https://github.com/genotrance/snip/blob/master/src/snip/ui.nim is how i did it in snip |
06:31:43 | * | rokups joined #nim |
06:33:03 | * | go|dfish joined #nim |
06:34:31 | * | B4s1l3 quit (Quit: Konversation terminated!) |
06:38:37 | FromDiscord | <Yardanico> @Synth well you set current color with terminal, write text with that color, reset attributes |
06:38:44 | FromDiscord | <Yardanico> There's also styledWrite |
06:39:15 | FromDiscord | <Yardanico> https://nim-lang.org/docs/terminal.html#styledWrite.m%2CFile%2Cvarargs%5Btyped%5D |
06:42:52 | * | PMunch joined #nim |
06:43:46 | shashlick | @ynfile - last one for the night - tensorflow wrapper - https://gist.github.com/genotrance/9214b1c1762c1fc85e62bac1de67725f |
06:52:31 | bung_ | shashlick header: "/home/gt/.cache/nim/nimterop/nimquickjs/quickjs.h" the path should point to where? |
06:53:02 | PMunch | Hmm, I think I might want to write stacklang 2.0 |
06:53:18 | PMunch | krux02 planted some interesting ideas in my head yesterday |
06:58:38 | FromDiscord | <Synth> Hmm okay, thank you |
06:58:39 | shashlick | @bung_? it should point to the location of the quickjs header |
06:59:05 | shashlick | you'd rather generate it for your setup using the nimterop wrapper rather than the raw output |
07:02:23 | bung_ | how to do that ? |
07:05:08 | bung_ | ah , I install fails that's why I have no toast binary |
07:09:57 | shashlick | what's the error |
07:11:40 | bung_ | it first build fails then ask me install nimterop#head |
07:11:42 | bung_ | ... /Users/bung/.choosenim/toolchains/nim-#devel/lib/system/fatal.nim(49, 5) Error: unhandled exception: shell.nim(84, 16) `false` Command failed: 128 ... cmd: cd /Users/bung/.cache/nim/nimterop/nimterop/treesitter_cpp && git log --decorate --no-color -n 1 --format=oneline ... result: ... fatal: your current branch 'master' does not have any commits yet [AssertionDefect] |
07:14:01 | bung_ | I even didnot git init under project root |
07:15:14 | shashlick | please delete ~/.cache/nim/nimterop altogether and try again |
07:21:13 | bung_ | doing it |
07:21:43 | * | pietroppeter joined #nim |
07:31:13 | bung_ | it will take over ten minutes? |
07:31:35 | bung_ | it still "Building nimterop/nimterop/toast using c backend" |
07:31:54 | FromDiscord | <demotomohiro> This PR is not merged to nimgl repository.↵https://github.com/nimgl/imgui/pull/2 |
07:31:55 | disbot | ➥ Fix compile error from nim cpp tests/test.nim |
07:39:32 | shashlick | @bung_ takes 20 seconds on my small linux box |
07:39:55 | shashlick | maybe a minutes max for first time |
07:40:13 | shashlick | how long does nim take to bootstrap typically |
07:40:46 | Oddmonger | hello, i've looked the link given yesterday ( https://github.com/nim-lang/Nim/wiki/Curated-Packages ) : there is an entry for curses, but no link. Is this an error or there's really nothing for ncurses ? Otherwise, i've found this: https://github.com/rnowley/nim-ncurses but don't know if it's ok |
07:40:48 | bung_ | maybe cause am using nim 1.3.3 ? |
07:41:20 | shashlick | that's what i'm using as well |
07:41:31 | shashlick | did you compile it in debug mode or something |
07:41:37 | shashlick | presume you used koch |
07:41:54 | shashlick | what version of gcc do you have |
07:42:21 | solitudesf | Oddmonger, this one is maintained https://github.com/walkre-niboshi/nim-ncurses |
07:42:52 | bung_ | Apple clang version 11.0.0 (clang-1100.0.33.17) |
07:44:31 | Oddmonger | thank you solitudesf , this one seems nice too (but only inspired by ncurses): https://github.com/johnnovak/illwill |
07:45:22 | * | Jjp137 quit (Quit: Leaving) |
07:45:24 | shashlick | i don't see why it should take so long - is it still not done? |
07:45:42 | shashlick | instead, can you git clone and run `nim c nimterop/toast` and see what happens |
07:46:29 | FromGitter | <bung87> I cancel it after about 15 mins, I check it when am back, buy some drinking |
07:48:13 | * | Jjp137 joined #nim |
08:15:36 | * | dddddd joined #nim |
08:16:20 | bung_ | shashlick same in clone, or should i remove whole ~/.cache/nim/ ? |
08:17:58 | * | letto quit (Quit: Konversation terminated!) |
08:19:53 | bung_ | there's https://github.com/ImVexed/quickjs4nim looks like generated through nimgen |
08:23:47 | * | vicfred quit (Quit: Leaving) |
08:38:01 | PMunch | I keep forgetting, what is the fast version of koch? |
08:39:00 | FromDiscord | <gokr> @dom96 I am wondering, if I add an installDir - it evidently seems to look for it under src (if I have srcDir set to "src" which I think is proper style). Is that a rule? |
08:52:28 | Oddmonger | nimble | grep "up[dgr]\+a[dt]e" # no match |
08:52:42 | Oddmonger | is it possible to update all packages at once ? |
08:52:44 | * | nikita_ is now known as nikita |
08:53:14 | * | nikita is now known as Guest25669 |
08:58:46 | slackytude[m] | what would I need to do to have my nim executable run on mac? |
08:59:45 | Oddmonger | you need Xcode (i've seen that in the doc, i don't use mac) |
08:59:53 | * | fanta1 joined #nim |
09:00:11 | Oddmonger | if i have well read, you can't cross-compile with nim for mac |
09:03:36 | slackytude[m] | thats kinda sucky |
09:04:37 | PMunch | Well, that doesn't really seem to be the case: https://forum.nim-lang.org/t/2652 |
09:05:02 | slackytude[m] | oh noice |
09:05:06 | slackytude[m] | let me check that |
09:05:11 | slackytude[m] | thx |
09:05:13 | PMunch | That is compiling from Linux to MacOS, but I guess it would be similar for Windows |
09:05:14 | PMunch | No problem |
09:05:44 | PMunch | disruptek, could disbot be made to show the title for forum links as well? Similar to how it shows the title of repo issues? |
09:07:51 | * | oddp joined #nim |
09:10:00 | PMunch | Man, the documentation generation is a real mess.. |
09:10:11 | PMunch | I think I've now found three ways of passing the output format around |
09:10:31 | slackytude[m] | I forgot how ugly cross compiles are |
09:10:39 | slackytude[m] | maybe there is a nice docker for that |
09:14:42 | * | JustASlacker joined #nim |
09:23:34 | * | krux02 joined #nim |
09:26:52 | FromDiscord | <impbox> i did manage to cross compile from linux to mac but it was a real pain |
09:27:06 | FromDiscord | <impbox> https://github.com/tpoechtrager/osxcross |
10:02:04 | Oddmonger | what is the difference between const and let ? |
10:02:29 | Oddmonger | const is only for preprocessor, and not usable in the source ? |
10:02:35 | FromDiscord | <mratsim> const are done at compiletime |
10:03:09 | FromDiscord | <mratsim> Nim doesn't have a preprocessor, but you can run lots of computation at compile-time |
10:03:38 | Oddmonger | so it's only for compilation |
10:04:35 | FromDiscord | <mratsim> If you know the value or can derive the value at compile time for example↵↵const x = align("foo", 10) |
10:05:03 | FromDiscord | <mratsim> you will have " foo" inline everywhere and the actual computation will not appear in the code, only the result |
10:05:16 | FromDiscord | <mratsim> (this is left pad) |
10:05:35 | FromDiscord | <mratsim> if you use "let" there will be an actual function call in the code |
10:05:52 | FromDiscord | <mratsim> Also "const" can be use for dependent types |
10:06:35 | FromDiscord | <mratsim> for example: https://github.com/numforge/laser/blob/master/laser/dynamic_stack_arrays.nim#L6-L18 |
10:06:39 | FromDiscord | <jseb> oh, it can compute things at compile time |
10:07:10 | Oddmonger | ok, thank you for the sample mratsim |
10:07:28 | FromDiscord | <mratsim> My array size is parametrized by a const integer, this is not possible with a let |
10:08:15 | Oddmonger | can't you do something like «let length = length(array) » ? |
10:08:27 | FromDiscord | <mratsim> @jseb you would be surprised by the number of things you can do at compile-time |
10:08:48 | FromDiscord | <mratsim> I've implemented BigInt and a proof-of-concept of a machine learning compiler at compile-time |
10:08:52 | FromDiscord | <mratsim> and a state machine generator |
10:09:25 | leorize | the only caveat is that nimvm is slow :p |
10:09:32 | FromDiscord | <mratsim> @Oddmonger, yes you can do this, but you cannot use the new "length" value everywhere that required a const |
10:09:36 | * | Tongir quit (Ping timeout: 256 seconds) |
10:09:47 | FromDiscord | <mratsim> nah, it's as slow as Python which is plenty fast |
10:10:00 | Oddmonger | i think i understand |
10:10:03 | FromDiscord | <mratsim> much faster than C++ template metaprogramming |
10:10:04 | Oddmonger | thank you |
10:11:27 | Oddmonger | another one: i've tried nimx , for having portable GUI. It's quite slow to compile at first, and then when the obj are cached, the compilation is faster then. But it stills does a lot of things (2.5 seconds for relinking without modifications, on a good machine). So i wonder if the solution could be to generate a library with the functions i want from nimx, for avoiding the linking state everytime ? |
10:14:02 | FromDiscord | <mratsim> In my experience, the slowest thing in a project is if there are C or C++ files/header and it's not pure Nim because the C filesare recompiled.↵The second slowest is when you have a lot of compile-time computation but that's not the case for Nimx |
10:14:25 | * | fredrikhr joined #nim |
10:14:35 | FromDiscord | <mratsim> yes you can do a library, though I'm not an expert on Nim DLLs |
10:17:20 | Oddmonger | ok that's not very important for now anyway, i was just curious. Thank you |
10:20:01 | FromDiscord | <mratsim> When I found the compilation too slow with C/C++ lib I just build them as DLL as you said: https://github.com/numforge/agent-smith/blob/master/third_party/ale_build.nim |
10:20:09 | FromDiscord | <mratsim> (and replacing CMake in the process 😉 |
10:27:21 | * | xet7 quit (Quit: Leaving) |
11:17:07 | * | PMunch_ joined #nim |
11:17:27 | * | PMunch quit (Read error: Connection reset by peer) |
11:30:41 | * | xet7 joined #nim |
11:31:00 | Oddmonger | good to know, thanks |
11:33:30 | Oddmonger | i don't like cmake very much… in fact, for something supposed to be easier than make, i see it as a lie |
11:46:25 | Oddmonger | mratsim, can you tell me how to build «agent smith» ? I've cloned your repo, and have done «nimble build» at root , but it answers there is nothing to build |
11:54:36 | * | rockcavera joined #nim |
11:56:44 | * | Vladar joined #nim |
11:57:25 | * | Guest25669 is now known as nikita |
11:57:43 | * | nikita quit (Quit: Reconnecting) |
11:58:00 | * | Guest6133 joined #nim |
12:00:38 | * | PMunch_ is now known as PMunch |
12:00:47 | * | Guest6133 is now known as nikita` |
12:06:01 | * | supakeen quit (Quit: WeeChat 2.8) |
12:06:42 | * | supakeen joined #nim |
12:10:02 | FromDiscord | <exelotl> Oddmonger: ow yeah I agree, cmake is pretty painful :( |
12:12:54 | * | Trustable joined #nim |
12:15:11 | krux02 | regarding cmake, I think that there is a reason that my 9 commits project here got pretty popular: https://github.com/krux02/minimal_cmake_example |
12:18:28 | Oddmonger | thank for the sample, i tried the official «documentation» and sink in despair |
12:18:40 | Oddmonger | sink… sank … sunk i mean |
12:19:11 | * | abm joined #nim |
12:22:25 | * | JustASlacker quit (Ping timeout: 264 seconds) |
12:29:29 | PMunch | Quick guess, there is no sane way of getting the name of a constant given a value? |
12:30:05 | FromDiscord | <Rika> i dont see how |
12:30:17 | PMunch | krux02, I started thinking about your negative stack thing. Really interesting, but I think it would be a PITA to implement |
12:30:45 | PMunch | Basically the stack operations would need to be some kind of async operation |
12:30:58 | PMunch | So that they can suspend the execution until you get a value |
12:31:18 | krux02 | you can see it that way. |
12:31:52 | PMunch | I also have an "insert" operation in stacklang, that would be interesting to implement :P |
12:32:11 | krux02 | My thoughts were also more for a programming language not an interactive stack. |
12:32:13 | PMunch | Inserting values into some negative positions on the stack so they suddenly become available |
12:32:39 | krux02 | So that at the end there is static checking that the stack has a size of zero |
12:33:19 | PMunch | Oh |
12:33:20 | krux02 | and everything gets compiled to something that isn't really a stack. It is just a concept that is used to resolve the semantics. |
12:33:31 | PMunch | In stacklang it just outputs whatever was left on the stack |
12:33:32 | krux02 | it surely can be implemented as a real stack though. |
12:33:39 | PMunch | Which is how the program can return stuff |
12:33:48 | PMunch | Well, I also have a echo thing |
12:34:29 | krux02 | btw you are developing on linux as well, don't you? |
12:34:34 | PMunch | Yup |
12:35:13 | krux02 | I would like to have someone to test my opengl-sandbox again, in term of. Does it even run on other peoples computers. |
12:35:49 | krux02 | after nimble has failed me many times, I eventually migrated to git submodules now. |
12:36:20 | krux02 | You would do me a great favor if you agree to try it. |
12:37:19 | krux02 | like a real user test as good software should always do. |
12:38:51 | PMunch | Sure, just tell me how to try it |
12:41:44 | disruptek | PMunch: forum titles, sure. |
12:41:54 | PMunch | disruptek, sweet |
12:42:29 | disruptek | i'll make a ticket. might be a little bit. |
12:43:10 | PMunch | No problem, just thought of it when I had to link someone a post |
12:44:08 | disruptek | don't tell him how to try it; that defeats the purpose. |
12:44:42 | disruptek | user testing involves the user having a goal and using your product to attempt to achieve it. |
12:45:03 | PMunch | Okay, tell me what I should try to achieve then |
12:45:23 | disruptek | well, i do need a renderer for graphs. 😁 |
12:46:09 | disruptek | or just something like "make text appear on the screen with a given background color" |
12:46:21 | FromDiscord | <Zachary Carter> Wrapping C++ is confusing af... I'm trying to wrap - https://github.com/guillaumeblanc/ozz-animation/blob/master/include/ozz/base/io/stream.h |
12:47:04 | FromDiscord | <Zachary Carter> and I always run into errors like these - https://gist.github.com/zacharycarter/e2937f718c21bc62e13306884c46a372 |
12:47:32 | FromDiscord | <Zachary Carter> I don't understand whyyyyyy |
12:50:13 | FromDiscord | <Zachary Carter> I understand why the generated C++ code compiles - but what I don't understand is how to fix it to get it to compile. |
12:53:15 | disruptek | dunno, but i'd look for some other cpp wrappers for ideas. |
12:53:42 | disruptek | shashlick is mr. wrapper, as you know... 😉 |
12:54:03 | FromDiscord | <Zachary Carter> oh yeah - he's fixed like four or five nimterop bugs in the past couple days for me |
12:54:41 | disruptek | i think if you say shashlick shashlick shashlick va-va-voom he'll just appear in the chat. |
12:54:51 | disruptek | fix your bugs. |
12:54:56 | FromDiscord | <Zachary Carter> I've looked at other C++ wrappers but no ah ha moments yet |
12:54:58 | FromDiscord | <Zachary Carter> hahaha |
12:54:58 | disruptek | upload a new wrapper to a gist. |
12:55:47 | disruptek | if that doesn't work, you might have to go to his house and camp out on his lawn. |
12:55:53 | FromDiscord | <Rika> PMunch: about negative stacks, why not have operations be put into a 2nd stack when theyre lacking operands, and pop them once theyre fulfilled |
12:55:55 | FromDiscord | <Rika> or something |
13:08:25 | FromDiscord | <jseb> is it true that you can now replace `nake` with `nimble`, for building ? |
13:10:52 | * | krux02 quit (Remote host closed the connection) |
13:11:34 | * | krux02 joined #nim |
13:26:39 | FromDiscord | <exelotl> @jseb yes, or even just `nim mytask` |
13:27:02 | FromDiscord | <exelotl> where `mytask` is defined in your project's "config.nims" file |
13:32:01 | FromDiscord | <Zachary Carter> you don't even need nimble |
13:32:07 | FromDiscord | <Zachary Carter> you can just use a nimscript file - which is what I do |
13:32:35 | PMunch | @Rika, yes that's the plan, but that is in principle the same as what an async system does |
13:32:52 | FromDiscord | <Rika> i see |
13:32:55 | FromDiscord | <exelotl> here are the docs: https://nim-lang.org/docs/nims.html |
13:39:29 | * | audiophile joined #nim |
13:40:08 | disruptek | ~nimscript is mostly nim. it's analogous to clojurescript in that it's the same language, running on a different backend. in the case of nim, it's running on the nim vm. |
13:40:08 | disbot | nimscript: 11NimScript is the subset of Nim that can be evaluated by Nim's builtin virtual machine - https://nim-lang.org/docs/nims.html |
13:40:08 | disbot | nimscript: 11mostly nim. it's analogous to clojurescript in that it's the same language, running on a different backend. in the case of nim, it's running on the nim vm. |
13:40:56 | disruptek | ~nimscript is mostly nim. it's analogous to clojurescript in that it's the same language, running on a different backend. in the case of nimscript, it's running on the nim vm. |
13:40:57 | disbot | nimscript: 11NimScript is the subset of Nim that can be evaluated by Nim's builtin virtual machine - https://nim-lang.org/docs/nims.html |
13:40:57 | disbot | nimscript: 11mostly nim. it's analogous to clojurescript in that it's the same language, running on a different backend. in the case of nimscript, it's running on the nim vm. |
13:41:17 | disruptek | spammy, i know. |
13:41:28 | disruptek | i just don't care about you all. |
13:41:40 | FromDiscord | <Zachary Carter> that's obvious |
13:42:23 | FromDiscord | <Zachary Carter> otherwise we'd have IC or a compilation server by now |
13:42:39 | disruptek | actually, i'm working on a couple cool things for nim right now. |
13:43:03 | disruptek | one is secret, the other is top secret. |
13:43:12 | FromDiscord | <Zachary Carter> oooo |
13:43:17 | FromDiscord | <Zachary Carter> can you make my importcpp code work? |
13:43:21 | disruptek | nope. |
13:43:22 | FromDiscord | <Zachary Carter> is that the top secret one? |
13:43:25 | FromDiscord | <Zachary Carter> fuckkkkkk |
13:43:29 | disruptek | that's arcane majik. |
13:43:37 | FromDiscord | <Zachary Carter> SOMEONE has to know how this shit works |
13:43:39 | FromDiscord | <Zachary Carter> looking at Araq |
13:43:52 | FromDiscord | <Zachary Carter> actually it seems like there are quite a few community members who have wrapped cpp libs |
13:44:09 | FromDiscord | <Zachary Carter> none of them ever chime up when I ask questions about this stuff though - besides leorize and he just tells me took at the generated code |
13:44:40 | FromDiscord | <Zachary Carter> well they just tell me - need to start being better about this before another incident happens |
13:45:31 | disruptek | but how is this something that doesn't appear in other libs? |
13:45:54 | FromDiscord | <Zachary Carter> it definitely does - but I'm not doing anything differently from what I can tell |
13:46:24 | disruptek | let me look at this and just throw swags at you. |
13:46:26 | FromDiscord | <Zachary Carter> the only thing that might be different is there's no default constructor defined for this type in the C++ code |
13:46:52 | FromDiscord | <Zachary Carter> and the generated C++ code does something like - `N_LIB_PRIVATE ozz::io::File f__bB9c2jWHU9cutANbte9by7cXw;` |
13:46:55 | disruptek | take the constructor out, then. |
13:47:06 | disruptek | take the .constructor out, then. |
13:47:07 | FromDiscord | <Zachary Carter> I need the constructor though - the one that's defined in C++ |
13:47:21 | disruptek | take it out. |
13:47:37 | FromDiscord | <Zachary Carter> this one - `https://github.com/guillaumeblanc/ozz-animation/blob/master/include/ozz/base/io/stream.h#L99` |
13:47:47 | FromDiscord | <Zachary Carter> how else am I going to invoke that then? |
13:47:50 | krux02 | Zachary Carter: what is your question. |
13:47:55 | krux02 | I've worked with c++ in the past. |
13:48:02 | disruptek | i have no idea. i just want to see how the behavior changes. |
13:48:22 | FromDiscord | <Zachary Carter> I'm trying to wrap this header - https://github.com/guillaumeblanc/ozz-animation/blob/master/include/ozz/base/io/stream.h |
13:48:26 | FromDiscord | <Zachary Carter> specifically the `File` class |
13:48:52 | FromDiscord | <Zachary Carter> here's what I've tried - along with the error that is produced: https://gist.github.com/zacharycarter/e2937f718c21bc62e13306884c46a372 |
13:49:06 | FromDiscord | <Zachary Carter> and I can gist the generated C code too - one moment |
13:50:07 | FromDiscord | <Zachary Carter> Okay the gist is updated with the generated cpp code |
13:50:11 | FromDiscord | <Zachary Carter> sorry not c |
13:50:27 | disruptek | he's not a nazi just because he wants updates. |
13:50:38 | disruptek | fascism is a much deeper ideology. |
13:51:29 | FromDiscord | <Zachary Carter> lol |
13:53:09 | FromDiscord | <Zachary Carter> I'm guessing it's because File doesn't have any constructor that takes zero params defined in it |
13:53:36 | disruptek | okay, lemme look at this new one. |
13:53:59 | FromDiscord | <Zachary Carter> in the cpp code I mean - but why Nim generates what it does - where it creates an uninitialized File object, I'm not sure how to avoid |
13:54:15 | FromDiscord | <Zachary Carter> Here's the impl for that header btw - https://github.com/guillaumeblanc/ozz-animation/blob/master/src/base/io/stream.cc |
13:54:16 | disruptek | when you import the constructor, change the pattern. |
13:54:33 | FromDiscord | <Zachary Carter> to what? |
13:54:42 | disruptek | i dunno, the docs tell you how to construct it. |
13:54:52 | disruptek | at least, i think it's in the docs. |
13:55:00 | disruptek | i might have read the compiler. |
13:55:08 | * | lritter joined #nim |
13:55:33 | disruptek | https://nim-lang.org/docs/manual.html#importcpp-pragma-namespaces |
13:55:52 | FromGitter | <jarv_gitlab> Hello I am brand new to nim and have what I hope is a simple question. In a program I want to create a table where the keys are strings and the values are procs. The functions have side-effects and after reading about how nim handles functions with side-effects I am expecting this to work but it doesn't. https://play.nim-lang.org/#ix=2qMi Is it valid to use a table like this? Why am I seeing an error only when |
13:55:52 | FromGitter | ... line#4 is commented out? |
13:56:20 | FromDiscord | <Zachary Carter> https://nim-lang.org/docs/manual.html#importcpp-pragma-wrapping-constructors - is pretty much what I'm doing |
13:56:22 | FromDiscord | <Rika> welcome |
13:56:33 | FromDiscord | <Zachary Carter> Hi jarv_gitlab |
13:56:37 | FromDiscord | <Rika> one moment, ill look into the code |
13:56:59 | FromDiscord | <kodkuce> sent a code paste, see https://play.nim-lang.org/#ix=2qMj |
13:57:38 | FromDiscord | <Rika> kodkuce i dont see why not |
13:57:56 | disruptek | that bot translation needs to be fixed. |
13:58:02 | disruptek | Yardanico: ^ |
13:58:21 | FromDiscord | <Rika> @jarv_gitlab: i dont think the link is correct? i dont see any table code |
13:58:28 | FromDiscord | <Rika> maybe you miscopied? |
13:58:32 | disruptek | put the question in a comment block, please and thank you. |
13:58:54 | FromGitter | <jarv_gitlab> @rika sorry I think it was a bad paste https://play.nim-lang.org/#ix=2qMf is the right link |
13:58:56 | FromDiscord | <kodkuce> i think too its legit but was like meybe i duno something so wanted to confirm |
13:59:08 | disruptek | you have to await the sleepAsyncs. |
13:59:36 | FromDiscord | <kodkuce> yep sorry frogot to write that in question |
13:59:46 | * | waleee-cl joined #nim |
13:59:52 | FromDiscord | <Rika> @jarv_gitlab: it will work if you use debugEcho instead |
14:00:07 | disruptek | well, i'm not sure i understand the question. |
14:00:33 | disruptek | the stuff gets destroyed at the end of scope. |
14:00:53 | FromDiscord | <Rika> @kodkuce i think it should work just fine |
14:01:14 | FromDiscord | <Zachary Carter> ohhh I think I maybe understand what I'm doing incorrectly |
14:01:18 | * | haxscramper joined #nim |
14:01:21 | FromGitter | <jarv_gitlab> @rika do know why if I comment out line number #4 in https://play.nim-lang.org/#ix=2qMf the compile error goes away? |
14:02:02 | FromDiscord | <Rika> @jarv_gitlab since the echo makes the first proc not have the "nosideeffects" pragma, and the type is inferred from the first entry in the table |
14:02:33 | FromDiscord | <Rika> removing echo makes it have the nosideeffects pragma and thats inferred into the table's type |
14:02:55 | disruptek | i'm thinking of arc here. and i should point out that there's no guarantee that stuff gets destroyed at end-of-scope. it may be reaped as soon as then, let us say. |
14:03:04 | FromDiscord | <Zachary Carter> nope I'm still lost 😛 |
14:03:15 | disruptek | i think it's the pattern. |
14:03:29 | FromDiscord | <Zachary Carter> probably |
14:04:05 | shashlick | Sorry had a late night plus don't know much about c++ wrapping yet |
14:04:09 | FromGitter | <jarv_gitlab> @rika Thanks that makes more sense to me now, is there another option to explicitly set the pragma to allow side-effects for all entries in the table? |
14:04:34 | disruptek | damn, i swear it's free if you va-va-voom and he doesn't show up with a wrapper inside 30mins. |
14:05:06 | disruptek | kodkuce, what am i doing, here? |
14:06:16 | FromDiscord | <Rika> @jarv_gitlab: set the type explicitly; `let funcs: Table[string, proc()] = {` i think |
14:07:14 | * | PMunch quit (Quit: Leaving) |
14:09:14 | krux02 | Zachary Carter: I think the problem is that you create a global variable. |
14:10:21 | krux02 | put the `let f = ` into a proc main() =, and then it should work. |
14:10:32 | FromGitter | <jarv_gitlab> @rika hm, that doesn't seem to work |
14:11:44 | krux02 | @Zachary_Carter: initializing global variables at construction is simply speaking not generally possible, so it is not supported by the compiler. |
14:12:00 | krux02 | There should be an error or at least warning from the compiler though. |
14:13:00 | FromDiscord | <Rika> @jarv_gitlab: i think i know why, since the {} syntax is just syntax sugar for making an array of tuples, you'll have to make an intermediary variable i think |
14:13:56 | FromDiscord | <Zachary Carter> krux02: is there any other way I can do this? |
14:15:41 | FromDiscord | <Zachary Carter> oh I see - it's just because it's a global, let me try inside of a proc |
14:16:06 | disruptek | people here say "you's", pron. "use" or "ewes". the meaning is, "you all", as to address a group. |
14:16:24 | disruptek | is this something to preserve as historical identity of the region? culture? |
14:16:55 | FromDiscord | <Zachary Carter> that worked - thanks krux02! |
14:17:08 | Prestige | Who says "you's" ? |
14:17:27 | disruptek | people 'round philadelphia. |
14:17:54 | Prestige | Weird cultural slang |
14:18:19 | disruptek | i'm moving north next week. just been thinking about this area lately. |
14:18:28 | FromGitter | <jarv_gitlab> thanks @rika I will try experimenting a bit more to see if I can make it work, or just organize my code so the first entry has side-effects I guess |
14:18:29 | Prestige | Just like people saying yall |
14:18:38 | Prestige | Where to disruptek? |
14:19:04 | disruptek | my family has some land in vermont that i can camp on. |
14:19:48 | FromDiscord | <Zachary Carter> sounds pretty dope - as long as you have internet |
14:20:02 | disruptek | that is, as they say, the rub. |
14:20:05 | FromDiscord | <Rika> i use y'all |
14:20:11 | Prestige | Vermont sounds nice. I'm in MD but moving next summer, maybe to Oregon |
14:20:47 | disruptek | i'm sorry, but maryland is kinda the meh of the east. |
14:21:01 | Prestige | Yeah. Not a fan |
14:21:15 | FromDiscord | <Zachary Carter> if MD is the meh of the east, what is Florida? |
14:21:20 | disruptek | it's like, good think the capitol is there because otherwise... no one would fucking go. |
14:21:26 | shashlick | Thought you were going west what happened |
14:21:31 | FromDiscord | <Zachary Carter> Baltimore is cool |
14:21:40 | FromDiscord | <Zachary Carter> like a very small portion of Baltimore |
14:21:46 | disruptek | if i ever get a job, i'll go west. |
14:21:54 | FromDiscord | <Zachary Carter> I want to go to AZ - it's just soooooo expensive |
14:22:01 | disruptek | i'm too broke to move. |
14:22:02 | FromDiscord | <Zachary Carter> and my fiance wants to stay in Austin |
14:22:09 | Prestige | What job are you looking for? |
14:22:19 | disruptek | the one that lets me buy gas. |
14:22:45 | disruptek | i spent a winter in yuma. |
14:22:48 | shashlick | AZ is expensive or Austin |
14:22:58 | disruptek | it was pretty interesting. bought a lot of drugs in mexico. |
14:23:14 | disruptek | i mean, almost none. |
14:23:15 | disruptek | none. |
14:23:18 | FromDiscord | <Zachary Carter> both are expensive - but I think AZ is more expensive than Austin |
14:23:26 | disruptek | didn't buy any drugs in mexico, nope. |
14:23:31 | FromDiscord | <Zachary Carter> but I don't think either of them are as expensive as where I'm from (Northern VA) |
14:23:41 | shashlick | What's in AZ |
14:23:50 | Prestige | Dirt |
14:23:50 | disruptek | seriously. |
14:23:52 | FromDiscord | <Zachary Carter> not a lot of tech jobs that's for sure |
14:24:00 | FromDiscord | <Zachary Carter> but it's gorgeous |
14:24:08 | disruptek | north is nice, okay. |
14:24:11 | disruptek | but it's not amazing. |
14:24:14 | shashlick | @disruptek with this covid stuff you can work anywhere, just need to give an interview |
14:24:25 | FromDiscord | <Zachary Carter> you can come write mediocre Python with me |
14:24:35 | disruptek | i had to be led away in handcuffs from my last interview. |
14:24:40 | FromDiscord | <Zachary Carter> lol |
14:24:43 | disruptek | ngl, i'm not really looking forward to the next. |
14:24:51 | shashlick | Ok sober interview |
14:25:01 | FromDiscord | <Zachary Carter> do the drugs after the interview |
14:25:08 | Prestige | I'm leaving my current job soon, interviewing at a few places for a remote position |
14:25:11 | disruptek | i think i should focus on flame-retardant. |
14:25:14 | FromDiscord | <Shucks> sent a code paste, see https://play.nim-lang.org/#ix=2qMu |
14:25:28 | disruptek | cotton head to two, long sleeves, leather shoes. |
14:25:31 | disruptek | toe, two. |
14:25:34 | disruptek | too, too. |
14:26:09 | disruptek | Prestige: i wanted to ask you where and then i knew. |
14:26:09 | Prestige | What in the world happened at your last interview? |
14:26:13 | disruptek | i will fucking bury you. |
14:26:26 | FromDiscord | <Zachary Carter> lol |
14:26:32 | Prestige | What lol |
14:26:33 | disruptek | the court order says i'm not allowed to talk about it. |
14:26:42 | disruptek | especially the senator's involvement. |
14:27:09 | disruptek | i'm specifically not to mention the ants. |
14:27:58 | disruptek | but seriously, did i mention that status turned me down for an interview? |
14:28:20 | FromDiscord | <Rika> ~~expected~~ |
14:28:34 | disruptek | yeah, i'm unteachable. |
14:29:47 | shashlick | Maybe do some gigs then, you're your own boss, still have a customer to keep happy though |
14:30:19 | disruptek | where do you even go to do that? |
14:30:36 | disruptek | i've looked at some gig sites and the pay is staggeringly low due to world-wide competition. |
14:31:10 | shashlick | I'd imagine, might even be worse now |
14:31:30 | FromDiscord | <Zachary Carter> just make an app |
14:31:44 | disruptek | well, yeah; there are still like, what, 25 million unemployed? i really thought it was more. it's about 50%. |
14:33:04 | Prestige | What world you do for a job if you had your choice? |
14:33:32 | Prestige | Would* |
14:33:39 | disruptek | gigolo. |
14:33:47 | Prestige | Phone is hard to use |
14:33:59 | disruptek | is it? |
14:34:31 | Prestige | For me, yes. I miss phones with physical buttons |
14:34:31 | disruptek | i guess i'd be moving from strength to strength. |
14:36:34 | disruptek | i'm really enjoying systems programming, but i think i like pleasing women more. |
14:37:04 | * | NimBot joined #nim |
14:37:21 | FromDiscord | <Zachary Carter> there are a ton of systems programming jobs out there - especially if you don't mind coding (and are good at coding) in C/C++ |
14:37:46 | Prestige | disruptek: enjoy it while you can |
14:38:31 | disruptek | jesus, that sounds ominous. |
14:38:47 | disruptek | do you know something we don't? |
14:39:30 | disruptek | we should really have a rule against menacing in here. |
14:40:16 | FromDiscord | <exelotl> so it has come to this |
14:41:10 | Prestige | Sex stops being a super enjoyable thing after a while. I'd rather write code, or go on a jog |
14:41:37 | disruptek | how old are you? |
14:43:06 | disruptek | don't go off and make a sandwich on me. |
14:43:09 | Prestige | 26 |
14:43:17 | disruptek | either you know how old you are or you don't, right? |
14:43:38 | disruptek | two fucking minutes go by while this guy ponders his age. |
14:43:47 | disruptek | narrator: he was 26, or so he thought. |
14:43:56 | disruptek | i mean, what the actual fuck. |
14:44:00 | Prestige | Haha I was talking in another channel |
14:44:26 | disruptek | i'm 44. |
14:44:54 | disruptek | but you might say i fuck like a man half my age. |
14:45:26 | Prestige | Not really a matter of age, it will happen eventually |
14:45:44 | disruptek | i'm thinking about streaming today. |
14:45:52 | disruptek | would anyone watch? |
14:45:57 | FromDiscord | <Zachary Carter> I'm only interested if whats his name streams his chickens |
14:46:07 | disruptek | minsin56 |
14:46:11 | FromDiscord | <Zachary Carter> yeah minsin!!! |
14:46:11 | disruptek | they dude is crazy. |
14:46:42 | disruptek | did you ever watch his programming stream? |
14:46:46 | FromDiscord | <Vindaar> wow and I thought you were pretty young disruptek |
14:47:23 | disruptek | sometimes my ego amazes even myself. |
14:47:28 | FromDiscord | <Zachary Carter> I never did |
14:47:34 | FromDiscord | <Zachary Carter> but now I need to |
14:47:45 | disruptek | never? |
14:48:01 | disruptek | but you saw the chickens, right? |
14:48:43 | FromDiscord | <Zachary Carter> yeah |
14:48:46 | FromDiscord | <Zachary Carter> chickens were awesome |
14:49:05 | FromDiscord | <Zachary Carter> I'm watching one of his streams now on programming but there's no sound |
14:49:07 | FromDiscord | <Zachary Carter> dafuq |
14:49:11 | disruptek | that guy has written at least one minecraft clone with voxels. |
14:49:31 | disruptek | i don't think i've ever heard sound on his stream. |
14:49:41 | FromDiscord | <Zachary Carter> a minecraft clone with voxels? |
14:49:45 | FromDiscord | <Zachary Carter> pretty gd novel |
14:49:57 | disruptek | the point is that he's 15. |
14:50:20 | FromDiscord | <Zachary Carter> well that's pretty impressive for a 15 yo |
14:50:33 | FromDiscord | <Zachary Carter> I wasn't writing minecraft clones when I was 15 |
14:50:48 | disruptek | he's not lqdev territory, but it's good. i wonder how common it is now. |
14:51:22 | * | letto joined #nim |
14:51:42 | Oddmonger | i thought writing a lib (.so) in nim was as simple as defining some functions in a source, and then compiling it with --app:lib , but i must have missed something |
14:52:07 | Oddmonger | when i try to see the symbols with objdump , i see nothing that i've defined |
14:52:07 | FromDiscord | <Zachary Carter> you need to add the `exportc` pragma and the `dynlib` pragma |
14:52:17 | Oddmonger | ahhhh |
14:52:32 | shashlick | See Exportc and dynlib pragma |
14:53:34 | Oddmonger | hum wait i still dont have the symbols |
14:53:38 | Oddmonger | like this ? : |
14:54:29 | Oddmonger | nim c --app:lib -d:release -d:exportc -d:dynlib hellobib.nim |
14:54:53 | FromDiscord | <Zachary Carter> errr no |
14:55:10 | FromDiscord | <Zachary Carter> `exportc` and `dynlib` are pragmas you need to attach to the procs you want to export in the shared library |
14:55:32 | FromDiscord | <Zachary Carter> so `proc foo*() {.exportc, dynlib.} = echo "foo"` |
14:56:10 | Oddmonger | ah like for using C, but inversed (i have found only for C lib importing , in the doc) |
14:56:28 | Oddmonger | thank you |
14:57:25 | FromDiscord | <Zachary Carter> np! |
15:04:03 | Oddmonger | ah yes, it needs dynlib indeed it's not implicit |
15:07:41 | FromDiscord | <Zachary Carter> /.hjgb |
15:07:41 | FromDiscord | <Zachary Carter> ]'\ |
15:08:02 | disruptek | that bad, huh? |
15:13:41 | * | muffindrake quit (Quit: muffindrake) |
15:17:28 | * | kenran quit (Ping timeout: 258 seconds) |
15:17:30 | FromDiscord | <Rika> zachary has been taken over by their cat |
15:22:43 | * | audiophile_ joined #nim |
15:23:30 | * | mwbrown_ joined #nim |
15:23:38 | FromDiscord | <Zachary Carter> meow |
15:23:49 | FromDiscord | <Zachary Carter> haha I don't have any cats! just three dogs! but yeah - guaranteed it was one of them |
15:25:40 | * | mwbrown quit (Ping timeout: 240 seconds) |
15:25:40 | * | Amun_Ra quit (Ping timeout: 240 seconds) |
15:25:41 | * | audiophile quit (Ping timeout: 240 seconds) |
15:25:41 | * | mwbrown_ is now known as mwbrown |
15:25:50 | * | audiophile_ is now known as audiophile |
15:26:47 | * | Amun_Ra joined #nim |
15:33:51 | * | muffindrake joined #nim |
15:39:28 | FromDiscord | <lqdev> XD |
15:40:58 | Prestige | hm I really wish nimlsp worked better. Have to restart my lsp client every time I make changes in another file |
15:41:39 | FromGitter | <ynfle> Which editor are you using? |
15:41:48 | Prestige | neovim |
15:41:57 | FromDiscord | <lqdev> nim.nvim |
15:42:05 | FromDiscord | <lqdev> works much better |
15:43:00 | FromGitter | <ynfle> In vscode you have to manually save the file you want to have the changes updated with |
15:43:15 | Prestige | I'm using that for syntax highlighting - I use Coc for all programming so I'd like to keep the same workflow |
15:43:39 | disruptek | wait, you read in vscode but write in coc? |
15:44:05 | Prestige | nah I only use neovim w/coc |
15:44:49 | Prestige | I was replying to lqdev |
15:49:42 | * | marnix_ joined #nim |
15:50:20 | Prestige | nimlsp looks messy but the protocol seems simple enough.. just didn't want to take time away from other projects to work on it. Maybe I will |
15:50:50 | FromDiscord | <KrispPurg> anyone know the cause of this error?↵https://play.nim-lang.org/#ix=2qMS↵↵I appear to be getting it commonly when I make a http request that responds with a large json data |
15:51:08 | FromDiscord | <KrispPurg> Nim version is 1.2.2 |
15:51:47 | FromDiscord | <Rika> its a bug with using openssl it looks like |
15:51:57 | FromDiscord | <KrispPurg> huh |
15:52:59 | * | Trustable quit (Remote host closed the connection) |
15:53:05 | FromDiscord | <Rika> whats your openssl version |
15:53:49 | FromDiscord | <KrispPurg> how do I check? |
15:53:57 | FromDiscord | <Rika> uh 🙂 i dont know |
15:54:00 | FromDiscord | <Rika> haha |
15:55:15 | * | muffindrake quit (Quit: muffindrake) |
15:55:36 | * | audiophile quit (Ping timeout: 256 seconds) |
15:56:54 | FromDiscord | <KrispPurg> Found it 1.0.2.1 |
15:57:40 | FromDiscord | <Rika> i think this might be related https://github.com/openssl/openssl/issues/322 |
15:57:41 | disbot | ➥ SSL_do_handshake does not flush the write bio |
15:57:48 | FromDiscord | <Rika> only fixed in 1.1.0 |
15:58:17 | FromDiscord | <KrispPurg> I see, |
15:58:22 | FromDiscord | <KrispPurg> (edit) 'see,' => 'see.' |
15:59:04 | FromDiscord | <KrispPurg> Would Nim have to even update ssl? |
15:59:28 | FromDiscord | <Rika> what do you mean |
15:59:31 | * | Trustable joined #nim |
15:59:33 | FromDiscord | <Rika> nim doesnt bundle ssl i dont think |
16:00:13 | FromDiscord | <KrispPurg> I mean the ssl file |
16:00:23 | FromDiscord | <KrispPurg> sslleay.dll |
16:00:51 | FromDiscord | <Rika> i dont understand |
16:01:16 | FromDiscord | <KrispPurg> Never mind. |
16:01:54 | dzamo[m] | 098poiPOI)*( |
16:02:12 | FromDiscord | <Rika> another one's cat has taken over |
16:02:29 | Prestige | looks like a password |
16:03:12 | Prestige | pattern on qwerty |
16:03:24 | FromDiscord | <Rika> @dzamo did you accidentally type a password? |
16:03:38 | FromDiscord | <Rika> it might be a cat tho really |
16:04:36 | FromDiscord | <mratsim> Seems like the password of Kame Sennin |
16:05:12 | FromDiscord | <Rika> you remind me to learn shogi lol thanks i guess |
16:07:29 | FromDiscord | <mratsim> tell me if you find a good server, though i don't see where I would find the time to play :p |
16:08:16 | FromDiscord | <Synth> sent a code paste, see https://play.nim-lang.org/#ix=2qMV |
16:09:44 | FromDiscord | <mratsim> I think the docker images use Alpine :? |
16:14:08 | Prestige | I have a weird thing I'm wondering if is possible... can a template/macro be created to mimic a property of an object? Where you could say foo.bar = 5, but bar is not actually a property? |
16:14:24 | FromDiscord | <mratsim> sure |
16:14:43 | FromDiscord | <mratsim> https://github.com/status-im/nim-cookbook/blob/master/dynamic_approximating_dynamic_types.nim |
16:14:46 | FromDiscord | <mratsim> here you go |
16:15:07 | Prestige | Thanks, I'll give it a read |
16:15:23 | FromDiscord | <Clyybber> I think what you want is a setter proc |
16:15:26 | FromDiscord | <Clyybber> or template |
16:15:42 | disruptek | agree. |
16:15:48 | FromDiscord | <Clyybber> https://nim-lang.github.io/Nim/manual#procedures-properties |
16:16:12 | Prestige | oh perfect |
16:16:16 | Prestige | Ty ty |
16:16:26 | FromDiscord | <mratsim> yes this is preferable if it fits your needs |
16:16:44 | FromDiscord | <mratsim> my solution is if "bar" is also only known at runtime |
16:18:00 | Prestige | is the inline pragma needed? |
16:18:32 | FromDiscord | <mratsim> it's never needed |
16:19:02 | FromDiscord | <mratsim> but here it avoids a function call and allows the compiler to do constant propagation if the value you set is known at compile-time |
16:19:23 | FromDiscord | <mratsim> + various other optimizations that are not possible if what you o is hidden behind a proc |
16:19:30 | * | audiophile joined #nim |
16:21:06 | * | muffindrake joined #nim |
16:25:04 | * | nkoza joined #nim |
16:27:42 | * | kitech1 quit (Quit: ZNC 1.7.5 - https://znc.in) |
16:28:02 | * | kitech1 joined #nim |
16:30:52 | audiophile | guise, is there any reason to create a wrapper when a c library exists and that can be interfaced with nim right? |
16:32:08 | FromDiscord | <Rika> thats what a wrapper is is it not? |
16:32:18 | FromDiscord | <Rika> you wrap c libraries for nim usage |
16:33:39 | shashlick | wrapping basically means to tell Nim what functionality the C library offers |
16:33:46 | shashlick | types, consts, procs |
16:39:21 | * | waleee-cl quit (Quit: Connection closed for inactivity) |
16:39:26 | * | audiophile_ joined #nim |
16:39:50 | * | fredrikhr quit (Ping timeout: 246 seconds) |
16:42:49 | * | audiophile quit (Ping timeout: 264 seconds) |
16:42:53 | * | audiophile_ is now known as audiophile |
16:43:27 | * | nsf joined #nim |
16:44:20 | * | dddddd quit (Ping timeout: 256 seconds) |
16:45:28 | * | audiophile is now known as Roomba |
16:45:32 | * | Roomba is now known as audiophile |
16:46:20 | * | Trustable quit (Remote host closed the connection) |
16:46:58 | * | nkoza quit (Remote host closed the connection) |
16:56:56 | * | Vladar quit (Quit: Leaving) |
17:01:01 | FromDiscord | <exelotl> it would be nice if we had some way to allow `+=` and stuff with getter/setter procs |
17:01:16 | FromDiscord | <Rika> wdym? is it not possible |
17:01:41 | FromDiscord | <Rika> ```proc `+=`(dest: var T, val: T) = discard```↵? |
17:03:47 | FromDiscord | <exelotl> no, like `foo.x += 1` when you have``` proc x(a:T): int ``` and ``` proc `=x`(a:T, v:int) ``` |
17:04:08 | FromDiscord | <Rika> `proc x(a:var T): var T`? |
17:04:15 | FromDiscord | <exelotl> (edit) '`=x`(a:T,' => '`x=`(a:T,' |
17:04:53 | FromDiscord | <Rika> then you can do `a.x = 2` or w/e that takes in a var T |
17:05:02 | FromDiscord | <Rika> i mean var U for a's type btw |
17:05:13 | FromDiscord | <lqdev> that's not what he means |
17:05:41 | FromDiscord | <Rika> you only want +=? |
17:05:44 | FromDiscord | <lqdev> he means that if you have a setter and getter you cannot use the compound assignment operators += etc. |
17:05:45 | FromDiscord | <Rika> maybe not possible |
17:05:58 | FromDiscord | <Rika> eh? really? i was pretty sure you could |
17:06:01 | FromDiscord | <Recruit_main707> Cant you do proc 'x+='(... |
17:06:05 | FromDiscord | <Rika> no |
17:06:48 | FromDiscord | <exelotl> something like that might be nice... I'm pretty sure it doesn't exist currently |
17:06:57 | FromDiscord | <Rika> https://play.nim-lang.org/#ix=2qN4 ??? |
17:07:01 | FromDiscord | <Rika> i just did it |
17:07:22 | FromDiscord | <Rika> += is just a 2 arg no ret proc with arg 0 being var T and arg 1 being T |
17:07:32 | FromDiscord | <Rika> a getter that returns a var T will work with += |
17:08:10 | FromDiscord | <exelotl> I see, that's cool, but unfortunately my getter can't return var T |
17:08:11 | FromDiscord | <Rika> its also how mitems works i think |
17:08:22 | FromDiscord | <Rika> oh? then cant do anything about it i dont think |
17:08:36 | FromDiscord | <Rika> you can make two getters with arg 0 nonvar T and var T |
17:08:48 | FromDiscord | <Recruit_main707> Never understood getters and setters point unless you are interopig |
17:08:56 | FromDiscord | <Recruit_main707> interoping* |
17:08:57 | FromDiscord | <Rika> if not possible then RIP cant do anything about that |
17:09:14 | FromDiscord | <Rika> getters are nice if you want to limit access and stuff |
17:09:29 | FromDiscord | <Rika> w/o using "olden" names like getX and setX or so |
17:09:58 | FromDiscord | <Rika> though ara q still likes them for some reason, but /shrug he prolly has a very good reason to use them that i dont know |
17:10:52 | FromDiscord | <exelotl> here's an example of the thing I wish could have += |
17:10:54 | FromDiscord | <exelotl> https://github.com/exelotl/natu/blob/master/natu/private/oam.nim#L242 |
17:11:16 | FromDiscord | <lqdev> @Recruit_main707 well they make it possible to make fields immutable outside of the declaring module |
17:11:39 | FromDiscord | <lqdev> you simply make it private, create a getter and don't export it |
17:11:41 | FromDiscord | <Rika> wait, you're adding a bool? huh? |
17:11:53 | FromDiscord | <lqdev> s/don't// |
17:11:57 | FromDiscord | <Rika> ah thats converted to an int |
17:12:06 | FromDiscord | <exelotl> it's a bitwise and |
17:12:14 | FromDiscord | <Rika> sadly i dont think you can var'ify that |
17:14:18 | FromDiscord | <Clyybber> you can still do it |
17:14:28 | FromDiscord | <Clyybber> but you need to define a += |
17:14:42 | * | theelous3 joined #nim |
17:14:47 | FromDiscord | <Rika> i dont see how... |
17:15:05 | FromDiscord | <exelotl> you'd have to make an untyped += macro that checks for the presence of getter/setter procs, right? |
17:15:10 | FromDiscord | <Clyybber> yeah |
17:15:26 | FromDiscord | <exelotl> sounds ugly but might be worth a try one day xD |
17:15:31 | FromDiscord | <Clyybber> it doesn't have to be untyped actually |
17:15:46 | FromDiscord | <Clyybber> you can make it typed but check the LHS |
17:15:53 | FromDiscord | <Clyybber> which will be the getter |
17:15:53 | FromDiscord | <exelotl> ah true |
17:15:58 | FromDiscord | <Clyybber> from that you could get the setter |
17:16:37 | FromDiscord | <Rika> sounds painful 😛 |
17:16:59 | FromDiscord | <exelotl> another solution in my case, could be to redefine my datatype to use the {.bitsize.} pragma instead of getters/setters |
17:17:05 | FromDiscord | <exelotl> https://nim-lang.org/docs/manual.html#implementation-specific-pragmas-bitsize-pragma |
17:17:31 | FromDiscord | <exelotl> that would mean breaking compatibility with the underlying C types from the library that I'm wrapping |
17:17:47 | FromDiscord | <exelotl> but it could work out OK I guess |
17:20:08 | * | nkoz joined #nim |
17:21:57 | * | theelous3_ joined #nim |
17:31:24 | * | rokups quit (Quit: Connection closed for inactivity) |
17:42:08 | * | endragor quit (Remote host closed the connection) |
17:42:48 | * | endragor joined #nim |
17:42:56 | * | endragor quit (Remote host closed the connection) |
17:43:03 | * | endragor joined #nim |
17:45:57 | krux02 | I have the feeling more and more people migrate to discord |
17:46:22 | disruptek | i'm blocking it and gitter more often. |
17:46:42 | krux02 | blocking? |
17:46:54 | disruptek | well, filtering it out with /ignore. |
17:47:17 | krux02 | ah that you mean. |
17:47:21 | krux02 | No I don't do that. |
17:47:54 | krux02 | I just realized there is a trend towards discord because everything within an houre was discord only |
17:48:22 | disruptek | see, that's the stuff i want to ignore. 😉 |
17:48:58 | FromDiscord | <Clyybber> :( |
17:49:14 | FromDiscord | <Clyybber> Araq: ping |
17:50:36 | FromDiscord | <Clyybber> Araq: Having an issue where the int `f` in `f += 1` is not an nkHiddenAddr when the call arrives in ccgcalls.nim; how can that be? |
17:52:06 | FromDiscord | <Clyybber> its nkSym directly |
17:52:23 | FromDiscord | <Clyybber> krux02: Do you know how that could possibly happen? |
17:52:57 | krux02 | I don't know it. |
17:52:59 | krux02 | maybe it is a bug. |
17:53:31 | FromDiscord | <Clyybber> would be a really big one :D |
17:53:33 | * | a_chou joined #nim |
17:58:47 | * | a_chou quit (Remote host closed the connection) |
18:00:22 | * | synshroud joined #nim |
18:01:59 | * | a_chou joined #nim |
18:03:13 | * | vr0n joined #nim |
18:05:47 | * | a_chou quit (Client Quit) |
18:08:47 | * | audiophile quit (Quit: Default Quit Message) |
18:18:48 | FromDiscord | <kodkuce> if i want to random betwin 500 and 750, i cant rand(500, 750) and there is no shorcut right, only soultuon is to 500+rand(250) ? |
18:20:16 | Jjp137 | you can do rand(500..750) |
18:20:19 | FromDiscord | <Rika> rand 500..750 i think? |
18:21:41 | FromDiscord | <kodkuce> oh, would that be inefficient like isent that liek creating an inerator/array of 250ints ? |
18:22:02 | FromDiscord | <Rika> it is not |
18:22:21 | FromDiscord | <Rika> 500..750 creates a Slice object with 2 ints, 500 and 750 |
18:22:24 | FromDiscord | <Rika> thats it |
18:24:17 | FromDiscord | <kodkuce> ok 🙂 |
18:27:24 | FromDiscord | <Shucks> could I unpack a sequence? e.g.: `var a, b = @[1, 2].unpack` |
18:28:19 | FromGitter | <ynfle> !repo unpack |
18:28:20 | disbot | https://github.com/technicallyagd/unpack -- 9unpack: 11sequence/object unpacking/destructuring for nim 15 29⭐ 0🍴 7& 2 more... |
18:38:56 | FromGitter | <ynfle> @Shucks, does that help? |
18:41:02 | FromDiscord | <Shucks> Yea was hoping for something built in |
18:52:50 | * | audiophile joined #nim |
18:59:44 | * | krux02 quit (Remote host closed the connection) |
19:03:59 | * | go|dfish quit (Ping timeout: 256 seconds) |
19:16:27 | * | nsf quit (Quit: WeeChat 2.8) |
19:17:31 | * | kenran joined #nim |
19:17:35 | * | go|dfish joined #nim |
19:19:44 | * | dddddd joined #nim |
19:23:01 | * | marnix quit (Ping timeout: 264 seconds) |
19:31:01 | vr0n | is there a way with nim-prompt to auto-clear the screen? prompt.clear() doesn't throw an error, but it also doesn't do anything |
19:33:32 | * | synshroud quit (Quit: ZNC 1.7.5 - https://znc.in) |
19:37:25 | FromDiscord | <Vindaar> vrOn: never used that library, but just had a short look at the code. did you redraw after `clear`? |
19:39:56 | FromDiscord | <Vindaar> ups, vr0n^ |
19:39:58 | vr0n | i didn't, but i when i just tried the redrawPrompt() command, i got a unicode error.... that's odd |
19:40:09 | vr0n | thank you, though. that is a tleast a start. i think i might be missing a required library |
19:40:20 | * | audiophile_ joined #nim |
19:40:47 | FromDiscord | <Vindaar> hm, curious |
19:41:29 | vr0n | says error is coming from: .nimble/pkgs/unicodedb-0.9.0 |
19:44:02 | * | audiophile quit (Ping timeout: 264 seconds) |
19:44:02 | * | audiophile_ is now known as audiophile |
19:45:04 | * | marnix joined #nim |
19:46:14 | * | marnix_ quit (Ping timeout: 256 seconds) |
19:48:13 | * | fredrikhr joined #nim |
19:50:22 | * | audiophile quit (Quit: Default Quit Message) |
19:50:41 | FromDiscord | <Varriount> Is this a compiler error, or a runtime one? |
19:51:05 | * | marnix_ joined #nim |
19:51:19 | FromDiscord | <Vindaar> and do you have a snippet that reproduces the problem? |
19:54:14 | * | marnix quit (Ping timeout: 240 seconds) |
19:54:32 | * | marnix_ is now known as marnix |
20:21:12 | * | abm quit (Quit: Leaving) |
20:24:11 | * | marnix quit (Ping timeout: 246 seconds) |
20:31:42 | * | waleee-cl joined #nim |
20:33:16 | * | vicfred joined #nim |
20:35:39 | vr0n | compiler |
20:35:50 | vr0n | one sec, ill post a pastebin link |
20:36:22 | * | fanta1 quit (Quit: fanta1) |
20:38:00 | * | haxscramper quit (Remote host closed the connection) |
20:46:17 | * | sknebel quit (Quit: No Ping reply in 180 seconds.) |
20:46:51 | * | sknebel joined #nim |
20:49:14 | FromDiscord | <kodkuce> why stupit vscode color .high on seq i hate it am allwies typing .len-1 just to envade it |
20:49:42 | * | solitudesf quit (Ping timeout: 256 seconds) |
20:49:53 | FromDiscord | <Rika> wdym? |
21:01:18 | * | pietroppeter quit (Quit: Connection closed for inactivity) |
21:05:41 | shashlick | who wants a 57k line wrapper of gtk+-3.0 |
21:05:44 | FromDiscord | <Elegant Beef> Are you using nim-alt or the official nim? |
21:05:48 | FromDiscord | <Elegant Beef> Uhh |
21:05:50 | FromDiscord | <Elegant Beef> Not me |
21:05:58 | disruptek | amateur. |
21:06:25 | shashlick | takes 7 seconds to generate but for some reason, Nim takes 70 seconds to compile it |
21:06:44 | shashlick | 5k const values but still doesn't explain it |
21:06:44 | disruptek | get a real computer. |
21:06:51 | FromDiscord | <Elegant Beef> Give your nim VM some cocaine, to speed it up |
21:07:12 | FromDiscord | <kodkuce> sorry was alt tab and no headphones on head 🙂 , i am ussing offical nim |
21:07:22 | FromDiscord | <Elegant Beef> Try nim alt for nicer highlighting |
21:07:48 | FromDiscord | <Elegant Beef> https://media.discordapp.net/attachments/371759389889003532/728718658620096512/unknown.png |
21:08:13 | FromDiscord | <kodkuce> https://media.discordapp.net/attachments/371759389889003532/728718761171091477/simplescreenrecorder-2020-07-03_23.06.17.webm |
21:08:20 | FromDiscord | <kodkuce> ye atm i get this shit one |
21:10:04 | FromDiscord | <kodkuce> i need to unstiall officla right? |
21:10:47 | FromDiscord | <Elegant Beef> Probably |
21:11:22 | FromDiscord | <kodkuce> yep got it working |
21:12:34 | * | a_chou joined #nim |
21:12:56 | shashlick | https://gist.github.com/genotrance/755a1aff57989840f867a03015592aa8 |
21:13:17 | shashlick | that was good - fixed some nimterop bugs in the process |
21:15:13 | * | a_chou quit (Client Quit) |
21:25:59 | * | vicfred quit (Quit: Leaving) |
21:26:13 | * | theelous3 quit (Quit: is outty) |
21:26:14 | * | theelous3_ quit (Quit: is outty) |
21:29:53 | * | hyiltiz_ joined #nim |
21:39:11 | FromDiscord | <Technisha Circuit> Is there a module that allows interfacing with Nim with Java that generates a jar file? |
21:39:34 | * | kenran quit (Ping timeout: 256 seconds) |
21:42:21 | FromDiscord | <codic> Just why |
21:43:14 | FromDiscord | <codic> There's something called JNim, https://github.com/yglukhov/jnim, but that allows you to use Java from Nim, not vice versa, and does not generate a JAR |
21:43:23 | FromDiscord | <Technisha Circuit> Oh okay |
21:43:35 | FromDiscord | <codic> You can wrap the C functions exported by Nim's compile-to-C target in a header and use that with JNI |
21:43:38 | FromDiscord | <Technisha Circuit> How would i use it to make an MC plugin? :P |
21:43:40 | FromDiscord | <codic> (edit) 'You can wrap the C functions exported by Nim's compile-to-C target in a header and use that with JNI ... ' => 'You can wrap the C functions exported by Nim's compile-to-C target in a header and use that with JNIto use NIm from C' |
21:43:42 | FromDiscord | <codic> (edit) 'NIm' => 'Nim' |
21:43:51 | FromDiscord | <codic> Uh, I don't think you can |
21:43:59 | FromDiscord | <codic> That doesn't run on the JVM, it only interfaces with the JVM |
21:44:09 | FromDiscord | <Technisha Circuit> Damn ir |
21:44:10 | FromDiscord | <Technisha Circuit> It* |
21:44:15 | FromDiscord | <codic> I don't think there's a version of nim that runs on the JVM |
21:44:52 | FromDiscord | <Technisha Circuit> Note to self, make an easier way to generate a jar file from Nim code using Jnim |
21:45:06 | FromDiscord | <codic> That's impossible... |
21:45:14 | FromDiscord | <codic> You'd need to rewrite Nim to run on the JVM |
21:45:18 | FromDiscord | <codic> You can't use Jnim for that |
21:45:40 | * | thomasross joined #nim |
21:45:59 | FromDiscord | <codic> I'm pretty sure you couldn't, at least |
21:46:51 | FromDiscord | <Technisha Circuit> Hm |
21:46:54 | shashlick | Why does it need to run on the jvm |
21:47:13 | FromDiscord | <Technisha Circuit> For a making a Minecraft plugin :P |
21:47:29 | shashlick | You just want it to be callable by Java right |
21:47:54 | FromDiscord | <codic> Minecraft plugins have to be jar files |
21:48:04 | FromDiscord | <codic> At least with most of the popular plugin engines |
21:48:18 | shashlick | Sure that doesn't mean it has to run in the jvm |
21:48:25 | FromDiscord | <codic> Yeah |
21:48:30 | FromDiscord | <Technisha Circuit> I'm planning on doing it with spigot |
21:48:35 | FromDiscord | <codic> As long as it's a working JAR, I guess |
21:48:40 | FromDiscord | <codic> But aren't all JARs running on the jvm? |
21:48:49 | FromDiscord | <codic> Unless they aren't jars and just have the wrong file extension |
21:49:00 | FromDiscord | <codic> Since jars depend on the jvm to run |
21:49:01 | FromDiscord | <Technisha Circuit> > You just want it to be callable by Java right↵As long as i can actually interface with the spigot plugin api |
21:49:12 | FromDiscord | <codic> Wait |
21:49:40 | FromDiscord | <codic> Write java code that uses JNI to interface with C compiled from Nim, and use the plugin API in that Nim using Jnim |
21:49:49 | FromDiscord | <codic> That will 999999999% not work |
21:49:52 | FromDiscord | <codic> Aka your speciality |
21:49:57 | FromDiscord | <Technisha Circuit> Lmao |
21:50:11 | FromDiscord | <Technisha Circuit> Thanks for the confidence boost man- |
21:50:33 | FromDiscord | <codic> If that works, you can wrap it in an API↵I'm saying that you get stuff that isn't supposed to work to work, that's good :p |
21:50:54 | FromDiscord | <Technisha Circuit> G: xD |
21:50:59 | FromDiscord | <Technisha Circuit> (edit) removed 'G:' |
21:51:15 | FromDiscord | <Technisha Circuit> So, you wanna help me do this stupid thing then?- |
21:51:31 | FromDiscord | <codic> Sure? |
21:51:36 | FromDiscord | <Rika> not gonna lie |
21:51:50 | FromDiscord | <Rika> internally (in my head) Technisha and codic are one person |
21:52:07 | FromDiscord | <Rika> it sure sounds like you two are one person |
21:52:11 | FromDiscord | <Technisha Circuit> We aren't xD |
21:52:24 | FromDiscord | <codic> What if one of the accounts is just an alt account |
21:52:25 | FromDiscord | <Technisha Circuit> I'm an idiot |
21:52:27 | FromDiscord | <Rika> i have a difficult time believing that |
21:52:29 | FromDiscord | <Technisha Circuit> He isn't |
21:52:31 | FromDiscord | <codic> Welp |
21:52:32 | FromDiscord | <Technisha Circuit> Lmao |
21:52:48 | FromDiscord | <codic> (edit) 'account' => 'account?' |
21:52:52 | FromDiscord | <Technisha Circuit> So myself, wanna help me- |
21:52:59 | FromDiscord | <codic> @Technisha Circuit You are an idiot |
21:53:03 | FromDiscord | <codic> There, I just called myself an idiot |
21:53:10 | FromDiscord | <Technisha Circuit> Thank you me :) |
21:53:24 | FromDiscord | <codic> No problem me! |
21:54:11 | FromDiscord | <Technisha Circuit> How is it where i live myself? |
21:54:39 | FromDiscord | <Technisha Circuit> I think we broke @Rika via confusion- |
21:54:52 | FromDiscord | <Technisha Circuit> And i honestly wouldn't be surprised lmao |
21:54:54 | * | pietroppeter joined #nim |
21:55:12 | * | hyiltiz_ quit (Quit: hyiltiz_) |
21:56:27 | FromDiscord | <Technisha Circuit> Oof Codic isn't responding- |
21:56:51 | FromDiscord | <Rika> no i'm just trying to figure out my application's plugin system |
21:57:06 | FromDiscord | <Technisha Circuit> O |
21:57:08 | FromDiscord | <Technisha Circuit> Oki |
21:59:02 | FromDiscord | <Technisha Circuit> Oh YeAh ThAt'S mY aLt GuYs- |
22:00:54 | * | fanta1 joined #nim |
22:05:12 | * | arecaceae quit (Remote host closed the connection) |
22:05:45 | * | arecaceae joined #nim |
22:11:54 | vr0n | sorry for the delay. Here is a link to the code itself: https://pastebin.com/9aWKK9Da |
22:12:08 | vr0n | and the nimble file: https://pastebin.com/WZ34Z9gM |
22:12:33 | vr0n | the issue is with the proc "main" when i call prompt.clear() |
22:12:53 | vr0n | (this is the issue with unicodedb error from earlier. Sorry it took so long, I had to step out |
22:30:30 | * | krisppurg joined #nim |
22:30:46 | * | stefantalpalaru_ joined #nim |
22:32:47 | * | stefantalpalaru quit (Ping timeout: 272 seconds) |
22:35:22 | * | sschwarzer joined #nim |
22:36:26 | * | sschwarzer quit (Client Quit) |
22:37:03 | * | stefantalpalaru_ is now known as stefantalpalaru |
22:37:16 | * | stefantalpalaru quit (Changing host) |
22:37:16 | * | stefantalpalaru joined #nim |
22:39:49 | * | a_chou joined #nim |
22:40:55 | * | a_chou quit (Client Quit) |
22:41:17 | * | a_chou joined #nim |
22:45:13 | * | a_chou quit (Client Quit) |
23:11:12 | FromDiscord | <codic> yes i'm totally @Technisha Circuit's alt /s |
23:12:09 | FromDiscord | <Technisha Circuit> xD |
23:12:38 | FromDiscord | <Technisha Circuit> Okay me, let's get the Spigot plugin in Nim working! |
23:13:22 | FromDiscord | <codic> I'm not doing it now |
23:15:08 | FromDiscord | <codic> Sorry |
23:15:10 | FromDiscord | <codic> (edit) 'Sorry' => 'Sorry, me' |
23:16:33 | * | nikita` quit (Quit: leaving) |
23:20:42 | FromDiscord | <Technisha Circuit> Oof okay me |
23:22:54 | * | fanta1 quit (Quit: fanta1) |
23:31:12 | FromDiscord | <demotomohiro> @lmariscal↵This PR has been merged to nimgl/imgui but not to nimgl/nimgl repository.↵https://github.com/nimgl/imgui/pull/2 |
23:31:13 | disbot | ➥ Fix compile error from nim cpp tests/test.nim |
23:43:54 | * | fredrikhr quit (Ping timeout: 240 seconds) |
23:44:38 | * | nkoz quit (Ping timeout: 264 seconds) |
23:50:24 | * | NimBot joined #nim |
23:56:59 | FromDiscord | <𝓑𝓮𝓷𝓾𝓶𝓫𝓮𝓭> Hey a while back I could have sworn I saw a list of needed/wanted Nim libraries/integrations, but for the life of me I can't find it. Does anyone know what I'm talking about and have a link? |
23:59:42 | FromDiscord | <exelotl> oh yeah that sounds familiar... |