00:05:20 | FromGitter | <zetashift> ah yes nkNone indicates an error |
00:15:29 | * | kapil____ joined #nim |
00:21:43 | * | elrood quit (Remote host closed the connection) |
00:24:44 | * | seni_ quit (Quit: Leaving) |
00:26:06 | FromGitter | <zacharycarter> genotrance: are you around by any chance? |
00:26:26 | FromGitter | <zacharycarter> wait |
00:26:31 | FromGitter | <zacharycarter> nevermind |
00:26:48 | FromGitter | <zacharycarter> don't want to bug you about this - I think I can figure it out via other example repos you've put up |
00:31:37 | FromGitter | <zacharycarter> maybe not :/ |
00:33:37 | FromGitter | <zacharycarter> or if anyone else is good with nimgen and cpp |
00:39:46 | FromGitter | <zacharycarter> shashlick: just in case you're on this irc (which is probably more likely :P) |
01:01:54 | * | leorize quit (Quit: "") |
01:02:03 | * | jose122 joined #nim |
01:02:12 | * | jose122 quit (Quit: Page closed) |
01:08:54 | FromGitter | <zacharycarter> ooph - yeah - going to give up on this for now I think so it doesn't block me |
01:09:11 | FromGitter | <zetashift> whatchu up to? |
01:09:37 | FromGitter | <zacharycarter> trying to use nimgen to create bindings to - https://github.com/Auburns/FastNoiseSIMD |
01:09:42 | FromGitter | <zacharycarter> having troubles though |
01:15:19 | FromGitter | <zacharycarter> keep running into errors like - |
01:15:23 | * | Snircle quit (Quit: Textual IRC Client: www.textualapp.com) |
01:15:32 | FromGitter | <zacharycarter> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5bdf99b4b9c9191954a1606b] |
01:17:37 | FromGitter | <zacharycarter> https://gist.github.com/zacharycarter/9c61ce86123ab597ec0e43f493323862 |
01:17:40 | FromGitter | <zacharycarter> is what my cfg looks like |
01:19:31 | FromGitter | <zacharycarter> ah - I fixed one issue that was pretty obvious, and now i have a whole new slew of errors :D |
01:27:31 | * | Snircle joined #nim |
01:29:46 | shashlick | Sorry buddy on the road |
01:29:54 | shashlick | Will check back in 3 hours I think |
01:30:51 | FromGitter | <zacharycarter> cool! no rush and safe travels! |
01:34:33 | shashlick | What does your generated Nim look like |
01:34:54 | shashlick | Seems like the cpp files are not compiled on |
01:34:55 | shashlick | In |
01:38:56 | FromGitter | <zacharycarter> yeah - not quite sure what I'm doing - I'll wait till your free and keep playing around till then |
01:42:26 | * | Aareon_ quit (Ping timeout: 260 seconds) |
01:43:22 | shashlick | Are there any compile entries in the generated Nim |
01:43:29 | shashlick | Can you gist that |
01:56:04 | FromGitter | <zacharycarter> yes |
01:56:06 | FromGitter | <zacharycarter> one sec |
01:56:14 | FromGitter | <zacharycarter> I will gist everything I have |
01:59:14 | FromGitter | <zacharycarter> shashlick: https://gist.github.com/zacharycarter/9c61ce86123ab597ec0e43f493323862 |
02:02:18 | * | Aareon_ joined #nim |
02:16:02 | shashlick | The init000 symbols come from the Nim main proc |
02:16:13 | shashlick | Don't see why those aren't found |
02:17:13 | shashlick | How come foo.o is not in the final link command |
02:17:21 | FromGitter | <gogolxdong> @PMunch Is your protobuf library production-ready? |
02:17:27 | FromGitter | <zacharycarter> okay I think I am making progress |
02:21:21 | * | endragor joined #nim |
02:22:38 | FromGitter | <zacharycarter> I think it has to do with me missing -mavx2 |
02:23:44 | shashlick | Cool |
02:24:03 | shashlick | Well nice to see another nimgen wrapper |
02:25:16 | * | theelous3_ quit (Ping timeout: 268 seconds) |
02:27:44 | FromGitter | <zacharycarter> ugh nm |
02:27:55 | FromGitter | <timotheecour> anyone familiar with nimsuggest? |
02:27:57 | FromGitter | <zacharycarter> back and forth b/w the error in the gist and this new onw |
02:32:36 | FromGitter | <zacharycarter> lol shashlick: it was because the nim file was named the same as the header / cpp file |
02:32:47 | FromGitter | <zacharycarter> renamed the nim file - it compiles now |
02:37:28 | shashlick | Got overwritten |
02:37:57 | shashlick | I had to add some code to nimgen to handle files it processed |
02:38:24 | shashlick | But can't do much with consumers 🙂 |
02:41:03 | shashlick | Interesting nonetheless |
02:41:36 | shashlick | Should open an issue with Nim to notify that object files got over written |
02:41:44 | shashlick | Or avoid it by renaming |
02:42:08 | * | endragor quit (Remote host closed the connection) |
02:42:34 | * | endragor joined #nim |
02:45:40 | * | endragor quit (Remote host closed the connection) |
02:50:15 | FromGitter | <kdheepak> @shashlick you can try ssh-ing into travis for more information, and interactively debug. |
03:05:18 | * | banc quit (Quit: ZNC - http://znc.in) |
03:09:47 | FromGitter | <zacharycarter> it seems to be working? |
03:10:20 | FromGitter | <zacharycarter> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5bdfb49c995818347ba4a7a1] |
03:16:21 | FromGitter | <gogolxdong> Got could not load: libpq.dll , I have placed it into the working directory. |
03:20:35 | * | banc joined #nim |
03:26:22 | FromGitter | <zacharycarter> wewt! got it working |
03:26:37 | FromGitter | <zacharycarter> SIMD fast noise woot! going to be awesome for terrain gen |
03:35:17 | shashlick | @kdeepak: I just ran it locally with docker |
03:35:31 | shashlick | But ssh is a good idea |
04:02:11 | xace | does the example in https://github.com/yglukhov/nimpy # work for anyone? the calling python from nim example, i get this error: nimpy-0.1.0/nimpy/py_utils.nim(75, 46) Error: type mismatch: got <NimNode> |
04:02:13 | * | Snircle quit (Quit: Textual IRC Client: www.textualapp.com) |
04:07:27 | * | chemist69 quit (Ping timeout: 252 seconds) |
04:09:14 | * | chemist69 joined #nim |
04:23:25 | xace | Hmm, this machine was running nim 0.18.0, turns out that was the problem |
05:23:35 | * | nsf joined #nim |
06:54:52 | * | krux02 joined #nim |
06:59:29 | * | mech422_ joined #nim |
07:01:52 | * | leorize joined #nim |
07:02:46 | * | mech422__ quit (Ping timeout: 268 seconds) |
07:14:36 | * | kapil____ quit (Quit: Connection closed for inactivity) |
07:15:49 | * | itschin joined #nim |
07:32:58 | livcd | what cross platform http server would you recommend as of now ? |
07:43:37 | Araq | httpbeast? |
07:43:55 | Araq | always use a proxy for security though :-) |
07:50:14 | * | vlad1777d joined #nim |
07:51:40 | * | Vladar joined #nim |
08:10:15 | * | PMunch joined #nim |
08:13:29 | * | vlad1777d quit (Remote host closed the connection) |
08:27:45 | FromGitter | <admin0day> do we have the pkg about sendgrid? |
08:29:47 | FromGitter | <admin0day> cause i want to use the api of sendgrid to send the email avoid the Mail service provider's filter |
08:34:53 | krux02 | admin0day never heared about sendgrid, just reading about it. Is that a spam filter circumvention service? |
08:36:11 | krux02 | "45 billion emails every month" sounds like a huge spam factory |
08:41:14 | FromGitter | <admin0day> yeah,google and tencent's mail service only allow the same provider to send the email to themself,so if my platform using the difference provider to send the email,it will return back or send it to them trash |
08:43:25 | PMunch | Hmm, that's annoying Sublimes LSP client sends a completion request before sending a didChange notification.. |
08:43:50 | PMunch | So when I return my completion it has already changed the document.. |
09:00:40 | FromGitter | <admin0day> do we have any pkg of the starttls,unfortunately we use the outlook email,their smtp service using the starttls |
09:01:38 | FromGitter | <admin0day> by the way do we have another protocol to send the email? |
09:08:25 | * | floppydh joined #nim |
09:11:56 | * | yonson joined #nim |
09:12:43 | * | vlad1777d joined #nim |
09:15:44 | FromGitter | <Varriount> @timotheecour I've updated several NimLime issues. |
09:21:56 | yonson | When unmarshalling a json, is there a way to have an object model with fields that are not present on the json data? |
09:22:14 | yonson | This is an example of what I'm talking about https://pastebin.com/nmRJi0LU |
09:22:40 | yonson | I'd like to have some fields of the object to be used after the unmarshalling |
09:24:42 | PMunch | Not as far as I know |
09:25:06 | PMunch | I use my jsonschema module in nimlsp to work with typed json objects |
09:25:16 | PMunch | And it supports optional fields |
09:27:43 | yonson | I see, I'll look into your module, thanks |
09:32:32 | * | stevenfx joined #nim |
09:44:21 | * | stevenfx quit (Quit: stevenfx) |
09:47:07 | * | Vladar quit (Ping timeout: 240 seconds) |
09:47:14 | * | fredrik92 is now known as couven92 |
09:48:51 | * | stevenfx joined #nim |
09:51:03 | * | stevenfx quit (Client Quit) |
09:56:34 | couven92 | PMunch, in .NET we have the NonSerializable, IgnoreDataMember and JSonIgnore annotations (depending on what serializer you use). These are really useful, I use them all the time! If we don't have, we should add them, as pragmas for example! |
09:57:51 | couven92 | Optional fields do not do the trick, because they will serialize the field if able, which is not what you want |
09:58:56 | FromGitter | <gogolxdong> where is the RSA implementation? |
09:59:49 | * | stevenfx joined #nim |
10:02:00 | PMunch | couven92, I'm pretty sure yonson wanted optional fields. But a way to ignore fields would also be a good idea |
10:02:45 | PMunch | My jsonschema module doesn't actually deserialize anything, it just checks if a JsonNode conforms to a certain schema |
10:03:06 | PMunch | And it implements compile-time field access on the distinct types, which is neat |
10:03:18 | FromGitter | <gogolxdong> Do we have an implementation of RSA? |
10:31:40 | yonson | I just realised that if I wrap the type of my desired optional field in an Option[type] then parseJson doesn't complain and just returns `None[type]` |
10:31:45 | yonson | So that works too I guess |
11:06:03 | * | stevenfx quit (Quit: stevenfx) |
11:11:11 | * | stevenfx joined #nim |
11:24:02 | FromGitter | <zacharycarter> @gogolxdong - https://github.com/joppiesaus/nimchat/blob/master/rsa.nim ? |
11:27:28 | FromGitter | <zacharycarter> seems like it'd be rather trivial to come up with a Nim implementation - https://www.geeksforgeeks.org/rsa-algorithm-cryptography/ |
11:28:22 | * | martin1_ joined #nim |
11:36:23 | FromGitter | <gogolxdong> yes,crypto is always trivial.Thanks anyway. |
11:38:16 | FromGitter | <gogolxdong> we choose Vulkan however. |
11:40:53 | FromGitter | <zacharycarter> not following haha but okay |
11:45:33 | * | Vladar joined #nim |
11:45:52 | FromGitter | <gogolxdong> sorry,jumping thinking. |
11:47:29 | FromGitter | <gogolxdong> regarding the context, using secp256k1 is easier. |
11:53:16 | FromGitter | <zacharycarter> np |
12:06:03 | * | theelous3 joined #nim |
12:16:05 | * | Snircle joined #nim |
12:34:53 | federico3 | trivial to get wrong |
12:35:16 | * | stevenfx quit (Quit: stevenfx) |
12:35:56 | * | hwallann joined #nim |
12:38:26 | * | dorelix_ joined #nim |
12:39:24 | * | dorelix quit (Read error: Connection reset by peer) |
12:45:43 | * | dddddd joined #nim |
13:27:50 | * | elrood joined #nim |
13:33:43 | * | abm joined #nim |
13:43:14 | FromGitter | <zacharycarter> well - yeah |
13:43:42 | FromGitter | <zacharycarter> I don't know what he needs exactly |
13:43:56 | FromGitter | <zacharycarter> or what his goals are - but I guess it's a non issue now |
13:46:54 | shashlick | Reminds me to wrap more portions of openssl in nimssl |
13:51:52 | FromGitter | <alehander42> @zacharycarter people are very into "don't implement your own crypto". I've read opinions(I think it was @mratsim) that this should mean "don't invent your own crypto algorithm/math", not "don't implement this existing algo", but even in the second case one still needs a lot of additional verification indeed |
13:56:16 | * | Aareon_ quit (Ping timeout: 260 seconds) |
14:00:33 | * | Aareon_ joined #nim |
14:04:15 | FromGitter | <zacharycarter> yeah - I can understand that |
14:12:05 | PMunch | Well it's a dual edged sword. On hand you don't want to make your own implementation of an algorithm in case you mess it up and leave it with a security hole in it. On the other hand we are starting to become very dependent on a few crypto implementations, so if they are ever found to be fundamentally wrong we're screwed until they are properly re-implemented. |
14:15:28 | * | nsf quit (Quit: WeeChat 2.3) |
14:23:51 | federico3 | PMunch: "your own crypto" refers to small projects/orgs and random developers. Having well maintained alternatives to OpenSSL is obviously good |
14:28:37 | * | kapil____ joined #nim |
14:46:41 | * | NimBot joined #nim |
15:06:18 | * | hwallann quit (Remote host closed the connection) |
15:26:12 | * | Trustable joined #nim |
15:34:28 | * | dom96_w joined #nim |
15:35:39 | * | krux02 quit (Remote host closed the connection) |
15:35:43 | * | krux02_ joined #nim |
15:36:31 | FromDiscord_ | <Epictek> NaCl seems like a nice crypto libary |
15:37:58 | FromGitter | <mratsim> To implement algo, you need good test vectors and master level dumpHex-fu with gdb superpower. When you’re off by one your hashes are completely different and this is super annoying |
15:38:26 | Araq | well at least you notice it quickly |
15:39:06 | FromGitter | <mratsim> the fact that everyone is using it’s own int15 or int31 or other clever schemes to save extra metadata in the last bit + avoiding carries is also a pain. |
15:41:56 | FromGitter | <zacharycarter> going to use that fastnoise simd port I authored last night to start creating procedural maps in godot tonight |
15:42:43 | FromGitter | <kdheepak> Does anyone have an example of nim using sdl to run on ios? |
15:43:02 | FromGitter | <kdheepak> I see that nimx supports ios but I'm unable to get it up and going. |
15:43:30 | FromGitter | <kdheepak> and the only other example is statically calling a function in Nim that returns a string. |
15:44:15 | FromGitter | <kdheepak> If there are some ios / mac developers in the chat, I have a few questions about this. |
15:44:38 | * | citycide quit (Ping timeout: 244 seconds) |
15:48:05 | * | citycide joined #nim |
15:49:36 | Araq | kdheepak, what's the problem with nimx? |
15:51:22 | * | tiorock joined #nim |
15:51:22 | * | rockcavera is now known as Guest41678 |
15:51:22 | * | tiorock is now known as rockcavera |
15:51:22 | * | rockcavera quit (Changing host) |
15:51:22 | * | rockcavera joined #nim |
15:51:52 | yonson | has anyone inserted multiple rows at once with the default nim postgresql drivers? I can't get it to work with `INSERT` |
15:52:31 | yonson | also related question, does the driver support `COPY` operations? I don't see it mentioned in the docs |
15:53:34 | itschin | Araq: is js nimcache being in current folder intended |
15:53:47 | Araq | itschin, yes |
15:54:51 | * | Guest41678 quit (Ping timeout: 252 seconds) |
15:56:14 | * | PMunch quit (Quit: Leaving) |
16:00:14 | FromGitter | <kdheepak> @Araq It looks like it has all the features I want but I'm just having issues running it on ios. |
16:00:20 | FromGitter | <kdheepak> Works great on my mac. |
16:03:10 | FromGitter | <kdheepak> I'll paste a screenshot here in a moment. |
16:06:36 | FromGitter | <kdheepak> (https://files.gitter.im/nim-lang/Nim/fnNN/Screen-Shot-2018-11-05-at-9.06.04-AM.png) |
16:07:03 | FromGitter | <kdheepak> This is what I get when I run `nim c --threads:on -d:release -r main.nim` on my mac. |
16:08:11 | FromGitter | <kdheepak> (https://files.gitter.im/nim-lang/Nim/9nGm/Screen-Shot-2018-11-05-at-9.07.31-AM.png) |
16:09:09 | * | vlad1777d quit (Ping timeout: 252 seconds) |
16:09:29 | FromGitter | <kdheepak> When I run the following in XCode ⏎ ⏎ ```code paste, see link``` ⏎ ⏎ I get a linker error in XCode shown in the screenshot above. [https://gitter.im/nim-lang/Nim?at=5be06b39076992347abded76] |
16:09:49 | FromGitter | <kdheepak> I added all the build/nimcache64 files to XCode |
16:10:29 | FromGitter | <kdheepak> I'm able to run a pure C example this way. |
16:11:16 | FromGitter | <kdheepak> If I don't use nimx and just use nim sdl, I'm able to compile successfully, but when I open the app in an ios simulator it just hangs on the splash screen. |
16:11:27 | FromGitter | <kdheepak> I'm missing something simple, but don't know what it is. |
16:11:49 | FromGitter | <kdheepak> I'm able to run the default C example in SDL and that works fine in this XCode project. |
16:18:58 | * | darithorn joined #nim |
16:30:01 | * | narimiran joined #nim |
16:35:23 | FromGitter | <zacharycarter> are you linking all the correct iOS Frameworks? |
16:35:44 | FromGitter | <zacharycarter> I don't think you are |
16:35:59 | FromGitter | <zacharycarter> I think that's why you're getting undefined symbols from the linker |
16:36:18 | FromGitter | <zacharycarter> make sure you're linking the AppKit framework |
16:41:35 | FromGitter | <kdheepak> Thanks for the reply @zacharycarter. Appkit is macos, I'm trying to build for ios. |
16:48:13 | FromGitter | <zacharycarter> hmm |
16:48:33 | FromGitter | <zacharycarter> well those linker errors are related to AppKit |
16:48:37 | FromGitter | <zacharycarter> or whatever the iOS equivalent is |
16:49:28 | FromGitter | <zacharycarter> at least I think they are |
16:51:18 | FromGitter | <zacharycarter> https://stackoverflow.com/questions/1159227/symbols-not-found-in-xcode-cocoa-application - IOKit I guess @kdheepak |
16:51:23 | FromGitter | <mratsim> @zacharycarter I’m surprised @jackmott didn’t implement one in Nim already: https://github.com/jackmott?utf8=✓&tab=repositories&q=noise&type=&language= |
16:51:50 | FromGitter | <zacharycarter> @mratsim - I didn't use jackmott's project |
16:52:09 | FromGitter | <zacharycarter> I used - https://github.com/Auburns/FastNoiseSIMD - who I think expanded on JackMott's work |
16:52:14 | FromGitter | <mratsim> I mean he has fast noise in C# C++ and Rust, he has a NIM SIMD library |
16:52:34 | FromGitter | <zacharycarter> yeah but his fast noise lib is limited in the types of noise it supports |
16:52:50 | FromGitter | <kdheepak> @zacharycarter thanks for looking into this. There's no IOKit. |
16:52:59 | FromGitter | <kdheepak> That link is from 2009, maybe things have changed? |
16:53:00 | FromGitter | <zacharycarter> @kdheepak dunno then - np |
16:53:03 | FromGitter | <zacharycarter> possibly |
16:53:46 | FromGitter | <kdheepak> I think nimx (or the darwin nim package) is not using the right functions depending on whether it is being compiled for ios / mac |
16:54:15 | FromGitter | <mratsim> and what do you use for runtime CPU features detection? |
16:55:06 | FromGitter | <mratsim> ah, you are just wrapping, you’re not reimplementing from scratch |
16:55:09 | FromGitter | <zacharycarter> yeah |
16:55:54 | FromGitter | <zacharycarter> would be awesome to be able to port these to Nim |
16:55:58 | FromGitter | <zacharycarter> but for now I think this is the best I can do |
16:56:18 | FromGitter | <kdheepak> @PMunch did you implement a nim sdl library that essentially reflected the functions in the SDL library? |
16:56:35 | FromGitter | <kdheepak> I remember seeing something like this a while ago but I'm not able to find it again. |
16:58:46 | * | wildlander joined #nim |
16:59:34 | krux02_ | I have simplex noise implemented with the types of nim-glm that can be cross compiled to GLSL as well |
17:00:31 | FromGitter | <zacharycarter> @kdheepak - Vladar wrote it - https://github.com/Vladar4/sdl2_nim |
17:01:16 | FromGitter | <mratsim> for runtime CPU detection on x86 and ARM I use this: https://github.com/numforge/laser/blob/master/laser/cpuinfo.nim |
17:01:43 | FromGitter | <mratsim> Example: https://github.com/numforge/laser/blob/master/laser/hpc_kernels/reduction_sum_min_max.nim#L47 |
17:01:59 | FromGitter | <zacharycarter> might have to look at porting this lib to Nim then when I have more time |
17:02:12 | FromGitter | <zacharycarter> thanks for sharing that |
17:03:14 | FromGitter | <kdheepak> Thanks for that @zacharycarter even that is not working. It hangs on starting the app. |
17:03:40 | FromGitter | <kdheepak> I need to start with simpler examples. |
17:04:18 | FromGitter | <kdheepak> I think I may have to wrap SDL myself to see why I'm able to use the C example but not able to use an example in Nim. |
17:05:13 | FromGitter | <mratsim> I’m only adding cpu features and SIMD on a as needed basis though. often deep learning workflows are memory bound so SSE get max perf and there is no need for AVX2 or AVX512. Basically the only exceptions are matrix multiplications and convolutions and I didn’t implement those yet. |
17:12:42 | * | a_b_m joined #nim |
17:13:58 | * | a__b__m joined #nim |
17:15:54 | * | abm quit (Ping timeout: 252 seconds) |
17:17:21 | * | a_b_m quit (Ping timeout: 252 seconds) |
17:20:22 | * | PMunch joined #nim |
17:25:47 | narimiran | @kdheepak https://github.com/nim-lang/sdl2 ? |
17:26:24 | * | floppydh quit (Quit: WeeChat 2.3) |
17:27:14 | itschin | anyone using vscode know how to skipfiles when using debugger |
17:27:24 | * | leorize quit (Ping timeout: 250 seconds) |
17:49:34 | * | nsf joined #nim |
17:50:14 | PMunch | https://github.com/nim-lang/Nim/issues/9627 |
17:54:47 | FromGitter | <tim-st> PMunch: Do you need a proc `proc convert*(kind: TNodeKind): SymbolKind =` ? |
17:55:32 | PMunch | tim-st, I've created one based on https://github.com/pragmagic/vscode-nim/blob/master/src/nimSuggest.ts#L44 |
17:55:45 | PMunch | But if you can do better I'm happy to accept it :) |
17:56:06 | FromGitter | <tim-st> where is your version? |
17:56:37 | PMunch | I forgot to upload it, just a sec |
17:56:57 | FromGitter | <tim-st> ok, thanks :) |
18:00:01 | PMunch | There |
18:00:13 | PMunch | src/nimlsppkg/mappings.nim in the repo |
18:01:27 | FromGitter | <tim-st> Thanks |
18:07:00 | * | druonysus quit (Quit: http://quassel-irc.org - Chat comfortably. Anywhere.) |
18:07:18 | * | druonysus joined #nim |
18:07:18 | * | druonysus quit (Changing host) |
18:07:18 | * | druonysus joined #nim |
18:08:27 | * | theelous3 quit (Ping timeout: 240 seconds) |
18:09:46 | FromGitter | <kdheepak> Okay after much trial and error I got it working! |
18:10:19 | FromGitter | <kdheepak> I can now compile a nim file and run it on a ios simulator! |
18:10:31 | FromGitter | <kdheepak> Next to try an ios device itself. |
18:11:30 | PMunch | kdheepak, oh cool! Make sure to document how you do it ;) |
18:20:21 | * | Sembei joined #nim |
18:20:40 | * | Pisuke quit (Ping timeout: 244 seconds) |
18:22:24 | * | stevenfx joined #nim |
18:25:06 | FromGitter | <kdheepak> Yes. Will do! |
18:25:16 | * | yonson quit (Quit: WeeChat 2.3) |
18:25:27 | FromGitter | <kdheepak> I am planning to start a brand new project and try to make everything work again. |
18:25:47 | FromGitter | <kdheepak> That'll allow me to write down the minimum steps required. |
18:37:36 | * | dom96_w quit (Ping timeout: 250 seconds) |
18:38:12 | Araq | kdheepak: yeah, please. |
18:39:04 | FromGitter | <kdheepak> I'll do that. Although I will say that @yglukhov has already done everything. |
18:39:41 | FromGitter | <kdheepak> From the looks of it, I think getting nimx to work on ios is the only missing piece. |
18:40:21 | FromGitter | <kdheepak> Whatever I write up will be nim + SDL as opposed to using nimx. |
18:41:21 | FromGitter | <kdheepak> And will likely not be required once nimx works with ios. |
18:45:36 | * | stevenfx quit (Quit: stevenfx) |
18:58:33 | * | natrys joined #nim |
18:58:42 | martin1_ | o/ all! new to the whole nim world, pretty exciting.. quick question, is there some sort of `ast` lib to parse code into an ast ? |
18:59:13 | shashlick | check out the macros module and dumpAst I guess |
19:02:52 | FromGitter | <kdheepak> ( followup: works on the ipad as well! ) |
19:04:51 | * | Aareon_ quit (Ping timeout: 260 seconds) |
19:05:17 | * | Aareon_ joined #nim |
19:07:58 | * | gmpreussner quit (Ping timeout: 245 seconds) |
19:10:27 | * | gmpreussner joined #nim |
19:26:26 | * | Vladar quit (Remote host closed the connection) |
19:57:36 | * | platoff joined #nim |
19:58:14 | FromGitter | <zacharycarter> for those of you who use emacs - do you recommend any starter kits? like spacemacs or prelude or anything like that? |
20:00:19 | FromGitter | <zacharycarter> I'll just start with vanilla to play around with |
20:00:36 | PMunch | Don't use Emacs myself, but I've heard good things about Spacemacs |
20:05:33 | FromGitter | <rayman22201> @kaushalmodi is the person to ask about emacs, when he is online. |
20:06:40 | PMunch | How is Nim support in Emacs at the moment by the way? |
20:06:49 | PMunch | I know it's one of the four semi-officially supported ones |
20:09:02 | FromGitter | <rayman22201> I'm a Vim guy, but there are several active Nim users who use Emacs very successfully. |
20:09:17 | FromGitter | <rayman22201> I can't give a more specific answer than that. sorry lol |
20:09:40 | FromGitter | <zacharycarter> I like Vim / Kak - but I plan on moving to windows |
20:10:23 | PMunch | I like the idea of Kak, but I've spent so much time configuring Vim that it's hard to move on |
20:11:06 | benjikun | I still use vim on windows, sometimes vscode |
20:11:13 | FromGitter | <rayman22201> You don't want VSCode @zacharycarter? |
20:11:29 | benjikun | textadept/joe/vim/vscode, they all work for me |
20:11:37 | FromGitter | <rayman22201> since Araq uses VSCode, it's probably the best supported editor for Windows. |
20:12:09 | * | theelous3_ joined #nim |
20:13:32 | martin1_ | speaking of editors.. what are you guys using for vim? I found zah/nim.vim, is that the best option currently? |
20:13:47 | FromGitter | <zacharycarter> @rayman22201 - not really |
20:14:14 | FromGitter | <zacharycarter> I hate VS Code to be honest |
20:14:18 | martin1_ | and also.. is there some attempt of lsp implementation? |
20:14:44 | FromGitter | <zacharycarter> you start installing plugins - pretty soon it's leaking everywhere and your plugins are breaking one another |
20:14:48 | FromGitter | <rayman22201> yes. lsp is being actively worked on atm. It's not quite ready for prime time though |
20:14:50 | FromGitter | <zacharycarter> it's a mess |
20:15:16 | FromGitter | <zacharycarter> not to mention, ootb, it has a large memory footprint |
20:15:32 | FromGitter | <rayman22201> @zacharycarter I empathize.... VSCode is a giant bloat monster |
20:15:42 | PMunch | martin1_, literally working on LSP as we speak |
20:15:47 | PMunch | It's coming along pretty nicely |
20:15:55 | PMunch | Have suggestions and hover support already |
20:16:14 | FromGitter | <rayman22201> @PMunch yay! *cheers you on* |
20:16:21 | martin1_ | PMunch: is that open to contributions yet? it feels like a nice way to get to know the language while contributing to the community |
20:16:54 | PMunch | martin1_, yes all contributions welcome: https://github.com/PMunch/nimlsp/issues |
20:17:02 | martin1_ | awesome! |
20:18:55 | benjikun | what is LSP? |
20:19:12 | PMunch | And rayman22201, it's actually surprisingly useable at the moment |
20:19:20 | PMunch | benjikun, Language Server Protocol |
20:19:38 | PMunch | Basically a common protocol for editors <-> language understanding |
20:19:45 | benjikun | oh I see |
20:19:50 | FromGitter | <rayman22201> oh good. I knew it was being worked on, but I wasn't sure how far along it was. This is good news |
20:20:12 | PMunch | So instead of implementing a plugin for each editor/language combination you develop one LSP client for each editor, and an LSP server for each language |
20:20:46 | benjikun | sounds cool |
20:20:52 | PMunch | So with the LSP server for Nim you will be able to use any editor with a LSP client plugin and get pretty much the same experience |
20:21:17 | benjikun | dam that's nice |
20:21:35 | PMunch | rayman22201, I got the first parts of suggestions working over the weekend, so you're excused for not knowing about it yet :P |
20:21:54 | PMunch | benjikun, yea it's a pretty neat idea |
20:22:01 | PMunch | The protocol is pretty messy though.. |
20:22:26 | PMunch | Like all data is transferred as UTF-8, but the offsets are given in UTF-16 code-units.. |
20:22:44 | FromGitter | <arnetheduck> +1 - nice, @PMunch |
20:28:56 | dom96 | Nice indeed :) |
20:30:39 | dom96 | Should really give your template arguments types: https://github.com/PMunch/nimlsp/blob/master/src/nimlsp.nim#L39 |
20:31:06 | PMunch | I was wondering about that |
20:31:11 | PMunch | I've seen it both with and without |
20:31:18 | PMunch | I thought without was preferred |
20:31:34 | dom96 | :'( |
20:31:44 | dom96 | Why do we even allow it without? :( |
20:31:57 | dom96 | Actually, I wonder why you need this template |
20:32:04 | dom96 | Where is `isValid` defined? |
20:34:05 | PMunch | In jsonschema |
20:34:24 | PMunch | It validates the schema of the JSON objects |
20:35:04 | PMunch | And whenValid casts them to the distinct type, which has [] implemented with static[string] for compile time checking of field access |
20:35:30 | PMunch | So if I mistype something it will complain as I compile it |
20:35:48 | PMunch | And it will return an option type if it's optional |
20:36:13 | PMunch | Currently it only returns JsonNodes though, so second-level access is still unsafe |
20:37:34 | dom96 | oh, ugh |
20:37:37 | dom96 | You're including files |
20:39:37 | PMunch | Haha, yes |
20:40:25 | PMunch | I'm including messages2 (I'm renaming this soon), which creates all the procedures. And I include mappings as it needs to know of some of those types |
20:40:54 | dom96 | You shouldn't need `include` |
20:42:44 | dom96 | Sorry, I'm too picky :P |
20:43:27 | PMunch | Well I wanted jsonschema to be able to be used within the same file without exporting it's fields |
20:43:55 | PMunch | Like here: https://github.com/PMunch/jsonschema/blob/master/tests/test1.nim |
20:45:02 | PMunch | If you imported that module the different procedures generated by jsonschema would be hidden |
20:45:28 | PMunch | But I didn't want to start nimlsp with the 700 line LSP specification |
20:45:38 | PMunch | So I moved it into another file and included it |
20:46:02 | PMunch | And because it needs to be included I had to include mappings as well, otherwise they would be declared twice |
20:47:35 | PMunch | Could definitely be done without include (by eg. having a field for the jsonschema macro that can add or remove the export marker) but this was just easier.. |
20:47:55 | * | nsf quit (Quit: WeeChat 2.3) |
20:54:09 | PMunch | Of course since packedjson didn't work I guess marshalling is on the table.. |
20:54:24 | PMunch | Not sure how much performance I gain by doing it this way |
20:57:53 | * | Trustable quit (Remote host closed the connection) |
21:06:06 | Araq | what do you mean "packedjson didn't work" ? |
21:06:35 | PMunch | Araq, I get a segfault |
21:06:43 | PMunch | Just a sec |
21:09:38 | PMunch | https://github.com/PMunch/jsonschema/tree/packedjson |
21:10:04 | PMunch | The tests/test1.nim fails with SIGSEGV: Illegal storage access. (Attempt to read from nil?) |
21:14:53 | shashlick | @zacharycarter: i tried spacemacs but its dog slow once you start using it |
21:17:38 | * | krux02_ is now known as krux02 |
21:29:20 | krux02 | shashlick: I use vanilla emacs, using it for Nim was dog slow as well, until I fixed the horrible syntax highlighting. |
21:29:34 | krux02 | and nimsuggest I disabled as well, ferformance eater |
21:30:02 | krux02 | and I disabled anything based on smie, that was not just slow but also broke automatically my code |
21:30:55 | shashlick | ya i really liked helm |
21:31:10 | shashlick | anyway, seems like there's no decent nim support anywhere |
21:31:24 | shashlick | am now used to using the CLI for git so even vscode seems pointless |
21:31:39 | * | itschin quit (Ping timeout: 268 seconds) |
21:31:41 | shashlick | if it is just syntax highlighting and lint, vim works sufficiently |
21:32:20 | PMunch | shashlick, soon Vim will get better support via LSP :) |
21:32:50 | PMunch | Well, many editors will get better support |
21:33:27 | shashlick | vscode pissed me off when i dragged a folder of nim projects as a workspace |
21:33:50 | shashlick | ran hundreds of git processes, nim check, suggest and what not |
21:34:59 | dom96 | I always use git through CLI |
21:35:12 | dom96 | Don't see why that would make VS Code pointless |
21:36:56 | shashlick | well, there's just highlight and lint, no suggest, and i don't use git there anymore |
21:37:05 | shashlick | plus it cannot handle complex workspaces |
21:37:10 | shashlick | that's basically vim |
21:37:42 | * | kapil____ quit (Quit: Connection closed for inactivity) |
21:41:31 | dom96 | Except it's better than Vim :P |
21:41:46 | benjikun | Why exactly? |
21:41:48 | dom96 | i.e. I don't have to re-learn how copy and paste works |
21:41:57 | shashlick | that I agree 😄 |
21:42:01 | shashlick | i still don't get it |
21:42:15 | PMunch | Haha, but Vims copy and paste is sooo much better once you get used to it :) |
21:42:19 | benjikun | ye |
21:42:22 | benjikun | it's not that complicated |
21:42:52 | PMunch | I remember I found that annoying as well when I started out, but now I'm just annoyed whenever I don't have it |
21:45:06 | dom96 | I gave Vim a chance for 1 month |
21:45:11 | dom96 | Printed a cheat sheet |
21:45:18 | dom96 | And gave it a proper chance |
21:45:22 | dom96 | Couldn't handle it |
21:45:26 | benjikun | fair enough |
21:45:27 | enthus1ast | multicursor is so much more convenient than vim macros, and withouth cryptic syntax |
21:45:42 | dom96 | I hated it so much that I wrote my own IDE |
21:45:51 | PMunch | enthus1ast, yeah I have a multi-cursor plugin for Vim |
21:45:52 | shashlick | i keep going back to vim, minimal memory usage, available everywhere |
21:46:01 | PMunch | Once I got used to that I couldn't live without it |
21:46:11 | PMunch | shashlick, and that battery performance :) |
21:46:13 | shashlick | but hate the useless out of the box deal |
21:46:29 | PMunch | dom96, Aporia? |
21:46:33 | * | d10n-work joined #nim |
21:46:52 | enthus1ast | i know there is one PMunch but the one i tried was too stupid |
21:47:21 | dom96 | PMunch: What else? |
21:47:25 | PMunch | I use terryma/vim-multiple-cursors |
21:47:36 | PMunch | dom96, I was just wondering if you had written another editor |
21:47:38 | shashlick | an editor should just work and be ready - not have to spend hours getting it to work |
21:48:24 | shashlick | felt spacemacs was cool but unusable once loaded - i'm using a 1 year old high end laptop that too |
21:48:40 | shashlick | so am using spacevim for now |
21:48:53 | PMunch | Well, I see an editor as a toolbox. I need to see which tools I like and what fits for me, and add those to my toolbox. Having a toolbox full of tools I never use just means I'll be lugging it around for no reason. |
21:50:10 | PMunch | So I spend some time setting up my editor with the plugins and mappings that works for me, and I've got a sorta sleek experience that's tailored to me. Without a bunch of extra stuff I never use taking up a lot of "weight" in my "toolbox". |
21:50:29 | PMunch | Hmm, that analogy turned out to be much more apt than I had expected :P |
21:51:28 | shashlick | yep and that's why i came up with vire - https://github.com/genotrance/vire |
21:52:22 | enthus1ast | and that is one problem of vim, that i have to read pages of text to just install a plugin mananger |
21:53:02 | benjikun | you don't |
21:53:11 | PMunch | Oh yeah, I'm not saying that Vim is perfect. It's definitely showing it's age |
21:53:37 | PMunch | I really wanted to get into kakoune, but last I tried it I was just missing some features |
21:53:58 | benjikun | yeah kakoune seems nice |
21:54:10 | PMunch | Might have to try it out again |
21:54:45 | benjikun | have you seen textadept? |
21:55:56 | PMunch | Hmm, nope |
21:56:37 | shashlick | kakoune doesn't work on windows |
21:56:48 | shashlick | textadept didn't work for me for nim |
21:57:09 | benjikun | yeah I kinda doubt nim highlighting is supported |
21:57:14 | benjikun | too small of an editor and language |
21:57:38 | benjikun | https://github.com/xomachine/textadept-nim |
21:57:39 | benjikun | there's this |
21:57:50 | benjikun | >development suspended though |
21:58:01 | PMunch | textadept seems to have a LSP plugin :) |
21:58:13 | benjikun | aha |
21:58:51 | shashlick | https://github.com/xomachine/textadept-nim/issues/5 |
21:58:55 | * | narimiran quit (Remote host closed the connection) |
21:59:16 | benjikun | dang |
21:59:24 | benjikun | LSP would be the solution then |
21:59:25 | benjikun | ig |
22:00:05 | FromGitter | <zacharycarter> shashlick: can I ask you a couple of nimgen related questions? |
22:00:11 | shashlick | sure |
22:00:20 | shashlick | and also interested in your experience, feedback |
22:00:54 | FromGitter | <zacharycarter> I think expanded documentation / tutorials would be extremely useful - but other than that it was easy to use |
22:01:42 | FromGitter | <zacharycarter> let me create a gist of the project's config and what I had to change to get it working |
22:04:33 | enthus1ast | i'm fighting with an async in a thread example, does one have a tip where my big mistake is? It works for a few http request then crashes, it crashes faster in release, but not crashes withouth gc :/ https://gist.github.com/enthus1ast/c3b3b0af48144d0a198d6bd0907c9640 |
22:06:15 | FromGitter | <zacharycarter> shashlick: https://gist.github.com/zacharycarter/20c34bdecca24ecab2da20402b88168e |
22:06:42 | FromGitter | <zacharycarter> actually the docs are probably good enough |
22:07:23 | FromGitter | <zacharycarter> but some textual tutorials explaining walking through some of the examples you've already done I think would help a lot of new users |
22:07:43 | FromGitter | <zacharycarter> overall though - I think you've done an awesome job |
22:07:56 | FromGitter | <zacharycarter> and I think even without that, it's great and works very well |
22:09:15 | shashlick | Thanks - ya I've been thinking about a tutorial or video or something |
22:09:53 | FromGitter | <zacharycarter> I think a nice markdown document would be wonderful |
22:09:59 | FromGitter | <zacharycarter> but I'm a sucker for text tutorials |
22:10:17 | shashlick | Cool so what's the question |
22:10:32 | shashlick | You could merge all those pragma into one |
22:11:03 | FromGitter | <zacharycarter> I added two small files to that gist titled problem1.nim and problem2.nim |
22:11:51 | FromGitter | <zacharycarter> problem 1 is - there's a weird forward declaration thing - `discard "forward decl of FastNoiseVectorSet"` and then where the type is defined |
22:12:13 | FromGitter | <zacharycarter> it has all this initialization code ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5be0c03c7c6c9e5df2120126] |
22:12:58 | FromGitter | <zacharycarter> problem two is - there are some proc parameters with the name `_size` - I'm guessing I can just use the search and replace functionality you've added to name them something like `sz` or whatever |
22:30:27 | shashlick | Brb |
22:32:49 | FromGitter | <mratsim> please not `sz` |
22:34:56 | FromGitter | <zacharycarter> haha |
22:35:45 | * | vlad1777d joined #nim |
22:36:16 | FromGitter | <zacharycarter> if I can use the word size I will if not I'll figure out something else - I wasn't trying to take a lot of time to think about it in the moment |
22:36:23 | FromGitter | <zacharycarter> I was just using what I had plugged in to get it to compile |
22:36:55 | FromGitter | <zacharycarter> here's the project btw - https://github.com/zacharycarter/cacophony - in case you want to run nimgen on it |
22:44:54 | PMunch | Update the docs to show how to use nimlsp with Sublime: https://github.com/PMunch/nimlsp, and updated the table to show the progress |
22:45:28 | FromGitter | <zacharycarter> schweeet |
22:46:25 | * | zachk joined #nim |
22:48:03 | PMunch | If anyone wants to try it out I'd be happy to see some feedback :) |
22:48:16 | * | zachk quit (Changing host) |
22:48:16 | * | zachk joined #nim |
22:49:56 | PMunch | It seems to work pretty well in the small tests I've tried. It's able to show the location and signature of procedures and types when you hover over them. It will show auto-completions while typing, and it can go to definition or list all occurrences from the hover meny |
22:55:25 | shashlick | @zacharycarter: the forward declaration is what c2nim puts when you have a struct XYZ; and implementation elsewhere or later |
22:55:37 | shashlick | i usually have to replace them with an object in generated nim |
22:55:55 | * | PMunch quit (Remote host closed the connection) |
22:55:57 | shashlick | in other cases (nimgraphql for example), need to collect all types together at the top so that forward declarations are not required |
22:56:35 | shashlick | for _size, you can do a search/replace with the correct data type |
22:57:33 | shashlick | actually, _size is the var name, just replace with size |
22:57:57 | shashlick | https://github.com/Auburns/FastNoiseSIMD/blob/master/FastNoiseSIMD/FastNoiseSIMD.h#L99 <= this is the forward declaration |
22:58:27 | shashlick | it is used before declaration on line 332 |
22:58:44 | shashlick | what you can do is use the regex/move operation to move the declaration at the top |
22:58:49 | shashlick | nimgraphql is a good example |
22:58:55 | shashlick | hope that helps |
23:09:32 | * | natrys quit (Quit: natrys) |
23:10:06 | FromGitter | <zacharycarter> thank you shashlick! it does! going to work on those now |
23:11:56 | * | krux02 quit (Remote host closed the connection) |
23:11:56 | * | theelous3_ quit (Ping timeout: 272 seconds) |
23:18:52 | shashlick | 👍 |
23:41:08 | FromGitter | <kaushalmodi> @PMunch I code Nim in Emacs. You had a question? |
23:55:29 | * | elrood quit (Remote host closed the connection) |