00:05:55 | * | qwertotter is now known as qwertfisch |
00:16:44 | * | subsetpark_ quit (Ping timeout: 252 seconds) |
00:17:16 | * | subsetpark_ joined #nim |
00:31:26 | * | endragor joined #nim |
00:35:35 | * | endragor quit (Ping timeout: 240 seconds) |
00:35:35 | * | Yardanico[Phone] quit (Read error: Connection reset by peer) |
00:37:27 | * | claudiuinberlin quit (Quit: Textual IRC Client: www.textualapp.com) |
00:38:30 | * | devdri quit () |
00:41:36 | * | gokr quit (Ping timeout: 248 seconds) |
01:01:17 | * | zama joined #nim |
01:04:57 | * | marenz__ quit (Ping timeout: 265 seconds) |
01:06:00 | * | pleiosaur joined #nim |
01:55:35 | * | MJCaley joined #nim |
02:05:37 | * | dddddd quit (Remote host closed the connection) |
02:10:00 | * | S1tiSchu joined #nim |
02:13:48 | * | SitiSchu quit (Ping timeout: 268 seconds) |
02:29:32 | * | yglukhov quit (Remote host closed the connection) |
02:30:09 | * | yglukhov joined #nim |
02:31:30 | * | vlad1777d joined #nim |
02:34:51 | * | yglukhov quit (Ping timeout: 265 seconds) |
02:58:35 | * | benoliver999 quit (Ping timeout: 240 seconds) |
03:00:28 | * | chemist69 quit (Ping timeout: 265 seconds) |
03:14:01 | * | chemist69 joined #nim |
03:32:11 | * | endragor joined #nim |
03:36:57 | * | endragor quit (Ping timeout: 264 seconds) |
03:55:56 | * | yglukhov joined #nim |
04:00:05 | * | yglukhov quit (Ping timeout: 240 seconds) |
04:32:27 | * | MJCaley quit (Quit: MJCaley) |
04:36:57 | * | user0 quit (Ping timeout: 264 seconds) |
04:47:02 | * | xet7 joined #nim |
05:23:33 | * | endragor joined #nim |
05:27:59 | * | endragor quit (Ping timeout: 248 seconds) |
05:59:41 | * | xet7 quit (Quit: Leaving) |
06:04:23 | * | rauss quit (Quit: WeeChat 2.0.1) |
06:17:32 | * | dandevelo quit (Ping timeout: 276 seconds) |
07:03:25 | * | kevingolding joined #nim |
07:11:59 | * | kevingolding quit () |
07:17:48 | * | gokr joined #nim |
07:18:49 | * | azur_kind joined #nim |
07:24:03 | * | earenndil quit (Quit: ZNC 1.6.3+deb1 - http://znc.in) |
07:25:02 | * | endragor joined #nim |
07:26:11 | * | earenndil joined #nim |
07:30:10 | * | endragor quit (Ping timeout: 265 seconds) |
07:32:57 | * | craigger quit (Ping timeout: 256 seconds) |
07:33:16 | * | craigger joined #nim |
07:38:19 | * | Yardanico[Phone] joined #nim |
07:44:10 | * | dandevelo joined #nim |
07:47:22 | * | miran joined #nim |
07:59:50 | * | benoliver999 joined #nim |
08:00:34 | * | yglukhov joined #nim |
08:04:00 | * | dandevelo quit (Ping timeout: 265 seconds) |
08:05:05 | * | yglukhov quit (Ping timeout: 240 seconds) |
08:10:21 | * | Yardanico joined #nim |
08:14:40 | Yardanico | hi everyone, I assume it's currently night in NA? |
08:14:53 | Yardanico | oh, it seems so |
08:15:46 | miran | ...but morning in europe |
08:16:17 | Yardanico | yes, that's why I'm here :) |
08:22:20 | * | nsf joined #nim |
08:24:43 | * | gangstacat joined #nim |
08:32:34 | miran | Yardanico: if you're bored waiting for more people, i just posted something on the forum.... ;) |
08:55:56 | * | gokr quit (Ping timeout: 252 seconds) |
09:02:29 | * | gmpreussner quit (Ping timeout: 256 seconds) |
09:05:38 | * | gmpreussner joined #nim |
09:18:17 | Araq | muhaha, I finally figured out how 'sink' parameters need to work. I think. |
09:23:36 | * | yglukhov joined #nim |
09:26:52 | * | endragor joined #nim |
09:27:33 | * | Yardanico quit (Remote host closed the connection) |
09:29:06 | * | user0 joined #nim |
09:29:16 | * | Yardanico joined #nim |
09:31:29 | * | endragor quit (Ping timeout: 265 seconds) |
09:32:57 | * | Vladar joined #nim |
09:35:35 | * | yglukhov quit (Remote host closed the connection) |
09:36:20 | * | yglukhov joined #nim |
09:37:06 | * | yglukhov quit (Remote host closed the connection) |
09:38:26 | * | Yardanico quit (Remote host closed the connection) |
09:41:14 | * | Yardanico_ joined #nim |
09:44:41 | * | Yardanico_ quit (Remote host closed the connection) |
09:46:01 | * | Yardanico joined #nim |
09:51:08 | * | Yardanico quit (Remote host closed the connection) |
09:52:40 | * | Yardanico joined #nim |
09:58:04 | * | Yardanico quit (Remote host closed the connection) |
09:58:55 | * | Yardanico joined #nim |
10:00:50 | * | dandevelo joined #nim |
10:05:51 | * | dandevelo quit (Ping timeout: 248 seconds) |
10:06:35 | FromGitter | <data-man> @Araq: Have you seen my new PR? :-) |
10:11:23 | Araq | which one? |
10:12:16 | * | endragor joined #nim |
10:12:47 | * | claudiuinberlin joined #nim |
10:13:17 | FromGitter | <data-man> https://github.com/nim-lang/Nim/pull/7037 |
10:14:13 | * | gangstacat quit (Quit: Ĝis!) |
10:15:01 | * | arecaceae joined #nim |
10:15:56 | FromGitter | <ervinbosenbacher> Hey everyone, I am getting familiar with the language, tools, compiler, etc and I am in love :D. Anyway once I am comfortable I am happy to contribute to those 1146 open issues. |
10:18:21 | * | gangstacat joined #nim |
10:20:33 | Araq | data-man: huh? That's not a fix, that's a worse design :P |
10:20:40 | FromGitter | <data-man> @ervinbosenbacher: Welcome! |
10:23:58 | * | devdri joined #nim |
10:25:28 | FromGitter | <data-man> @Araq: Why? ⏎ ⏎ `````` [https://gitter.im/nim-lang/Nim?at=5a51f598232e79134dd6f9ef] |
10:26:12 | FromGitter | <data-man> ```code paste, see link``` ⏎ ⏎ Is worked [https://gitter.im/nim-lang/Nim?at=5a51f5c45355812e57605388] |
10:27:13 | FromGitter | <data-man> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5a51f6010505ad8b45c486bb] |
10:28:59 | FromGitter | <data-man> *It's worked :-) |
10:30:03 | Araq | data-man: the allocator argument doesn't hurt, you can make the existing allocator compatible with it anyway |
10:30:17 | Araq | why do you think it should be removed? |
10:31:05 | FromGitter | <ervinbosenbacher> just a quick question, in order to link with C++ libraries do I have to compile using the C++ switched my code and proceed like that? Warning newbie question. Mangling and all. Or is there somewhere a simple example where I can have a look how to use c++ libraries from Nim? |
10:33:08 | Yardanico | ervimbosenbacher: AFAIK there's some support for compiling to C and using C++ libraries at the same time |
10:35:46 | FromGitter | <ervinbosenbacher> Probably. I have a bunch of c++17 code that is compiled using gcc 7.2 unil this point I have used them from Python 3.6 I would like to sitch to NIM and searching for a simple solution or example that can show me the way :D |
10:36:29 | miran | btw, it is Nim, not NIM - i've seen you're regularly using all caps :) |
10:36:32 | FromGitter | <ervinbosenbacher> Ill find it but thought I ask if someone knows |
10:36:43 | FromGitter | <ervinbosenbacher> Ok ok sorry :D |
10:36:45 | FromGitter | <ervinbosenbacher> Nim |
10:37:32 | Yardanico | if you compile your C++ code to dll/so/dylib, you don't need to use C++ compilation target in nim |
10:37:53 | FromGitter | <ervinbosenbacher> good point. |
10:40:38 | FromGitter | <ervinbosenbacher> It is such a big relief after rust by the way. Like a 200 kg stone fell of my soul. |
10:41:18 | FromGitter | <ervinbosenbacher> and D, where I had my GC headache. Now I can choose. |
10:41:39 | FromGitter | <data-man> @Araq: I was just trying to make it work, because the code did not compile. :-) |
10:43:04 | FromGitter | <data-man> And new string type too. |
10:43:18 | Araq | ok but don't change the interface unless you have good arguments. Note that the allocator interface is part of the wiki page |
10:43:38 | Araq | which is a work-in-progress *spec* :P |
10:47:05 | FromGitter | <ervinbosenbacher> is this how I interface with c or c++ (extern “C”) code? |
10:47:05 | FromGitter | <ervinbosenbacher> https://nim-lang.org/docs/manual.html#foreign-function-interface |
10:47:52 | Yardanico | it's how you interface with C code |
10:48:01 | Yardanico | it's more complicated with C++ |
10:48:12 | FromGitter | <ervinbosenbacher> i will use the dynlib pragma |
10:48:27 | Yardanico | well you still need to use importc/importcpp |
10:48:40 | FromGitter | <ervinbosenbacher> its ok |
10:49:02 | FromGitter | <ervinbosenbacher> ill find out |
10:54:06 | Araq | there are multiple ways to interface with C or C++ code... |
10:54:13 | FromGitter | <ervinbosenbacher> Thx for the help @Yardanico Ill browse the docs if I have a question Ill ask :) |
10:54:22 | Araq | I think "c2nim" covers the basics quite well |
10:54:52 | FromGitter | <ervinbosenbacher> Yes that is what I am looking ar |
10:54:55 | FromGitter | <ervinbosenbacher> at |
10:55:42 | FromGitter | <ervinbosenbacher> managed to nstall it after some pain, I had to install Nim head and compiler head after some errors |
10:57:29 | * | vlad1777d quit (Ping timeout: 252 seconds) |
10:58:18 | FromGitter | <ervinbosenbacher> so I can use c2nim to translate the header than use it to call into the c/c++ code? |
10:58:49 | Yardanico | yes, but almost always you need to manually modify C/C++ header |
11:00:02 | FromGitter | <ervinbosenbacher> its fine as long the reult is that I can use C++ code from Nim and I dont have to rewrite the entire thing, essentially I am loking for to replace tust/d/python code with Nim |
11:00:19 | FromGitter | <ervinbosenbacher> Sorry for the typos |
11:03:39 | * | dddddd joined #nim |
11:04:43 | Araq | the wise option is to use {.reorder: on.} for c2nim'ed code |
11:05:03 | Araq | you can keep a patchset and reapply the patches the header files |
11:05:34 | Araq | should the header files change in the future. Your goal should be to *not* edit the produced Nim code. |
11:06:02 | FromGitter | <ervinbosenbacher> So i create it the first time and then I just apply patches? |
11:06:20 | Araq | well that has never worked before. |
11:06:30 | FromGitter | <ervinbosenbacher> Sounds good to me. I will test this today with some simple stuff |
11:06:43 | Araq | but it's what you should strive for and the tooling keeps getting better for it. |
11:06:51 | FromGitter | <ervinbosenbacher> Never mind , if I have to I will do it manually |
11:07:22 | Araq | {.reorder: on.} is new and was a missing piece in the puzzle |
11:07:23 | FromGitter | <ervinbosenbacher> I can help with the tooling at some point, once I am done with the learning curve of everyting |
11:08:17 | FromGitter | <ervinbosenbacher> For me this is critical piece of the puzzle have several 100k loc in C++ |
11:10:35 | * | Yardanico[Phone] quit (Ping timeout: 260 seconds) |
11:11:43 | Araq | well it's some work but we wrapped, wxWidgets, Urho3D and Unreal Engine 4. |
11:12:06 | FromGitter | <ervinbosenbacher> Is that open source? |
11:12:11 | Araq | yes. |
11:12:18 | FromGitter | <ervinbosenbacher> So I can have a look? |
11:12:40 | * | xet7 joined #nim |
11:12:41 | FromGitter | <ervinbosenbacher> ok got it thx |
11:14:20 | FromGitter | <ervinbosenbacher> i will need rocksdb, tensorflow, a bunch of low level things. Compression , filesystem libs my own code |
11:21:15 | FromGitter | <ervinbosenbacher> i will use nimue4 as a reference, I used to work a lot with UE4 so i can relate to that |
11:39:58 | FromGitter | <ervinbosenbacher> I put this on my todo list |
11:40:12 | FromGitter | <ervinbosenbacher> will write tooling for cuda and openmp |
11:40:34 | FromGitter | <ervinbosenbacher> Basically that is critical for a my whole AI ;ayer |
11:40:55 | FromGitter | <ervinbosenbacher> it iwll be fun |
11:41:56 | FromGitter | <ervinbosenbacher> OpenCL I meant |
11:58:11 | FromGitter | <stisa> @ervinbosenbacher have a look at Arraymancer and Neo, they both have support for cuda I think |
11:58:47 | FromGitter | <stisa> https://github.com/unicredit/neo/ and https://github.com/mratsim/Arraymancer |
12:00:42 | Yardanico | arraymancer is meant for be used for AI btw |
12:01:18 | * | endragor quit (Remote host closed the connection) |
12:03:12 | * | dandevelo joined #nim |
12:07:27 | * | dandevelo quit (Ping timeout: 248 seconds) |
12:10:26 | * | gokr joined #nim |
12:18:30 | * | Yardanico quit (Remote host closed the connection) |
12:19:53 | * | Yardanico joined #nim |
12:22:12 | * | Yardanico quit (Remote host closed the connection) |
12:28:11 | * | Yardanico joined #nim |
12:37:11 | * | marenz__ joined #nim |
12:39:29 | * | user0 quit (Quit: user0) |
12:41:22 | * | user0 joined #nim |
12:42:05 | FromGitter | <ervinbosenbacher> yes thx, I’ve discovered them yester |
12:44:07 | FromGitter | <ervinbosenbacher> We need a unch of other things to have a proper scientific stack, at least my amition. Nim is very well suited for that, especially that it has a Pythonic syntax. |
12:45:42 | * | user0 quit (Client Quit) |
12:45:58 | * | user0 joined #nim |
12:50:31 | * | user0 quit (Client Quit) |
12:50:49 | * | user0 joined #nim |
12:52:38 | * | S1tiSchu is now known as SitiSchu |
12:53:24 | * | dandevelo joined #nim |
12:54:59 | * | Vladar quit (Quit: Leaving) |
12:58:44 | * | SitiSchu quit (Quit: Leaving) |
12:58:55 | * | SitiSchu joined #nim |
13:17:39 | * | rokups joined #nim |
13:23:27 | * | nsf quit (Quit: WeeChat 2.0.1) |
13:30:57 | * | user0 quit (Quit: user0) |
13:31:17 | * | user0 joined #nim |
13:31:56 | * | devdri quit () |
13:35:31 | * | user0 quit (Client Quit) |
13:35:48 | * | user0 joined #nim |
13:38:02 | * | MJCaley joined #nim |
13:43:20 | * | devdri joined #nim |
13:56:24 | * | vlad1777d joined #nim |
14:34:03 | * | devdri quit (Ping timeout: 265 seconds) |
14:40:36 | * | devdri joined #nim |
14:46:42 | * | MJCaley quit (Quit: MJCaley) |
14:53:09 | * | Senketsu quit (Ping timeout: 264 seconds) |
15:13:03 | * | derlafff quit (Remote host closed the connection) |
15:13:59 | * | MJCaley joined #nim |
15:14:23 | * | derlafff joined #nim |
15:24:20 | * | MJCaley quit (Quit: MJCaley) |
15:27:13 | * | gokr quit (Ping timeout: 265 seconds) |
15:30:57 | * | devdri quit (Ping timeout: 264 seconds) |
15:33:48 | * | devdri joined #nim |
15:39:04 | FromGitter | <mratsim> @ervinbosenbacher I’m currently adding OpenCL support to Arraymancer: https://github.com/mratsim/Arraymancer/pull/184 though I’ve taken 2 weeks off to recharge |
15:40:50 | * | Yardanico_ joined #nim |
15:42:56 | * | Yardanico quit (Ping timeout: 248 seconds) |
15:44:51 | * | Yardanico_ quit (Client Quit) |
15:45:10 | * | Yardanico_ joined #nim |
15:53:12 | * | nc-x joined #nim |
15:53:46 | nc-x | What does this error mean `Error: unhandled exception: cannot dispatch; dispatcher is nil [NilAccessError]`? I am trying to define `$` for objects inherited from other objects using `method` and getting this error. |
15:56:50 | nc-x | Okay i got it |
15:57:00 | nc-x | nvm |
15:58:42 | * | MJCaley joined #nim |
16:10:38 | * | Yardanico_ is now known as Yardanico |
16:10:49 | * | nc-x quit (Ping timeout: 260 seconds) |
16:17:33 | * | devdri quit () |
16:17:52 | * | devdri joined #nim |
16:18:08 | * | xet7 quit (Ping timeout: 252 seconds) |
16:25:57 | * | user0 quit (Quit: user0) |
16:26:14 | * | user0 joined #nim |
16:30:49 | * | xet7 joined #nim |
16:33:35 | * | MJCaley quit (Quit: MJCaley) |
16:34:45 | * | Trustable joined #nim |
16:35:31 | * | user0 quit (Quit: user0) |
16:35:44 | * | user0 joined #nim |
16:38:45 | * | dandevelo quit (Ping timeout: 265 seconds) |
16:38:53 | * | yglukhov joined #nim |
16:43:56 | * | endragor joined #nim |
16:46:05 | * | S1tiSchu joined #nim |
16:46:16 | * | SitiSchu quit (Remote host closed the connection) |
17:06:18 | * | devdri quit () |
17:06:47 | * | devdri joined #nim |
17:07:06 | * | rokups quit (Quit: Connection closed for inactivity) |
17:07:45 | * | Yardanico quit (Ping timeout: 248 seconds) |
17:09:50 | * | Yardanico joined #nim |
17:21:52 | FromGitter | <ervinbosenbacher> @mratsim that is good to know. I am planning to use your library in my search engine |
17:22:29 | FromGitter | <ervinbosenbacher> which is really nice as I dont have to hunt down for an ML lib :) |
17:51:11 | FromGitter | <data-man> D's tests moved from Travis to SemaphoreCI https://github.com/dlang/dmd/pull/7617 |
17:58:26 | Yardanico | time to move our tests :D |
17:58:46 | Yardanico | "Always free for open source. " in case someone is wondering |
17:59:25 | Yardanico | "Each execution environment ("Box") is powered by an Intel Core i7 Skylark CPU, 8 GB DDR4 RAM and high-end I/O throughput." |
17:59:29 | Yardanico | wow |
18:00:09 | * | MJCaley joined #nim |
18:01:01 | Yardanico | I'll fork nim and test how much time tests will take! (if I'm not lazy) |
18:02:34 | FromGitter | <RedBeard0531> Skylark? |
18:03:07 | Yardanico | IDK, ask them :) |
18:03:15 | FromGitter | <ervinbosenbacher> I have moved away from D 2 days ago in favor of Nim |
18:03:26 | FromGitter | <ervinbosenbacher> I stick with Nam skylark or not :D |
18:03:28 | Yardanico | LOL |
18:03:35 | Yardanico | I added forked nim, and warning says: " |
18:03:35 | Yardanico | This looks like a cool Nimrod project. |
18:03:35 | Yardanico | Semaphore doesn’t fully support it yet, but here’s the deal. Check out what’s on our platform, fill in your test commands below, email us what you did on [email protected] and we’ll improve our service. Thanks! |
18:03:35 | Yardanico | " |
18:05:40 | * | nsf joined #nim |
18:06:40 | FromGitter | <ervinbosenbacher> D is a pile of mess + I can comple Nim to c or C++ or Javascript or Objective-c and I dont have to mess with building bridges. My all time favourite is Rust on iOS. Rust->C->C++->Objective-C++->Swift |
18:06:44 | FromGitter | <ervinbosenbacher> and my head hurts |
18:07:02 | FromGitter | <ervinbosenbacher> No i just build Nim to Objective-C and done |
18:07:32 | FromGitter | <ervinbosenbacher> That alone worth to switch |
18:07:34 | Yardanico | wait, nim uses clang for testing? |
18:07:37 | Yardanico | *for testament |
18:07:43 | Yardanico | https://github.com/Yardanico/Nim/blob/devel/.travis.yml#L32 |
18:10:42 | Yardanico | I mean that's good |
18:10:54 | FromGitter | <ervinbosenbacher> yes it is |
18:11:49 | Araq | I disagree but it is what it is |
18:11:56 | Yardanico | Araq, for speed? |
18:12:08 | FromGitter | <ervinbosenbacher> Cant you change? If you want to? |
18:12:15 | Yardanico | yes he can, but testing will take more time |
18:12:17 | Araq | GCC is the default for Linux so we should test against GCC |
18:12:20 | Yardanico | gcc is slower than clang |
18:12:24 | FromGitter | <ervinbosenbacher> for example to gcc |
18:12:25 | Yardanico | but yeah, GCC is default |
18:12:29 | FromGitter | <ervinbosenbacher> i disagree |
18:12:35 | FromGitter | <ervinbosenbacher> Gcc-7.2 is fast hell |
18:12:35 | Araq | clang on osx, GCC on linux, msvc on Windows |
18:12:36 | Yardanico | ervinbosenbacher: nim has gcc by default |
18:12:41 | Yardanico | it's not really :) |
18:12:48 | Yardanico | I compared gcc 7.2 vs clang 5.0.1 |
18:12:52 | Yardanico | clang is still faster |
18:12:54 | FromGitter | <ervinbosenbacher> On my mac its faster |
18:12:58 | Araq | but we use mingw on Windows, so *shrug* |
18:13:05 | FromGitter | <ervinbosenbacher> :D |
18:13:23 | Araq | ervinbosenbacher: does GCC even run on OSX? :-) |
18:13:40 | Yardanico | yes |
18:13:47 | Yardanico | maybe patched, but yes |
18:13:50 | FromGitter | <ervinbosenbacher> i have blinders on my wndows I dont test anything on it ;D |
18:13:53 | Yardanico | you can install it via brew for example |
18:14:08 | FromGitter | <ervinbosenbacher> i have built gcc from sources |
18:14:24 | FromGitter | <ervinbosenbacher> on my mac yes its fine that is what I am using y default for c++ et al |
18:15:12 | Yardanico | ervinbosenbacher: you can use nim with gcc/clang/icc/tcc/msvc/mingw/can't remember others |
18:15:13 | FromGitter | <ervinbosenbacher> i needed c++17 features so I grabbed it |
18:15:26 | FromGitter | <ervinbosenbacher> gcc is fine :D thx |
18:15:44 | Yardanico | Araq, I'm testing Semaphore CI with gcc |
18:15:48 | dom96 | There is so many different CI services out there now |
18:15:54 | Yardanico | let's see how much time tests will take |
18:15:57 | Yardanico | https://semaphoreci.com/yardanico/nim/branches/devel/builds/3 |
18:15:57 | dom96 | But what about custom-hosted CI software? |
18:16:08 | Yardanico | dom96, gitlab? |
18:16:10 | dom96 | s/custom/self/ I should say |
18:16:27 | dom96 | Oh I've been there. Was quite painful. |
18:17:10 | * | Trustable quit (Remote host closed the connection) |
18:17:20 | Yardanico | ok let's go, testament started! https://semaphoreci.com/yardanico/nim/branches/devel/builds/3 |
18:17:38 | Yardanico | everything before testament took 3 mins |
18:17:41 | Yardanico | (with gcc) |
18:18:29 | FromGitter | <ervinbosenbacher> grab a coffee |
18:18:39 | * | azur_kind quit (Remote host closed the connection) |
18:19:12 | * | xet7 quit (Quit: Leaving) |
18:19:23 | dom96 | Nice, can't wait to run on Travis, Circle CI /and/ Semaphore |
18:19:33 | dom96 | More CIs can't hurt, right? :P |
18:19:57 | FromGitter | <ervinbosenbacher> No |
18:20:36 | Yardanico | so if semaphore ci with gcc is faster than travis ci with clang... |
18:20:47 | Yardanico | (some tests fail because boehm gc is not installed by default) |
18:21:36 | Yardanico | (of course you can use apt-get) |
18:21:44 | Yardanico | and they have ubuntu 17.04 by default |
18:22:19 | Yardanico | ah, no, ubuntu 14.04 is default |
18:22:30 | Yardanico | oh I'm blind |
18:22:37 | Yardanico | they ONLY have ubuntu 14.04 :D sorry for spam |
18:24:33 | Yardanico | ok, testament finished in 6 mins, BUT I haven't installed boehm or other dependencies, so it might be very inaccurate |
18:24:36 | Yardanico | oh wait |
18:24:38 | Yardanico | it's done in 9 mins |
18:24:47 | Yardanico | ah wait no? |
18:25:01 | Yardanico | AHH, it fails if one command returns non-zero exit code, wtf |
18:25:13 | FromGitter | <ervinbosenbacher> Hhaha |
18:25:22 | Yardanico | well I probably can change that |
18:25:41 | FromGitter | <ervinbosenbacher> having fun ? |
18:26:43 | * | Ven`` joined #nim |
18:30:40 | * | xet7 joined #nim |
18:33:27 | dom96 | Yardanico: If you want some brownie points: set up one of these CI services to store build artefacts on our VPS so that choosenim can use them :) |
18:33:37 | * | xet7 quit (Client Quit) |
18:34:47 | Yardanico | dom96, semaphore ci has ftp deployment |
18:35:04 | dom96 | sftp? :) |
18:35:12 | dom96 | cause that'd be nice |
18:35:20 | Yardanico | probably, and it also has generic deploy |
18:35:25 | Yardanico | (any your custom commands) |
18:35:32 | Yardanico | Semaphore has LFTP, an FTP/HTTP client and a file transfer program, installed by default. LFTP can be used with the Generic Deployment method on Semaphore. |
18:35:42 | Yardanico | yes, lftp supports fpt |
18:35:44 | Yardanico | sfpt |
18:35:45 | Yardanico | sftp |
18:36:15 | dom96 | Even if LFTP supports it, semaphore might not |
18:36:29 | dom96 | They'd need to give you an SSH key that you can trust. |
18:36:57 | Yardanico | firstly I need to understand how to make builds not fail if some command failed |
18:38:32 | FromGitter | <RedBeard0531> Can you just say `|| true` to hide the failure from it |
18:38:38 | Yardanico | well I can |
18:38:46 | Yardanico | but this would be a hack, no? |
18:38:55 | Yardanico | I firstly need to make sure I can't do it other way |
18:39:15 | Yardanico | also, why we don't use IRC notifications on travis? |
18:39:26 | Yardanico | https://docs.travis-ci.com/user/notifications/#Configuring-IRC-notifications |
18:39:37 | FromGitter | <RedBeard0531> Total hack, but good enough to benchmark, no? |
18:39:41 | Yardanico | ah, ok :) |
18:39:42 | Yardanico | yes |
18:39:49 | Yardanico | you're right |
18:40:11 | * | xet7 joined #nim |
18:40:16 | FromGitter | <RedBeard0531> Then you can decide if it's worth the effort to do it right ☺ |
18:41:44 | * | xet7 quit (Remote host closed the connection) |
18:45:57 | * | Ven`` quit (Ping timeout: 264 seconds) |
18:46:04 | * | xet7 joined #nim |
18:48:53 | * | Ven`` joined #nim |
18:51:35 | * | chemist69 quit (Ping timeout: 252 seconds) |
18:54:56 | FromGitter | <tim-st> Is it necessary for the compiler to write the function names (the same I use in source code) to the binary or why is it done? That makes reverse engineering quite easy... |
18:55:20 | Yardanico | ehm? |
18:55:25 | Yardanico | ask gcc or clang |
18:56:05 | FromGitter | <tim-st> I thought I saw the same in the nim generated code with underscore etc so I asked here |
18:56:21 | FromGitter | <tim-st> readMediaWikiXML_WPIqozUJE9cp18PTbwX5Cew |
18:56:55 | Yardanico | it's needed for things like different generic instantiations of one proc |
18:57:17 | FromGitter | <tim-st> Yes, but the compiler could use random names from md5 or similar |
18:57:30 | FromGitter | <RedBeard0531> You could probably edit the compiler's name mangling scheme to leave out the original function name. |
18:57:53 | Yardanico | tim-st: you can't read generated C code then at all |
18:58:14 | Yardanico | it will be really unreadable |
18:58:31 | FromGitter | <RedBeard0531> But try compiling with lto and no debug symbols first. That is probably good enough |
18:58:35 | Yardanico | use strip |
18:58:40 | Yardanico | it helps too |
18:59:01 | Yardanico | Guys, SemaphoreCi completed Nim test in 15 minutes! WITH GCC! |
18:59:10 | Yardanico | (compared to travis with clang - 24 mins last commit) |
18:59:16 | Yardanico | https://semaphoreci.com/yardanico/nim/branches/devel/builds/5 |
18:59:21 | FromGitter | <RedBeard0531> Nice |
18:59:38 | Yardanico | dom96, ^^ |
19:01:00 | shashlick | question on nimble - you have to put in the version string into the .nimble file, how can you use that value in the build/install process so that the binary built can contain the same version string? |
19:01:56 | * | Ven`` quit (Ping timeout: 276 seconds) |
19:02:01 | Araq | either use a common include file or include the nimble file |
19:02:13 | Araq | the .nimble file is Nim code. |
19:02:27 | * | endragor quit (Remote host closed the connection) |
19:02:49 | Yardanico | Sadly semaphore ci doesn't support osx |
19:02:56 | Yardanico | but it indeed is faster than travis |
19:03:46 | FromGitter | <tim-st> @Yardanico @RedBeard0531 Thanks, `nim -d:release --opt:size c "file.nim" && strip -s "file.exe"` solves it |
19:03:57 | Araq | 15 minutes vs 24 minutes is not relevant. |
19:04:07 | Yardanico | Araq, well I know, but it definitely helps :) |
19:04:09 | * | Ven`` joined #nim |
19:04:20 | Araq | since in either case I stop waiting for the result and play some game :P |
19:04:32 | Araq | which lasts for one hour. |
19:04:39 | Yardanico | let me guess... starcraft? |
19:04:40 | Araq | (nah, just kidding, but you get the idea) |
19:04:45 | Yardanico | ah, ok :) |
19:04:57 | * | chemist69 joined #nim |
19:05:08 | Yardanico | at least we can use semaphore ci to produce nightly binaries for choosenim (as dom96 suggested) |
19:05:33 | * | dandevelo joined #nim |
19:05:37 | Araq | my New Year's pledge is to play Prey |
19:09:56 | dom96 | shashlick: see Nimble's .nimble file for how to do it, it's a bit too messy still but doable |
19:10:18 | FromGitter | <RedBeard0531> Tim try --passc:-flto --passl:-flto |
19:10:19 | dom96 | Yardanico: Can't we do that with travis too? :P |
19:10:31 | * | dandevelo quit (Ping timeout: 265 seconds) |
19:12:53 | shashlick | Araq: dom96 thanks guys, will check it out |
19:13:05 | Yardanico | dom96, we can :) |
19:14:54 | Yardanico | dom96, but I have a feeling that compiled nim binary wouldn't work on other distros or even ubuntu versions |
19:15:12 | Yardanico | but IDK |
19:15:42 | dom96 | it will |
19:16:01 | Yardanico | dom96, https://docs.travis-ci.com/user/deployment/script/ |
19:16:03 | dom96 | well, if you compile it on latest ubuntu it won't |
19:16:16 | Yardanico | or we can use github releases |
19:16:19 | * | Ven`` quit (Ping timeout: 265 seconds) |
19:16:23 | dom96 | If you want the best compatibility for Linux you should compiling on a system with the oldest glibc |
19:16:30 | dom96 | *should be |
19:16:45 | Yardanico | ah, yes |
19:16:47 | Yardanico | centos 6 :D |
19:17:34 | shashlick | dom96: I see how you did it for nimble, but then when it comes to pulling the right version of a module, you rely on the github tags and not the value in the nimble file right? |
19:18:56 | * | Ven`` joined #nim |
19:21:10 | Yardanico | dom96, we can use github releases for nightly builds, not sure if that's OK or not |
19:21:16 | Yardanico | and tag them as prerelease |
19:21:23 | * | nsf quit (Quit: WeeChat 2.0.1) |
19:22:20 | Yardanico | dom96, because you can't use sftp - travis will run testing on a random host |
19:22:37 | Yardanico | maybe just normal FTP? (and don't be scared - you can encrypt passwords) |
19:22:50 | Yardanico | https://docs.travis-ci.com/user/encryption-keys/ |
19:23:52 | dom96 | We would need to set up FTP on the server then. |
19:24:14 | Yardanico | dom96, maybe scp? |
19:24:19 | Yardanico | ah, no |
19:25:14 | Yardanico | we can use bintray btw |
19:25:36 | Yardanico | but only 1 terabyte/month :P |
19:25:43 | Yardanico | and 10gb storage |
19:25:46 | Yardanico | (for open source) |
19:25:59 | Yardanico | https://docs.travis-ci.com/user/deployment/bintray/ https://bintray.com/ |
19:26:38 | dom96 | or we could write a little Nim binary that accepts files from travis ;) |
19:26:46 | Yardanico | how? |
19:27:01 | Yardanico | well I mean travis needs to upload them somewhere |
19:28:00 | Yardanico | and bintray looks nice |
19:31:06 | shashlick | how do you access a -d:NAME:VALUE within the code? |
19:32:17 | shashlick | accessing NAME directly in the code gives me undeclared identifier |
19:32:42 | FromGitter | <RedBeard0531> {..} |
19:33:50 | dom96 | Yardanico: PUT via curl? |
19:33:52 | FromGitter | <RedBeard0531> const NAME {.strdefine.}: string |
19:34:14 | FromGitter | <RedBeard0531> Or intdefine for ints |
19:34:38 | FromGitter | <RedBeard0531> Shashlick^^ |
19:35:00 | Yardanico | dom96, hmm, so you want to set up a separate web-server which will check for some password and accept upload? |
19:35:16 | dom96 | yes, or checks for travis IP |
19:35:36 | Yardanico | hmm, yes |
19:35:36 | Yardanico | https://docs.travis-ci.com/user/ip-addresses/ |
19:35:47 | dom96 | easy peasy :P |
19:36:03 | Yardanico | but Sudo-enabled Linux |
19:36:09 | Yardanico | we use it right? |
19:36:14 | Yardanico | or not? |
19:36:24 | * | gokr joined #nim |
19:36:44 | Yardanico | Araq, also this semaphore ci is 15 mins only using gcc :) |
19:36:46 | Yardanico | not clang |
19:36:51 | Yardanico | maybe you didn't notice |
19:37:20 | FromGitter | <ervinbosenbacher> :) |
19:37:22 | shashlick | @RedBeard0531: thank you! |
19:38:13 | shashlick | okay, and how can I pass extra params to the build or install nim command that nimble generates? |
19:40:50 | * | endragor joined #nim |
19:42:38 | FromGitter | <RedBeard0531> Shashlick https://nim-lang.org/docs/nimc.html#compiler-usage-configuration-files |
19:48:13 | shashlick | @RedBeard0531: ya but I won't be able to pass a value from within nimble that way - nim.cfg would be hard coded and not a value I can pass |
19:50:22 | FromGitter | <RedBeard0531> If you are fine passing things manually, keep doing that... |
19:53:49 | shashlick | basically, I want to use the nimble version value to build the executable, however, since nimble generates the nim commandline, I cannot add the -d:VERSION=xyz |
19:54:31 | shashlick | i was trying to avoid having to split out the version info into a separate .nim file since the entire code is in a single file |
19:59:36 | Araq | nimble should be able to forward most args you can pass to nim |
20:04:47 | * | sz0 joined #nim |
20:06:58 | shashlick | nimble doesn't seem to allow this, it's either -d:release or no args per the code |
20:07:08 | shashlick | https://github.com/nim-lang/nimble/blob/master/src/nimble.nim#L252 |
20:07:30 | * | dandevelo joined #nim |
20:09:50 | Yardanico | shashlick, are you sure? |
20:09:59 | Yardanico | ah, built from dir |
20:11:57 | * | dandevelo quit (Ping timeout: 240 seconds) |
20:13:58 | * | rauss joined #nim |
20:17:42 | dom96 | add it into a nim.cfg file? |
20:24:31 | Araq | dom96: now I remember, this *needs* to be added to nimble, is there an issue open for that? |
20:24:54 | Araq | I often have strange flags I need to add to nim and nimble wouldn't let me |
20:25:12 | dom96 | Why does nim.cfg not work? |
20:27:41 | FromGitter | <RedBeard0531> That can't be customized by the end user (easily) |
20:29:57 | dom96 | yes it can: use nimble c file.nim |
20:32:01 | * | Ven`` quit (Ping timeout: 248 seconds) |
20:33:39 | * | gsingh93- joined #nim |
20:35:02 | * | MJCaley quit (Quit: MJCaley) |
20:35:04 | * | Syneh_ quit (*.net *.split) |
20:35:04 | * | enigmeta quit (*.net *.split) |
20:35:06 | * | byteflame quit (*.net *.split) |
20:35:07 | * | EastByte quit (*.net *.split) |
20:35:07 | * | gsingh93 quit (*.net *.split) |
20:35:08 | * | gsingh93- is now known as gsingh93 |
20:36:25 | * | Ven`` joined #nim |
20:36:42 | Araq | dom96: it means I need to git stash the config changes, it works but it's not good enough |
20:37:28 | dom96 | nimble c file.nim? |
20:37:33 | dom96 | not good enough? |
20:49:44 | * | Ven`` quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
20:52:34 | * | MJCaley joined #nim |
20:52:55 | Araq | no. |
20:53:27 | * | nsf joined #nim |
20:54:26 | dom96 | I can guess why, but do please explain. |
20:54:34 | dom96 | My guess is that you've got a Nimble task that does the building |
20:55:06 | dom96 | Support for argument passing to tasks is already on my to-do list |
20:56:09 | * | Trustable joined #nim |
20:57:24 | FromGitter | <kasrasadeghi> Hi everyone! |
20:58:18 | Yardanico | hi |
20:59:24 | shashlick | dom96: it's not just on the command line, has to be possible through the .nimble file itself |
20:59:40 | shashlick | since the end user simply types nimble install xyz and won't know what extra flags are needed |
20:59:57 | FromGitter | <kasrasadeghi> does anybody know what it means when the compiler says `Hint: main [Processing]` |
20:59:58 | Yardanico | shashlick, there's nims and nim.cfg for this |
21:00:06 | shashlick | for the most part, i include most arguments as pragmas within the code, but that doesn't always work |
21:00:13 | Yardanico | kasrasadeghi: it means that compiler currently compiles main.nim file |
21:00:18 | Yardanico | shashlick, use nim.cfg? |
21:00:21 | Yardanico | it works with nimble |
21:00:33 | shashlick | nim.cfg is static, cannot have any dynamic info in it |
21:00:54 | FromGitter | <kasrasadeghi> @Yardanico: why would it need to tell me that though? it says the same thing for os, strutils, math, etc. |
21:01:28 | Yardanico | because it's a compiler? |
21:01:33 | Yardanico | and you want to see the progress |
21:01:38 | Yardanico | you can disable that |
21:01:53 | Yardanico | --hint[Processing]=off in nim.cfg or command-line |
21:01:56 | FromGitter | <kasrasadeghi> is that the -hint:off |
21:02:00 | dom96 | shashlick: What dynamic info do you want in it? |
21:02:02 | FromGitter | <kasrasadeghi> ooo alright thank you! |
21:02:06 | Yardanico | --hint:off will disable all hints whatsoever |
21:02:22 | dom96 | You can also do --verbosity:0 IIRC |
21:04:04 | FromGitter | <kasrasadeghi> --verbosity:0 seems to take away all of the hints that aren't hint[Processing] |
21:04:23 | dom96 | yep |
21:04:51 | shashlick | dom96: the same nimble version info - i know you did it the other way in nimble by having a common file |
21:04:52 | shashlick | but i'll have to create separate file and a directory structure |
21:04:52 | shashlick | all my code is in one file |
21:04:55 | shashlick | file.nim, file.nimble |
21:04:56 | shashlick | i cannot import file.nim into file.nimble for whatever reason |
21:07:15 | * | Syneh_ joined #nim |
21:07:15 | * | enigmeta joined #nim |
21:07:15 | * | byteflame joined #nim |
21:07:15 | * | EastByte joined #nim |
21:09:32 | FromGitter | <kasrasadeghi> looking at the tutorials, it seems like you don't really have a main() in nim |
21:10:30 | FromGitter | <ervinbosenbacher> main file |
21:10:42 | * | user0 quit (Quit: user0) |
21:11:05 | * | user0 joined #nim |
21:12:52 | FromGitter | <tim-st> in module `htmlparser` the lookup table `Entities` is implemented as an array this has probably worse lookup time than HashMap unless the compiler changes it |
21:13:52 | dom96 | shashlick: Just create the file and directory, don't be disgusted by it :) |
21:14:40 | Yardanico | kasrasadeghi: there's no need for it |
21:14:52 | Yardanico | you can of course still make main() proc and just call it |
21:15:31 | * | user0 quit (Client Quit) |
21:15:47 | * | user0 joined #nim |
21:17:28 | FromGitter | <kasrasadeghi> @Yardanico: that's the plan buddy :D |
21:18:04 | Yardanico | well why would you want main proc? |
21:18:11 | Yardanico | don't use styles from other languages |
21:18:36 | FromGitter | <kasrasadeghi> i don't want to entry point to have global names |
21:18:57 | FromGitter | <kasrasadeghi> that always bothered me about python scripts, and i'm using nim to rewrite a python script |
21:19:18 | * | MJCaley quit (Quit: MJCaley) |
21:19:26 | Yardanico | global names? |
21:19:26 | FromGitter | <kasrasadeghi> plus I like having main because it marks the root of the execution tree. You have one place to look for where things are happening |
21:19:40 | Yardanico | by default variables and procedures are not exported |
21:19:41 | FromGitter | <kasrasadeghi> if I use a name like |
21:19:48 | Yardanico | to other modules |
21:20:04 | FromGitter | <ervinbosenbacher> you need the * operator right? |
21:20:09 | * | Yardanico[Phone] joined #nim |
21:20:11 | Yardanico | yes |
21:20:15 | Yardanico | but it's not an operator :) |
21:20:21 | FromGitter | <kasrasadeghi> file_name, and then somewhere else in the file, inside a procedure, i want to call something file_name, then it would shadow the outside one. |
21:20:49 | Yardanico | well if you will re-declare it you won't have issues |
21:20:52 | shashlick | dom96: the whole point is for nimble install xyz to abstract all internal flags and whatnot, I can always build this manually any way I want by adding custom tasks, just that I want to use the standard method so that others can leverage it |
21:21:07 | FromGitter | <kasrasadeghi> i'd rather have them be encapsulated. |
21:21:12 | shashlick | dom96: looks like that's the only option at this time - I'm able to build with -d:VERSION=xyz but cannot do it by default in nimble install |
21:21:34 | * | Yardanico quit (Remote host closed the connection) |
21:22:09 | FromGitter | <tim-st> Is there a proc that takes a string with possible html entity within and returns a new string with translated entities to utf8? I've only seen htmlparser.entityToUtf8 which does it for single entities and I dont have a html document to parse |
21:22:41 | FromGitter | <tim-st> e.g. "A & B" --> "A & B" |
21:23:02 | FromGitter | <tim-st> `"A & B" --> "A & B"` |
21:24:37 | * | Trustable quit (Remote host closed the connection) |
21:28:43 | FromGitter | <kasrasadeghi> can't you do a map() |
21:28:47 | FromGitter | <kasrasadeghi> does nim have map() |
21:29:22 | miran | yes, in sequtils |
21:30:27 | FromGitter | <tim-st> It seems Entities table is only for special chars `&` is not there so there is no html decoding proc it seems |
21:32:34 | FromGitter | <kasrasadeghi> `proc applyT (data: var seq[T]; op: proc (x: var T) {..}) {..}` ⏎ `proc applyT (data: var seq[T]; op: proc (x: T): T {..}) {..}` |
21:32:39 | FromGitter | <kasrasadeghi> how are these two different? |
21:32:56 | FromGitter | <ervinbosenbacher> syntax |
21:33:15 | FromGitter | <tim-st> The first returns new T, the seconds writes on the T and changes it afaik |
21:33:19 | FromGitter | <ervinbosenbacher> its the same i think |
21:33:33 | FromGitter | <tim-st> I mean the opposite.. |
21:33:40 | FromGitter | <ervinbosenbacher> second assumes let |
21:34:07 | FromGitter | <ervinbosenbacher> ? |
21:34:42 | FromGitter | <kasrasadeghi> so the first one you give it a proc that mutates and apply does it for all elements ⏎ ⏎ and the second you give it a proc that does not mutate, and apply replaces each element with the result |
21:34:56 | FromGitter | <kasrasadeghi> i think |
21:40:11 | * | crem quit (Ping timeout: 255 seconds) |
21:41:11 | * | crem joined #nim |
21:41:49 | FromGitter | <kasrasadeghi> how would you guys make a GUI with nim? |
21:42:23 | FromGitter | <ervinbosenbacher> i think wxwidgets |
21:42:53 | Yardanico[Phone] | IUP/libui/wxwidgets/nigui/gintro |
21:42:59 | Yardanico[Phone] | Also nuklear |
21:43:28 | Yardanico[Phone] | These all use external libraries/c/c++ sources except nigui |
21:43:36 | FromGitter | <tim-st> I would write a gui using web based method and create a tcp server |
21:44:03 | Yardanico[Phone] | Maybe just use websockets? |
21:44:20 | FromGitter | <kasrasadeghi> that's true |
21:44:24 | FromGitter | <kasrasadeghi> might be good to learn |
21:44:27 | FromGitter | <ervinbosenbacher> @Tim I second that |
21:44:38 | FromGitter | <ervinbosenbacher> and I do that by the way |
21:44:51 | FromGitter | <kasrasadeghi> anyone know a good tutorial to get started? |
21:44:59 | FromGitter | <ervinbosenbacher> https://github.com/h3rald/litestore |
21:45:17 | FromGitter | <ervinbosenbacher> https://h3rald.com/litestore/ |
21:45:17 | FromGitter | <tim-st> I think today it's the best way and most compatible and there are nice frameworks |
21:45:37 | FromGitter | <ervinbosenbacher> look at the admin interface |
21:45:58 | FromGitter | <ervinbosenbacher> https://github.com/dom96/jester |
21:46:16 | FromGitter | <ervinbosenbacher> for the other web framework and maybe youcould use electron |
21:46:45 | FromGitter | <kasrasadeghi> this is nice! i did something similar with kotlin-spark |
21:46:52 | FromGitter | <tim-st> are there preview images? |
21:46:54 | FromGitter | <ervinbosenbacher> also I am still learning this bit but Nim can compile to Javascript directly |
21:46:56 | dom96 | shashlick: What I described is the standard method and won't affect your package's users. |
21:47:58 | FromGitter | <ervinbosenbacher> yeah it is nice one of the reasons I am here so I can build the c,c++, objective-c and javascript code in one languages |
21:48:34 | FromGitter | <kasrasadeghi> i should look into that. Do they have a thing like react too? |
21:48:43 | FromGitter | <ervinbosenbacher> and I am not limited cause uing FFI i can use whatever I want |
21:48:49 | FromGitter | <kasrasadeghi> wow they do |
21:48:53 | FromGitter | <kasrasadeghi> https://github.com/andreaferretti/react.nim |
21:49:44 | FromGitter | <ervinbosenbacher> yeah. I use this https://github.com/oskca/nimjs-vue |
21:50:14 | * | miran quit (Quit: Konversation terminated!) |
21:50:29 | FromGitter | <ervinbosenbacher> or the basis of that, anyway as our front is based on vue not react |
21:50:37 | FromGitter | <ervinbosenbacher> but react is good too |
21:50:58 | FromGitter | <kasrasadeghi> i'll look into both. thank you! |
21:51:25 | FromGitter | <ervinbosenbacher> its pretty awesome |
21:53:03 | Yardanico[Phone] | Nonono |
21:53:14 | FromGitter | <kasrasadeghi> https://github.com/pragmagic/karax |
21:53:16 | FromGitter | <kasrasadeghi> there's this too |
21:53:35 | Yardanico[Phone] | Use this one, yes :) |
21:54:02 | FromGitter | <ervinbosenbacher> brilliant thx!!! |
21:55:23 | FromGitter | <kasrasadeghi> to compile it to JS, do you do anything special? |
21:55:40 | shashlick | dom96: I presume you mean the common.nim and not the nimble c file.nim right? |
21:56:14 | dom96 | yes |
21:56:18 | Araq | dom96: I have nimble tasks yes and want to influence the building without editing the config/nimble file |
21:56:32 | Araq | glad to hear it's on your radar. |
21:56:41 | Yardanico[Phone] | Kasrasadeghi: nim js file.nim |
21:56:51 | FromGitter | <ervinbosenbacher> can you combine karax with electron? |
21:57:17 | FromGitter | <kasrasadeghi> @Yardanico: net thanks |
21:57:20 | FromGitter | <kasrasadeghi> neat* |
21:57:26 | FromGitter | <ervinbosenbacher> And there is Ormin |
21:57:33 | FromGitter | <ervinbosenbacher> https://nim-lang.org/araq/karax.html |
21:58:11 | FromGitter | <kasrasadeghi> what's the different between `include` and `import` |
21:58:25 | FromGitter | <ervinbosenbacher> Ok there is a lot to learn especially metaprgramming features of the language it seems |
21:58:34 | Yardanico[Phone] | Include just includes the file as is |
21:58:47 | FromGitter | <kasrasadeghi> C-style copypasta |
21:58:48 | FromGitter | <kasrasadeghi> classic |
21:58:50 | FromGitter | <ervinbosenbacher> I biught the book nim in action hopefully it coverks most of the stuff |
21:59:06 | FromGitter | <ervinbosenbacher> nope |
21:59:13 | Yardanico[Phone] | And import does a normal import like in Python |
21:59:13 | FromGitter | <ervinbosenbacher> include is not the same as import |
21:59:38 | Yardanico[Phone] | I didn't say it's the same |
22:00:04 | FromGitter | <ervinbosenbacher> no not you |
22:00:13 | FromGitter | <ervinbosenbacher> (just lazy typing out names) |
22:02:18 | FromGitter | <ervinbosenbacher> in the middle of code |
22:02:54 | FromGitter | <ervinbosenbacher> Wow karax is pretty awesome. I was thinking actually whether such thing exists where the framework is already written in Nim |
22:03:01 | FromGitter | <ervinbosenbacher> wow thx!!! :) |
22:03:08 | FromGitter | <ervinbosenbacher> an all nighter again |
22:04:07 | FromGitter | <kasrasadeghi> https://github.com/pragmagic/karax/blob/master/examples/todoapp/todoapp.nim |
22:04:17 | FromGitter | <kasrasadeghi> this has been helpful so far |
22:05:03 | FromGitter | <ervinbosenbacher> quick question/ is it production ready? |
22:05:18 | Araq | yes. |
22:05:57 | FromGitter | <ervinbosenbacher> Thanks. We will move our Electron app to this, I will look into it |
22:06:05 | * | nsf quit (Quit: WeeChat 2.0.1) |
22:07:03 | * | Yardanico[Phone] quit (Remote host closed the connection) |
22:07:19 | FromGitter | <ervinbosenbacher> inspired by vue and elm? |
22:07:45 | FromGitter | <kasrasadeghi> elm is great, can confirm |
22:08:05 | FromGitter | <kasrasadeghi> very very nice error reporting |
22:08:31 | * | dandevelo joined #nim |
22:08:55 | FromGitter | <ervinbosenbacher> :) yeah i know we went from react hype to angular then to vuejes 2 and then was looking into elm |
22:09:25 | * | Yardanico[Phone] joined #nim |
22:12:23 | FromGitter | <ervinbosenbacher> so what does karax actually do? |
22:13:03 | FromGitter | <kasrasadeghi> makes a DSL for integrating nim and html, as far as i can tell |
22:13:13 | * | dandevelo quit (Ping timeout: 265 seconds) |
22:13:16 | FromGitter | <kasrasadeghi> like jsx, but using nim's macros |
22:13:37 | FromGitter | <ervinbosenbacher> i just need to figure out how to integrate back the countless controls we have implemented in vim |
22:13:43 | * | gokr left #nim (#nim) |
22:13:45 | FromGitter | <ervinbosenbacher> or karax |
22:14:15 | FromGitter | <ervinbosenbacher> keep writing vim instead of nim :D |
22:14:50 | FromGitter | <ervinbosenbacher> i think i got this I will play withit later |
22:14:54 | FromGitter | <ervinbosenbacher> have fun |
22:16:20 | FromGitter | <kasrasadeghi> is there an autoimport thing? |
22:20:41 | Yardanico[Phone] | What it would do? |
22:21:03 | FromGitter | <kasrasadeghi> Like in vscode, when it shows that a symbol is missing |
22:21:13 | FromGitter | <kasrasadeghi> it would import the library that the symbol is probably from |
22:21:47 | Yardanico[Phone] | No |
22:22:01 | Yardanico[Phone] | But this can be implemented |
22:27:05 | FromGitter | <ervinbosenbacher> i have a question |
22:27:34 | FromGitter | <ervinbosenbacher> say one part tagets JS the other targets C how do we talk to each other? Sockets? |
22:27:42 | FromGitter | <ervinbosenbacher> using futures channels and sockets? |
22:30:22 | FromGitter | <kasrasadeghi> sockets are probably the way to go |
22:31:08 | FromGitter | <ervinbosenbacher> yeah I figured i would go with zmq or dRPC in any other case I just need to figure out what is the Nim way |
22:31:24 | Yardanico[Phone] | Also websockets? |
22:31:27 | FromGitter | <ervinbosenbacher> or microservices |
22:31:38 | FromGitter | <ervinbosenbacher> yes that websockets |
22:32:57 | FromGitter | <ervinbosenbacher> https://nim-lang.org/araq/karax.html |
22:33:10 | FromGitter | <ervinbosenbacher> is there a second part to this? with Ormin? |
22:36:11 | Yardanico[Phone] | No t yet |
22:36:52 | FromGitter | <ervinbosenbacher> Can I use Nim without GC? |
22:36:59 | FromGitter | <ervinbosenbacher> https://nim-lang.org/araq/destructors.html |
22:37:08 | FromGitter | <ervinbosenbacher> just quickly looking at this? |
22:39:46 | Yardanico[Phone] | This is not really tested, but you can |
22:40:07 | Yardanico[Phone] | Start with (two -)gc:none |
22:40:27 | Yardanico[Phone] | --gc:none but two - instead of -- |
22:40:41 | Yardanico[Phone] | Also why would you want to avoid GC? |
22:41:30 | FromGitter | <ervinbosenbacher> Just theoretical question for the future |
22:41:37 | FromGitter | <ervinbosenbacher> right now I dont, its fine |
22:42:33 | FromGitter | <zetashift> Also I think you lose some stdlib support if you disable it |
22:42:46 | FromGitter | <zetashift> The destructor thing is planned for the future(Nim v2) |
22:43:09 | Araq | the second part is done since forever but websockets don't work for some reason |
22:43:23 | Araq | -.- |
22:43:23 | FromGitter | <ervinbosenbacher> Nah its fine, if I dont need GC I use c++11/14/17 and talk to it using some IPC mechanism |
22:43:49 | FromGitter | <ervinbosenbacher> or I will use Nim v2 |
22:44:07 | FromGitter | <ervinbosenbacher> maybe I can contribute to Nim v2 |
22:44:25 | Yardanico[Phone] | It's just started :) |
22:44:33 | FromGitter | <ervinbosenbacher> Where? |
22:44:50 | Yardanico[Phone] | https://github.com/nim-lang/Nim/tree/nimv2?files=1 |
22:45:18 | FromGitter | <ervinbosenbacher> ah thx |
22:45:20 | FromGitter | <ervinbosenbacher> :) |
22:45:33 | Yardanico[Phone] | Also read https://github.com/nim-lang/Nim/wiki/Destructors |
22:46:12 | FromGitter | <ervinbosenbacher> Thats oretty cool stuff, actually I was searching for that about 30 minutes ago :D |
22:47:03 | Yardanico[Phone] | This page is about v2 destructors, not current ones :) |
22:47:22 | FromGitter | <ervinbosenbacher> is it safe to use v2? |
22:47:45 | Yardanico[Phone] | It's not really implemented yet |
22:47:52 | Yardanico[Phone] | As you can see by commits |
22:47:53 | FromGitter | <zetashift> @mratsim you there by any chance? |
22:47:57 | FromGitter | <ervinbosenbacher> yes |
22:48:02 | FromGitter | <ervinbosenbacher> browsing the source |
22:48:44 | Yardanico[Phone] | I think Araq will merge changes from devel where possible |
22:49:27 | Araq | yeah it's not really done in a branch but via a --newruntime switch |
22:49:42 | FromGitter | <ervinbosenbacher> its fine, I will spend next week to get fully knee deep in this so I understnad inside out. Really want to use it and contribute to it |
22:49:59 | Araq | --newruntime will use a cleaned up system.nim and a modified code generator |
22:50:26 | FromGitter | <ervinbosenbacher> faster? Smaller? Both? |
22:51:10 | Araq | eventually faster but more importantly better suited for embedded devices, interop with C++ and Python, etc |
22:51:19 | FromGitter | <ervinbosenbacher> I am writing a search engine aka Lucene nw I have a whole set of ideas around DSL for search |
22:51:30 | FromGitter | <tim-st> @Araq does nimsuggest evaluates results of const vars? if I type `const var1 = someCall` my system goes at 100% for ten minutes and now there is 3.3gb in memory |
22:51:33 | FromGitter | <ervinbosenbacher> awesome, |
22:51:44 | Araq | tim-st wow what? |
22:51:45 | FromGitter | <ervinbosenbacher> actually I am targetting embedded devices with this |
22:51:52 | Yardanico[Phone] | tim-st: on devel? Probably some bug in Nim vm |
22:52:15 | Yardanico[Phone] | Also is this proc really computation intensive? |
22:52:17 | Araq | but yes, nimsuggest is pretty much the full compiler without codegen |
22:52:20 | FromGitter | <tim-st> the call is pretty massiv: inserting wikipedia index in an orderedTable |
22:52:23 | Araq | so it does evaluate your consts |
22:52:26 | Yardanico[Phone] | Ah, it's nimsuggest |
22:52:32 | Araq | ah ouch. |
22:52:44 | FromGitter | <tim-st> does it do it again if I change nothing? |
22:53:09 | FromGitter | <ervinbosenbacher> ok @araq let me know if I can and where to contribute with v2 |
22:53:10 | Araq | if you don't touch the file it will be refreshed eventually iirc |
22:53:35 | Araq | ervinbosenbacher: I wrote this wiki for people like you. :-) |
22:53:42 | FromGitter | <tim-st> ok I will do `when false: .. else: ... ` for now |
22:53:50 | * | endragor quit (Remote host closed the connection) |
22:54:00 | Araq | when defined(nimsuggest) could also work |
22:54:15 | FromGitter | <ervinbosenbacher> this https://github.com/nim-lang/Nim/wiki/Destructors? |
22:54:22 | Araq | yes |
22:54:54 | FromGitter | <tim-st> btw can I do binarysearch on ordered set? |
22:54:57 | FromGitter | <ervinbosenbacher> i just dig into the issues list and go slowly |
22:55:35 | FromGitter | <tim-st> or better: return the next x results from position y |
22:56:51 | * | devdri quit () |
22:58:22 | Araq | tim-st: it's a set, so no. |
22:58:43 | FromGitter | <tim-st> but for what use case it's ordered than? |
22:58:51 | FromGitter | <tim-st> only echo? |
22:59:01 | Araq | ordered means it remembers the insertion order. |
22:59:28 | FromGitter | <tim-st> yes, and if I preorder it, it is ordered |
22:59:33 | Araq | the search uses hashing and doesn't support range queries, sad, I know. |
22:59:48 | FromGitter | <tim-st> can I access the underlying array? |
22:59:49 | FromGitter | <ervinbosenbacher> yes |
23:00:49 | FromGitter | <tim-st> Otherwise I will use ordered array with binarysearch but the lookup is Olog_2(n) vs O(1) |
23:01:47 | Araq | that doesn't mean much, you can also use an interpolation search to get it to O(log log N) or something like that |
23:01:52 | FromGitter | <ervinbosenbacher> just the classic batlle of what algo what data structure what search algo? |
23:01:52 | * | dddddd quit (Remote host closed the connection) |
23:01:55 | FromGitter | <ervinbosenbacher> :D |
23:02:12 | Araq | the real problem with the ordered array is that insertions are O(N) |
23:02:30 | Araq | as there are no holes to take advantage of. |
23:02:38 | FromGitter | <tim-st> no, problem because its constant and I do it once |
23:02:41 | FromGitter | <ervinbosenbacher> or just order it when you need to seacrch |
23:03:11 | Araq | ervinbosenbacher: That never works for hard realtime, unfortunately. |
23:03:39 | FromGitter | <tim-st> I dont see a use case for orderedSet/OrderedTable when this doesnt work |
23:03:49 | FromGitter | <tim-st> unless echo |
23:04:13 | FromGitter | <tim-st> and iterating all |
23:04:14 | Araq | huh? the benefits of ordered dicts are widely documented, Python moved to one |
23:04:47 | FromGitter | <ervinbosenbacher> :D :D yeah |
23:04:53 | Araq | the use case of "non pseudo random iteration order" is always nice for end users. |
23:05:00 | FromGitter | <ervinbosenbacher> my head is all over the place that is correct |
23:05:06 | * | MJCaley joined #nim |
23:05:32 | FromGitter | <ervinbosenbacher> its too late, python and related libs in C have a bnch of solutions |
23:05:59 | Araq | in fact, the compiler itself has bugs because it uses non-ordered dicts :P |
23:06:24 | Araq | or let's say the non-order makes the bugs more severe |
23:07:08 | FromGitter | <tim-st> If I think about my use case again ordered array is enough, but a combination of both would be best |
23:07:29 | FromGitter | <ervinbosenbacher> okay how abot hash tables |
23:08:05 | FromGitter | <tim-st> Hashtable is the same as set, with the difference that it store is value at this pos, I dont need the values, my keys are my values |
23:08:14 | FromGitter | <tim-st> *a |
23:08:32 | FromGitter | <ervinbosenbacher> ok |
23:09:18 | FromGitter | <tim-st> Maybe a third Set would be needed SortedSet this would be the thing I need |
23:09:51 | FromGitter | <tim-st> this would have insertion of O(n*lg(n)) but for const it's good |
23:10:18 | FromGitter | <ervinbosenbacher> python http://www.grantjenks.com/docs/sortedcontainers/index.html |
23:10:22 | FromGitter | <tim-st> no O(lg(n)) only :/ |
23:10:32 | FromGitter | <ervinbosenbacher> do we have that in nim? |
23:13:36 | Araq | I have a BTree implementation but it's not stdlib ready, in particular it lacks the 'delete' feature |
23:14:05 | FromGitter | <ervinbosenbacher> Actually i am working on a similar thing |
23:14:15 | FromGitter | <ervinbosenbacher> as of right now |
23:14:24 | Araq | a BTree is an excellent SortedSet |
23:15:02 | FromGitter | <ervinbosenbacher> Can you share? |
23:15:22 | FromGitter | <tim-st> Would be a really good type, if the proc names are the same or similar like the ones exists and if one can make it const like the others |
23:16:05 | Araq | oh it cannot easily be 'const', hmm. you're better off with a simple sorted seq then for now |
23:16:22 | Araq | ervinbosenbacker: it's not ready, sorry. |
23:17:19 | FromGitter | <tim-st> yes, that's ok. lg2(n) is already a very good runtime |
23:18:33 | Araq | as I said, use interpolation search, it's more fun |
23:18:58 | FromGitter | <tim-st> is it implemented? is this something like "minimal perfect hash function"? |
23:21:32 | Araq | no but https://en.wikipedia.org/wiki/Interpolation_search is not hard to implement |
23:21:47 | FromGitter | <tim-st> Have read it now sounds interesting, never heard before of it |
23:22:41 | Araq | keep your Sedgewick under your pillow |
23:25:17 | FromGitter | <tim-st> I will implement both for the wikipedia lookup and compare later which one does better |
23:28:57 | Araq | once you picked your pivot x compare the range y .. y+7 where y = x mod 64 since its free |
23:30:08 | FromGitter | <tim-st> why is it free? |
23:30:20 | FromGitter | <tim-st> shift? |
23:30:22 | Araq | well my math is wrong but you get the idea |
23:30:59 | Araq | data close to what you load is in the cache anyway so you might as well look at it |
23:31:26 | FromGitter | <tim-st> ok, thanks |
23:32:59 | * | Senketsu joined #nim |
23:37:00 | FromGitter | <ervinbosenbacher> I cant wat for v2, i desperately need that, embedded c++ and python. Ill see where I can help next week. |
23:40:02 | Araq | hey I feel your pain. I can guide you. |
23:40:24 | Araq | it's a ton of work but it's also pretty clear what and how to do. |
23:40:28 | FromGitter | <ervinbosenbacher> is there a roadmap somewhere? |
23:40:40 | FromGitter | <ervinbosenbacher> or a list of tasks? |
23:40:53 | FromGitter | <ervinbosenbacher> ETA? |
23:41:17 | * | claudiuinberlin quit (Quit: Textual IRC Client: www.textualapp.com) |
23:41:31 | Araq | I will write an RFC. |
23:41:40 | FromGitter | <ervinbosenbacher> look, initiallay I wanted to build something like Nim to meet my needs similar goals but then I found Nim 2 days ago and said yeah thats the stuff I want. |
23:43:14 | FromGitter | <ervinbosenbacher> The problem was that we wrote one thing in oen lang and another thing in another lang the porting libs back and forth between langs |
23:43:26 | FromGitter | <ervinbosenbacher> Rust, go, D c++ c and python |
23:43:38 | Araq | :-) |
23:43:44 | FromGitter | <ervinbosenbacher> Nim is perfect |
23:44:09 | Araq | well, no, but it's getting really good with the best things yet to come |
23:44:56 | FromGitter | <ervinbosenbacher> well yes I meant that is a perfect solution to my problem, cutting down that problem quite a bit |
23:45:40 | FromGitter | <ervinbosenbacher> anyway I need to know you plans so I can gear up and help as much as I can to get to that stage s fast as possible. |
23:46:16 | FromGitter | <ervinbosenbacher> I am building a startup called finddit.com and the more I am thinking about this the more I would like to base our core dev efforts on Nim |
23:46:49 | Araq | that's nice. any remarks on my destructor design? |
23:47:33 | FromGitter | <ervinbosenbacher> Not yet, still reading multitasking between coding, reading, learning. |
23:47:47 | FromGitter | <ervinbosenbacher> We are targeting Jetson TX2 with cuda |
23:48:15 | FromGitter | <ervinbosenbacher> and I am building a quick POC using Nim see how it performs |
23:48:39 | FromGitter | <ervinbosenbacher> rebasing some of the search engine code next week. |
23:48:58 | Araq | don't overheat ;-) |
23:49:02 | FromGitter | <ervinbosenbacher> Ok I get back to you |
23:49:28 | Araq | I'm always here, I never sleep. (nah, just kidding) |
23:49:30 | FromGitter | <ervinbosenbacher> I cant stop now, its been a long time i was that excited as now |
23:49:47 | FromGitter | <ervinbosenbacher> Right i do the same shit |
23:49:50 | FromGitter | <ervinbosenbacher> :D |
23:49:52 | FromGitter | <ervinbosenbacher> lol |
23:50:32 | FromGitter | <ervinbosenbacher> Need to try this on our embedded hardware |
23:50:50 | FromGitter | <ervinbosenbacher> i am building an embedded ubuntu image with Nim |
23:54:26 | FromGitter | <ervinbosenbacher> i was contributig to GCC and LLVM |
23:54:26 | FromGitter | <ervinbosenbacher> i will do this here now |
23:54:58 | Araq | cool more compiler devs is what we need :D |
23:55:25 | Araq | maybe you can help me with my dataflow analysis |
23:55:35 | FromGitter | <ervinbosenbacher> i was planning to contribute to D, after 2 key people left I got disapointed |
23:55:43 | FromGitter | <ervinbosenbacher> yes I can |
23:56:06 | FromGitter | <ervinbosenbacher> I have experience with Python code base, gcc and llvm, |
23:56:27 | Araq | I can't get the fixpoint iteration through the control flow graph to behave properly |
23:57:08 | FromGitter | <ervinbosenbacher> I will have a look next week, I need to get familar wit the compiler code |
23:57:21 | FromGitter | <ervinbosenbacher> and need to know what s the exact problem |
23:58:12 | Araq | well it's not important for anything |
23:58:23 | FromGitter | <ervinbosenbacher> cn you send me some logs? |
23:58:26 | Araq | but it would be nice to know how to do it properly |
23:58:51 | FromGitter | <ervinbosenbacher> and what is the misbeehavior |
23:59:23 | Araq | https://github.com/nim-lang/Nim/blob/devel/compiler/dfa.nim#L337 |
23:59:27 | FromGitter | <ervinbosenbacher> look, I am going to spend considerable time helping to build the tooling and the compiler I made up my mind today |
23:59:38 | FromGitter | <ervinbosenbacher> just give me some time to get familar |