00:06:34 | * | yglukhov joined #nim |
00:11:04 | * | yglukhov quit (Ping timeout: 265 seconds) |
00:14:25 | FromGitter | <Varriount> radagas: Well, the reference itself will be in the stack |
00:15:38 | * | qih_ joined #nim |
00:18:12 | FromGitter | <Varriount> `ref object ` types will always be allocated on the heap. `object types may be located on the stack or the heap, depending on if the are used by themselves, or embedded in another type. |
00:20:26 | * | SenasOzys_ joined #nim |
00:21:33 | * | SenasOzys quit (Ping timeout: 256 seconds) |
00:31:45 | * | qih_ is now known as qih |
00:38:38 | * | Jesin joined #nim |
00:39:14 | * | arecaceae quit (Remote host closed the connection) |
00:39:33 | * | arecaceae joined #nim |
00:41:23 | * | SenasOzys_ quit (Ping timeout: 256 seconds) |
00:51:53 | * | SenasOzys_ joined #nim |
01:00:50 | FromGitter | <SitiSchu> Is there something like type() from python in nim ? or any other way to find out the type of something ? |
01:01:07 | FromGitter | <Quelklef> ...what for? |
01:01:21 | FromGitter | <Quelklef> The things you use that for in Python are typically solved other ways in Nim |
01:05:13 | FromGitter | <SitiSchu> I'd just like a way to find out the type of things ^^ for example what this thing is: {'key': 'value'} |
01:06:26 | FromGitter | <Quelklef> For what, though? Debugging? |
01:06:37 | FromGitter | <Quelklef> also that's a list of 2-tuples iirc |
01:07:03 | FromGitter | <SitiSchu> Annotating the type and looking up the docs for it |
01:07:12 | FromGitter | <Quelklef> `[('key', 'value')]` |
01:07:47 | FromGitter | <Quelklef> https://stackoverflow.com/questions/28352559/how-to-get-the-type-of-a-value-as-string |
01:07:56 | FromGitter | <Quelklef> should suit your needs, I think |
01:12:54 | FromGitter | <SitiSchu> Thanks :) |
01:38:57 | * | skrylar joined #nim |
01:39:06 | skrylar | insert into nim values ('skrylar'); |
01:40:33 | FromGitter | <Quelklef> delete from nim where name='skrylar' |
01:40:52 | FromGitter | <Quelklef> ¯\\_(ツ)_/¯ |
01:41:37 | FromGitter | <SitiSchu> you forgot to specify the columns skrylar :P |
01:41:51 | FromGitter | <SitiSchu> ugh I need to turn of that auto emoji thingy |
01:41:56 | skrylar | at least mine was valid sql |
01:42:01 | FromGitter | <Quelklef> hey mine was too |
01:42:32 | FromGitter | <SitiSchu> shouldnt it be `insert into nim (column) values ('skrylar');` ? |
01:42:39 | FromGitter | <Quelklef> No, you can omit column names |
01:42:43 | FromGitter | <SitiSchu> ah |
01:42:54 | FromGitter | <Quelklef> and it'll just do the first column then second etc. i tihnk |
01:43:01 | FromGitter | <SitiSchu> yep |
01:43:11 | FromGitter | <SitiSchu> can be ommited if you provide values for all columns |
01:43:29 | FromGitter | <Quelklef> o |
01:43:36 | FromGitter | <Quelklef> been a while since I've done anything with sql |
01:43:39 | FromGitter | <Quelklef> ... thank the lord |
01:44:31 | skrylar | you can also eleave out optional columns which go to their defaults |
01:44:39 | skrylar | and in the case of firebird, triggers are probably involved :| |
02:06:58 | FromGitter | <RedBeard0531> If anyone is doing AOC and would be interested in seeing a nim program optimized to the point where a brute-force solution to today's puzzle is possible (<7hours): https://www.reddit.com/r/adventofcode/comments/7k572l/2017_day_16_solutions/drcxlcu/ |
02:23:51 | * | heinrich5991 quit (Quit: quit.) |
02:28:47 | * | marenz__ quit (Ping timeout: 248 seconds) |
02:29:08 | * | chemist69 quit (Ping timeout: 240 seconds) |
02:30:34 | skrylar | supercompilers? :) |
02:30:39 | skrylar | well, superoptimizers |
02:32:21 | skrylar | bleh. jenkins seems to have buried the docs on everything that isn't their latest pipeline setup, even though groovy pipeliens are the default |
02:32:38 | FromGitter | <zacharycarter> I can't stand jenkins |
02:41:41 | skrylar | i like the old parts they don't want you to use. they are straightforward and simple |
02:41:52 | skrylar | this new pipeline thing is ostensibly cool but it's not straightforward and simple |
02:42:31 | * | heinrich5991 joined #nim |
02:42:59 | * | chemist69 joined #nim |
02:53:04 | * | SenasOzys__ joined #nim |
02:53:15 | * | SenasOzys_ quit (Read error: Connection reset by peer) |
02:57:24 | * | MJCaley joined #nim |
03:07:20 | * | MJCaley quit (Quit: MJCaley) |
03:15:58 | skrylar | the terrifying thing is that i think its now theoretically possible to animate 3d models with a pencil |
03:16:10 | skrylar | there's a paper on recognizing stick figure drawings in to bone rigs |
03:17:32 | FromGitter | <ephja> neat |
04:08:40 | * | exit70 left #nim (#nim) |
04:12:13 | * | vlad1777d quit (Ping timeout: 255 seconds) |
04:54:18 | * | SenasOzys_ joined #nim |
04:54:43 | * | SenasOzys__ quit (Read error: Connection reset by peer) |
04:55:17 | * | endragor joined #nim |
04:58:46 | * | endragor quit (Remote host closed the connection) |
05:11:13 | * | SenasOzys_ quit (Ping timeout: 265 seconds) |
05:22:17 | * | SenasOzys_ joined #nim |
05:24:23 | * | endragor joined #nim |
05:29:15 | * | endragor quit (Ping timeout: 256 seconds) |
05:45:44 | * | dddddd quit (Remote host closed the connection) |
06:08:44 | * | endragor joined #nim |
06:13:19 | * | endragor quit (Ping timeout: 248 seconds) |
06:30:20 | * | wrigh720 joined #nim |
06:30:21 | * | wrigh720 quit (Remote host closed the connection) |
06:34:59 | * | methodtic692 joined #nim |
06:35:00 | * | methodtic692 quit (Remote host closed the connection) |
06:53:07 | * | endragor joined #nim |
07:05:35 | * | solitudesf joined #nim |
07:10:09 | * | Vladar joined #nim |
07:12:57 | * | solitudesf quit (Ping timeout: 264 seconds) |
07:33:21 | * | gokr quit (Ping timeout: 264 seconds) |
08:03:08 | skrylar | is the preferred way of dealing with openmp in nim to just use a bunch of emit's |
08:04:06 | * | qih quit (Quit: qih) |
08:09:47 | * | yglukhov joined #nim |
08:10:55 | * | yglukhov quit (Remote host closed the connection) |
08:11:24 | * | Vladar quit (Remote host closed the connection) |
08:15:06 | * | lastjedi joined #nim |
08:15:23 | * | couven92 joined #nim |
08:16:42 | * | solitudesf joined #nim |
08:17:36 | * | lastjedi quit (Remote host closed the connection) |
08:24:18 | * | nsf quit (Quit: WeeChat 1.9.1) |
08:37:58 | * | yglukhov joined #nim |
08:42:47 | * | yglukhov quit (Remote host closed the connection) |
08:46:53 | FromGitter | <mratsim> No: https://github.com/mratsim/Arraymancer/blob/master/src/tensor/backend/openmp.nim |
08:47:39 | FromGitter | <mratsim> Only needed emit for atomics: https://github.com/mratsim/Arraymancer/blob/master/src/nn_primitives/nnp_softmax_cross_entropy.nim#L106-L107 |
08:47:45 | skrylar | mratsim: that seems a rather incomplete openmp compared to http://www.openmp.org/wp-content/uploads/omp-hands-on-SC08.pdf |
08:49:57 | FromGitter | <mratsim> Works for me ™ |
08:50:09 | skrylar | maybe. supposedly i should learn that |
08:51:20 | FromGitter | <mratsim> With this I can implement parallel map and reduce. |
08:51:47 | * | yglukhov joined #nim |
08:51:50 | skrylar | nice |
08:52:18 | arecaceae | skrylar: straightforward and simple only to a shallow degree, you'll quickly hit something that makes you want to have pipelines it seems |
08:52:18 | * | claudiuinberlin joined #nim |
08:52:31 | arecaceae | skrylar: currently wrestling with jenkins myself tho |
08:52:54 | skrylar | it really depends what you're doing, arecaceae |
08:53:03 | arecaceae | skrylar: I'd love them to not use yet another obscure PL (groovy) nobody uses outside of it |
08:53:16 | skrylar | groovy is used in a lot of java projects |
08:53:22 | arecaceae | then I guess I'm just not a Java guy |
08:53:25 | skrylar | it's just unused outside of java guys |
08:53:39 | arecaceae | ahh isn't gradle using it as well? you're right |
08:54:03 | skrylar | now the grating part is that they use groovy by default, but are trying to hard sell blue ocean to the point they've hidden the groovy docs |
08:54:14 | skrylar | so you read these docs that don't work on the "recommended install" |
08:54:19 | FromGitter | <mratsim> parallel map, map2, map3: https://github.com/mratsim/Arraymancer/blob/master/src/tensor/higher_order_applymap.nim ⏎ parallel fold, fold over axis, reduce, reduce over axis: https://github.com/mratsim/Arraymancer/blob/master/src/tensor/higher_order_foldreduce.nim ⏎ ⏎ That’s Arraymancer secret sauce and I don’t think you can reproduce it cleanly in any other language. [htt |
08:54:19 | FromGitter | ... ps://gitter.im/nim-lang/Nim?at=5a3630ba232e79134d5cb6ae] |
08:54:43 | * | yglukhov quit (Remote host closed the connection) |
08:55:55 | skrylar | yea. i also read people discussing openmp and opencl |
08:56:09 | skrylar | the short consensus is that opencl will also handle vector intrinsics for you supposedly |
08:58:33 | skrylar | arecaceae, whats your usecase with jenkins? |
08:59:10 | arecaceae | skrylar: companies choice - but I can't find a valid alternative to propose either |
08:59:27 | skrylar | that's not a use case though :< |
09:00:02 | arecaceae | skrylar: well, what specifically do you mean with use-case |
09:00:32 | skrylar | in my case i didn't need pipelines because i'm just cross testing packages against stable and devel |
09:00:37 | arecaceae | skrylar: got a bunch of projects that need building in mostly archaic ways, integration with jira/scms/automailing and the like |
09:00:56 | skrylar | so it's just one master, old style multiconf project, and a basic "if [ $nim = unstable] change the path" |
09:00:56 | FromGitter | <mratsim> Are you sure it was OpenMP vs OpenCL, maybe OpenACC no? |
09:01:04 | skrylar | mratsim it was |
09:01:17 | arecaceae | skrylar: oh, looked into gitlab-ci ? |
09:01:18 | skrylar | openmp and opencl, they were discussing how openmp code still needs to be vectorized |
09:01:36 | FromGitter | <mratsim> You mean for SIMD? |
09:01:44 | skrylar | for math code yes |
09:02:23 | FromGitter | <mratsim> not an issue you can do “#pragma omp parallel for simd” if you want GCC/LLVM to generate simd code |
09:02:46 | skrylar | my old neural net code currently does rely on gcc converting the for loops to simd |
09:02:50 | FromGitter | <mratsim> and if speed is critical you will use intrinsics/hand-tuned ASM anyway which you probably can’t do with OpenCL |
09:03:29 | skrylar | its hard to say. there are some papers i'd like to implement, and it's not yet apparent where they can best run |
09:03:48 | skrylar | I would guess the CPU because these are doing strange neighborhood searches |
09:04:28 | FromGitter | <mratsim> I just use BLAS for linear algebra. For everything else there is OpenMP ;) |
09:04:36 | * | gmpreussner quit (Ping timeout: 260 seconds) |
09:05:14 | * | gmpreussner joined #nim |
09:05:38 | FromGitter | <mratsim> I’m pretty confident that Arraymancer is faster than anything else on CPU right now except if a framework implements TRIOT: https://github.com/mratsim/Arraymancer/issues/164 |
09:06:08 | arecaceae | skrylar: but yes people want multi-project job-pipelines at our place that jenkins seems to do well, why exactly, I have not figured out yet |
09:07:11 | skrylar | mratsim: i still have those blas tabs open, although time has been awkward. |
09:08:10 | skrylar | arecaceae, pipelines are good if you have very strange and arbitrary needs |
09:08:28 | arecaceae | skrylar: I feel like they beat unmaintained plugins you can easily implement in groovy yourself as well |
09:09:05 | arecaceae | skrylar: also gui-setting and exporting huge XMLs you have to dissect yourself doesnt seem that attractive as well |
09:09:10 | skrylar | i'm happy so far with some basic jobs and build-after rules. although i can see the appeal in that the multiconf job doesn't seem to understand things like "this is a windows machine" |
09:09:48 | arecaceae | skrylar: I tried this myself for a while - but as you noticed already, everything but pipelines feels like an abandoned ship pretty much |
09:09:56 | skrylar | pipelines seem to also mostly be useful for if you are doing shit like debian does, where you're running linters on packages |
09:10:28 | skrylar | since you get that pretty status box thats like, "oh running dpkg took this long and linting failed :D" |
09:10:34 | skrylar | but meh, i'm not shipping products |
09:12:34 | skrylar | mratsim: there may come a time aphelion starts using arraymancer |
09:13:01 | skrylar | although my current problems are incredibly weird research issues like "given a noisy signal with a varying mean, what impact do arbitrary milestones have?" |
09:13:32 | FromGitter | <mratsim> aphelion? your scratch tensor lib? |
09:13:40 | skrylar | it's a pile of AI code |
09:14:00 | skrylar | the crap tensors were the minimum viable code to run GRUs/tanhs/backprop |
09:15:28 | FromGitter | <mratsim> I see. I’m still on the fence on what to work next after I have a minimum viable MNIST: OpenCL, RNNs or SParse Tensors. For MNIST I’m only missing maxpooling |
09:15:40 | arecaceae | skrylar: if your use-case is simple tho, I feel like Jenkins should not be your first choice unless you want to get experience with it in particular, I saw nim uses gitlab-ci and that takes the easy: just yaml it route, nim seems to do fine with it? https://github.com/nim-lang/Nim/blob/devel/.gitlab-ci.yml |
09:16:24 | arecaceae | skrylar: doesnt have to be gitlab-ci, theres tons out there just relying on simle yaml files |
09:16:40 | arecaceae | skrylar: which unlike jenkins, you can also just run locally |
09:16:50 | skrylar | but i do just run jenkins locally... |
09:17:52 | arecaceae | skrylar: probably a waste of resources and time spent configuring then |
09:18:21 | skrylar | most of the time was me failing to remember shell scripting |
09:18:33 | skrylar | much less time spent getting jenkins to obey than buildbot was |
09:19:31 | arecaceae | skrylar: btw https://github.com/koalaman/shellcheck |
09:20:10 | skrylar | if i was also cross testing osx or windows it might add some weirdness |
09:20:59 | skrylar | also pondering if blockhash would be a brilliant idea for testing gui code |
09:27:14 | * | Vladar joined #nim |
09:27:54 | * | gokr joined #nim |
09:37:41 | * | gokr left #nim (#nim) |
09:44:39 | * | Drag333 joined #nim |
09:44:40 | * | Drag333 quit (Remote host closed the connection) |
09:46:33 | * | newn550 joined #nim |
09:46:34 | * | newn550 quit (Remote host closed the connection) |
09:59:05 | skrylar | whee, found a use for the critbit module |
09:59:06 | * | ra844 joined #nim |
09:59:08 | * | ra844 quit (Remote host closed the connection) |
09:59:22 | FromGitter | <mratsim> do tell |
10:00:43 | FromGitter | <alehander42> how can I test how the docs I write look? |
10:00:46 | * | solt551 joined #nim |
10:00:48 | * | solt551 quit (Remote host closed the connection) |
10:01:24 | FromGitter | <alehander42> ah `nim web` |
10:01:51 | * | rauss quit (Read error: Connection reset by peer) |
10:03:38 | * | rauss joined #nim |
10:03:47 | FromGitter | <mratsim> Rejoice! https://github.com/nim-lang/Nim/pull/6930 |
10:05:52 | skrylar | mratsim: using them to handle cells in miglayouts |
10:05:53 | * | Yardanico joined #nim |
10:07:03 | skrylar | with a two-byte string set to the current x/y it turns in to a sparse key so you can tell it "this element is two rows tall" and it becomes able to tell that a given cell is reserved by a previously specified cell |
10:07:33 | skrylar | critbit seems to work fine enough for this, for now |
10:08:54 | * | memol424 joined #nim |
10:09:16 | * | memol424 quit (Remote host closed the connection) |
10:09:51 | Yardanico | guys, did memol424 write something to you? |
10:10:03 | * | ladyami550 joined #nim |
10:11:05 | * | ladyami550 quit (Remote host closed the connection) |
10:13:06 | * | dddddd joined #nim |
10:17:42 | arecaceae | what's the hottest way to pass c/linker flags I need because I compile-pragma a c file that includes system-headers nim doesn't seem to want to be bothered with? |
10:18:36 | FromGitter | <mratsim> hottest? {.passC: "-fopenmp”.} and {.passL: "-fopenmp”.} if you want to hardcode this |
10:19:12 | arecaceae | mratsim: gorge for pkg-config still the way? |
10:19:15 | FromGitter | <mratsim> otherwise you can have that in a nim.cfg |
10:19:37 | FromGitter | <mratsim> I don’t know, I don’t use neither gorge nor pig-config :P |
10:19:41 | FromGitter | <mratsim> pkg* |
10:27:46 | arecaceae | I find wrapping c stuff to still be strange - I seem to have two options: either I wrap all of glib/gio whatever, the masses of converting headers of billions of lines of code by hand (because c2nim only does so much), OR, I just write a bunch of wrapper c files that expose the little functionality I want and end up writing like 100 lines of c, with no maintenance burden on me etc. |
10:29:01 | arecaceae | I know that depending on what you wrap, you'd want to really wrap the stuff 1:1, but for most I currently seem to care about, I really just only care for a small chunk of functionality out of a lib that its enormeous, and whenever I try to wrap it, I go down this rabbit-hole of figuring out how deep I have to go to wrap types and it ends up being way too much wrapper code |
10:30:15 | FromGitter | <mratsim> I think the one with the most experience for this is @StefanSalewski as he is wrapping/porting GTK to Nim |
10:30:35 | arecaceae | I saw his gio repo, last updated 1 year ago |
10:30:42 | Yardanico | wrong one |
10:31:04 | arecaceae | I mean it gets even worse, try wrapping xcb and all its ridiculous amounts of addons |
10:31:10 | Yardanico | https://github.com/StefanSalewski/gintro |
10:32:48 | FromGitter | <alehander42> @Araq I added some docs in https://github.com/nim-lang/Nim/pull/6841 , I am not sure about the order in website.ini, I just added it to the last group |
10:33:30 | skrylar | scripts help |
10:33:58 | skrylar | crm114, elisp |
10:34:40 | skrylar | in some cases back in the day D users were using GCC's xml mode to parse the c++ headers and then processing those, libclang is probably an option as well |
10:35:28 | skrylar | though wrapping as needed is very viable for some stuff shrug |
10:35:48 | arecaceae | just feels like insanity to me personally |
10:44:25 | * | yglukhov joined #nim |
10:59:59 | * | yglukhov quit (Remote host closed the connection) |
11:15:32 | * | jjido joined #nim |
11:19:12 | * | gokr joined #nim |
11:25:46 | * | yglukhov joined #nim |
11:26:17 | * | xkapastel quit (Quit: Connection closed for inactivity) |
11:30:38 | * | couven92 quit (Ping timeout: 265 seconds) |
11:35:33 | * | jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
11:46:39 | * | lithi13 joined #nim |
11:46:42 | * | lithi13 quit (Remote host closed the connection) |
11:58:59 | FromGitter | <mratsim> It seems like in master `block` became expression? This compiles in master but not in 0.17.2: ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5a365c021a4e6c82231c894c] |
11:59:30 | FromGitter | <mratsim> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5a365c215355812e57e68b4d] |
12:03:47 | skrylar | not sure whst the master branch is. i built it once and it still said 0.17.2 |
12:05:43 | Yardanico | he meant "devel" |
12:05:50 | Yardanico | master is always a release version |
12:05:55 | Yardanico | e.g. currently master contains 0.17.2 |
12:06:16 | Yardanico | and current devel contains 0.18.0/1.0 |
12:07:56 | * | vlad1777d joined #nim |
12:07:57 | skrylar | my devel build says 0.17.3 |
12:08:44 | Yardanico | yeah it is like this currently |
12:09:14 | Yardanico | because development versions are always 0.x.uneven number |
12:16:30 | * | miran joined #nim |
12:20:25 | FromGitter | <mratsim> yeah devel sorry |
12:20:41 | * | jjido joined #nim |
12:23:51 | * | marenz__ joined #nim |
12:47:34 | FromGitter | <GULPF> @dom96 I forgot to confirm my email on the forum, and now the confirmation email is gone (it went to the spam folder and got deleted after 30 days). Can you activate my account manually or something? I know the email is correct because I could reset the password |
12:47:54 | FromGitter | <GULPF> I'm GULPF on the forum to |
12:48:51 | dom96 | Sure, done. |
12:49:12 | FromGitter | <GULPF> thanks :) |
13:00:25 | FromGitter | <data-man> https://github.com/nim-lang/Nim/pull/6936 truecolor in a terminal :) |
13:02:55 | Araq | strformat has arrived |
13:04:51 | Araq | https://github.com/nim-lang/Nim/blob/devel/lib/pure/strformat.nim PRs welcome, I consider it rocksolid |
13:05:24 | Yardanico | did you write it yourself? |
13:05:27 | Araq | even installed Python to ensure I get left/-right alignments right |
13:05:32 | Yardanico | or it's a manual merge? |
13:05:38 | Yardanico | but amazing anyway |
13:05:58 | Araq | copied parts of bluenote's work, but rewrote most of it |
13:06:58 | Araq | spent 6 hours on it, way too long |
13:07:46 | skrylar | Araq, neat. |
13:07:57 | radagast | Unless {.inline.} pragma is passed, wouldn't the compilers automatically inline functions where seen fit? |
13:08:05 | Araq | the best thing is that it works out of the box with times.format |
13:08:44 | Yardanico | radagast, nim does that for iterators |
13:08:49 | Yardanico | and C compiler will do it if it wants |
13:08:55 | * | skrylar quit (Quit: Leaving) |
13:09:35 | FromGitter | <mratsim> I’m not sure gcc/clang can inline nim_call |
13:10:01 | FromGitter | <mratsim> I never saw it when I was benchmarking |
13:10:27 | Yardanico | maybe with aggressive GCC/Clang optimizations enabled? |
13:10:41 | Araq | enable linktime optimizations |
13:10:47 | Araq | and then it should work |
13:11:19 | FromGitter | <mratsim> good to know |
13:12:33 | dom96 | Araq: Awesome. |
13:12:45 | dom96 | Somebody really needs to fix the GitHub syntax highlighting for #[]# |
13:13:32 | Araq | runnableExamples is pretty neat, cuts the codesize quite a bit |
13:13:45 | Araq | but it was unusable until fixed some bugs :P |
13:15:48 | radagast | Ah. Thanks. Another thing. Have we considered to use an in-house fork of clang? I have a feeling that it would beget more ease of predictability and maintainability. Just a random thought. |
13:16:30 | Araq | you mean as an interim solution until our LLVM backend works with everything? |
13:16:34 | dom96 | Araq: You should make the examples collapsed by default |
13:16:38 | dom96 | that's a lot of examples |
13:17:10 | Araq | dom96, hmm but the examples are the best |
13:17:14 | * | yglukhov quit (Remote host closed the connection) |
13:17:19 | Araq | nobody reads the surrounding text |
13:17:38 | Araq | I could have fewer examples though and make the rest ordinary tests |
13:17:42 | dom96 | People will happily expand them |
13:17:52 | dom96 | and yeah, you probably should |
13:17:55 | dom96 | that's excessive |
13:18:03 | dom96 | 4 lines of examples is enough |
13:18:08 | radagast | Araq: Yes. Wait, are you talking about the NLVM project? I am new to the community, but are we considering to adopt it officially? |
13:18:20 | dom96 | and if you're showing something substantial then put it below a heading |
13:18:43 | Araq | radagast, I've said multiple times that as soon as it gives us one of the following, I'll merge it into the core |
13:18:52 | Araq | - better debugging |
13:18:54 | Araq | - a REPL |
13:19:01 | Araq | - faster exception handling |
13:19:06 | Araq | - precise GC |
13:20:15 | * | yglukhov joined #nim |
13:20:39 | Araq | radagast, what's the benefit of forking clang? protection against stupid C compilers? :-) |
13:20:56 | Araq | (cough, Visual C++, I'm looking at you ...) |
13:21:55 | miran | re strformat: wooohoooo!! nice job, Araq! |
13:23:45 | radagast | GCC and Clang.... they handle things differently, however if we choose to stick to compiler X, we could be able to utilize X's non-standard macros or other utilities. It would also make compiler behavior more "predictable". \nMSVSC is out of the question, completely non-portable and non-free |
13:23:54 | * | yglukhov quit (Remote host closed the connection) |
13:25:17 | Yardanico | radagast, but then it would be harder for others to port nim compiler to other platforms |
13:25:54 | Yardanico | E.g. for example I was able to run nim on Minoca OS (completely different OS with some posix compat) with minor config changes |
13:26:04 | Yardanico | because it has it's own GCC and it works |
13:26:31 | radagast | Yardanico: I see |
13:29:18 | Araq | well we could offer the C backend as is and still use a clang fork to avoid the dependency on Mingw |
13:29:44 | Araq | but since clang hardly supports windows iirc that is asking for trouble |
13:30:30 | Araq | we also need the backend into own executable to benefit from osproc.execProcesses to run codegen on multicore |
13:31:31 | Araq | the problem why we don't bundle mingw is its size, you can install it once and only reinstall Nim as it progresses |
13:31:52 | Araq | I don't know if clang would be significantly slower |
13:31:55 | Araq | er |
13:31:57 | Araq | *smaller |
13:32:45 | Yardanico | well |
13:33:48 | radagast | Just looked at strfmt. Fantastic job, Araq! No more of those manual concatenation on this & $that. |
13:34:41 | Yardanico | LLVM 5.0 installer for win64 is 92mb |
13:34:53 | Yardanico | it's only installer |
13:34:57 | Yardanico | http://releases.llvm.org/download.html |
13:35:18 | Araq | thanks but the credit goes to Bluenote, Dom and Python's design that happens to match Nim |
13:35:43 | Araq | I only did the finger excercise to implement it. |
13:36:00 | Yardanico | "Python's design that happens to match Nim" I see what you did there :P |
13:38:51 | FromGitter | <Varriount> Speaking of Python, this has made my day: https://www.python.org/dev/peps/pep-0562/ |
13:39:32 | Yardanico | custom __dir__ and __getattr__ for a module? |
13:39:33 | Yardanico | hmm |
13:40:36 | * | yglukhov joined #nim |
13:40:59 | miran | speaking of PEPs for 3.7: https://www.python.org/dev/peps/pep-0557/ |
13:41:02 | FromGitter | <Varriount> getattr is a function called when normal attribute access fails. dir() is a helper/debug function normally used to find the accessible attributes of an object. |
13:41:25 | Araq | I meant, Python's f-strings with the __format__ protocol was easy to adapt |
13:42:00 | Araq | getattr is Nim's "dot overloading" |
13:42:08 | Araq | it works |
13:43:28 | FromGitter | <Varriount> miran: I'm surprised 557 one made it in. |
13:50:27 | FromGitter | <alehander42> Awesome, I really missed interpolation |
13:55:06 | * | MJCaley joined #nim |
13:59:12 | * | jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
14:01:59 | radagast | `varargs[type]`'s `len` is an int as opposed to uint or any other unsigned arithmatic types. What's the rationale behind this? |
14:03:35 | * | nsf joined #nim |
14:04:19 | Araq | unsigned doesn't work, that's why |
14:04:24 | Araq | var x = s.len |
14:04:31 | Araq | while x >= 0: |
14:04:34 | Araq | echo x |
14:04:36 | Araq | dec x |
14:05:16 | Araq | all 'len's in Nim produce ints because int works, uint doesn't |
14:05:41 | Araq | uint is more a bit pattern than a number |
14:09:37 | radagast | What if, hypothetically, you were dealing with a massive linked list? Would an `int` for the list still be a good idea? |
14:10:51 | radagast | >9223372036854775807 |
14:10:53 | radagast | nvm |
14:16:50 | * | yglukhov quit (Remote host closed the connection) |
14:24:38 | FromGitter | <Varriount> radagast: Keep in mind that `int ` in Nim is the size of a pointer type. |
14:30:40 | FromGitter | <mratsim> `uint` is slower than `int` as well for all indexing operations because you would need to convert uint to int (pointer type). Also `uint` rollover on overflow which introduces extra checks for each uint operations, and makes counting error prone. |
14:31:44 | FromGitter | <mratsim> C++ designers said that using uint/size_t for indexing was a mistake. |
14:31:57 | FromGitter | <Varriount> Well, at the processor level, both int types overflow |
14:32:24 | FromGitter | <Varriount> I believe Araq would prefer saturated arithmetic. |
14:32:29 | FromGitter | <mratsim> Yes but the rollover introduce extra handling. |
14:33:19 | FromGitter | <Varriount> @mratsim Signed integers need to be checked for overflow too. |
14:34:00 | FromGitter | <Varriount> That's how the Nim compiler throws overflow errors. |
14:34:36 | FromGitter | <mratsim> But the compiler can just propagate the overflow error, and so can optimize the code as if it was bounded. |
14:36:08 | FromGitter | <mratsim> I don't know how to explain better :/ |
14:46:08 | * | jjido joined #nim |
15:18:43 | * | yglukhov joined #nim |
15:23:25 | * | jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
15:27:46 | * | safvav712t85 joined #nim |
15:34:40 | * | couven92 joined #nim |
15:42:08 | * | yglukhov quit (Remote host closed the connection) |
15:42:58 | * | yglukhov joined #nim |
15:55:55 | * | yglukhov quit (Remote host closed the connection) |
16:03:27 | Araq | Varriount: indeed I believe saturated arithmetic plus flow typing for array indexes is current the best tradeoff for correctness proofs |
16:15:41 | Yardanico | Araq, what do you think about https://github.com/nim-lang/Nim/issues/5600#issuecomment-352256858 ? |
16:15:52 | Yardanico | about runtime vs compiletime checks for formatting |
16:26:10 | Araq | I will later ajust the protocol to prefer formatStatic over format if available |
16:26:37 | Araq | at least that's the best idea I currently have, overloading based on static[string] could also be an option |
16:29:41 | * | endragor quit (Remote host closed the connection) |
16:32:34 | * | endragor joined #nim |
16:36:49 | * | endragor quit (Ping timeout: 248 seconds) |
16:42:06 | * | MJCaley quit (Quit: MJCaley) |
16:46:39 | * | endragor joined #nim |
16:52:35 | FromGitter | <data-man> @Araq: Centered alignment not supported? |
16:56:06 | * | endragor quit (Quit: Leaving...) |
16:59:02 | Araq | data-man: it is now, implemented the missing ^ and [sign] |
16:59:22 | Araq | the only feature that is still missing is '=' as I don't really understand yet what it does |
17:01:08 | FromGitter | <RedBeard0531> @Araq based on https://pyformat.info/#number_sign it looks like it puts the padding between the number and the sign |
17:01:48 | * | sendell joined #nim |
17:03:43 | sendell | is capturing a var param inside a closure illegal? |
17:03:49 | Araq | yes |
17:04:20 | * | sendell quit (Client Quit) |
17:04:20 | Araq | it would be very hard to support and keep memory safety |
17:12:18 | Araq | meh '=' looks hard to implement, nobody needs it, spaces between the sign and the number are ugly anyway |
17:13:35 | FromGitter | <RedBeard0531> I've never used it, but I think I've seen that style it on financial forms |
17:13:45 | * | Snircle quit (Quit: Textual IRC Client: www.textualapp.com) |
17:19:38 | FromGitter | <RedBeard0531> @Araq can you take a look at the approach I've taken here: https://github.com/nim-lang/Nim/compare/devel...RedBeard0531:tester_parallel. In particular, which nimcache name mangling do you prefer? I want to get that right before I fix up the tests that assume a fixed nimcache path. BTW, with just those two changes, "koch test cat stdlib" reruns go from 1:35 -> 43s since tests no longer clobber each other's caches. |
17:21:05 | * | SenasOzys_ quit (Ping timeout: 248 seconds) |
17:23:13 | Araq | RedBeard0531 subdir in nimcache/ means all the tools continue to work |
17:23:37 | Araq | and is what 'koch' uses too |
17:23:46 | Araq | I mean 'koch boot' |
17:24:59 | FromGitter | <RedBeard0531> do you mean nimcache/lib/blah/... or lib/blah/nimcache/... ? I think the current tester behavior is the latter, and my patch makes it the former. |
17:26:44 | * | xkapastel joined #nim |
17:30:43 | FromGitter | <RedBeard0531> Also, is tester intentionally not compiled with -d:release, or was that an oversight? I only did --opt:speed to keep the behavior the same while avoiding gcc's braindead -O0 codegen, but it you think -d:release makes sense I'll change it. |
17:34:15 | Araq | I only compile with -d:release if it's speed critical |
17:34:36 | Araq | the tester's runtime is probably 99% in execProcesses |
17:34:48 | Araq | and so shouldn't benefit from optimizations |
17:36:23 | FromGitter | <RedBeard0531> "tester html" takes a while, and its on the critical path since it can't happen in parallel with testing |
17:41:41 | FromGitter | <RedBeard0531> -d:release doesn't buy much (~2s) for it on top of --opt:speed (which buys a ton ~15s) so it doesn't seem worth changing |
17:50:48 | * | NimBot joined #nim |
17:51:00 | FromGitter | <RedBeard0531> is the nimcache dir provided as a define in compiled code? |
17:56:32 | * | yglukhov joined #nim |
17:59:27 | * | miran quit (Quit: Konversation terminated!) |
18:00:35 | * | yglukhov quit (Ping timeout: 240 seconds) |
18:02:07 | * | couven92 quit (Ping timeout: 248 seconds) |
18:16:11 | * | solitudesf quit (Quit: solitudesf) |
18:23:06 | * | solitudesf joined #nim |
18:28:41 | * | Trustable joined #nim |
18:31:45 | * | solitudesf quit (Quit: solitudesf) |
18:33:11 | * | tefter joined #nim |
18:33:26 | * | solitudesf joined #nim |
18:49:26 | * | MJCaley joined #nim |
18:52:17 | Araq | redbeard0531 no and I don't think code should rely on it |
18:52:38 | FromGitter | <RedBeard0531> turned out I didn't need it anyway |
18:54:00 | FromGitter | <RedBeard0531> I wanted it at one point for my own project since it uses re2c to generate c code and it seemed best to drop the generated file in nimcache |
19:03:39 | Araq | there is a PR that fixes html gen that I need to review and merge... |
19:04:33 | Araq | oh .4 for strings does truncate |
19:04:48 | Araq | we don't support that either ... oh well |
19:06:23 | * | sz0 joined #nim |
19:07:43 | * | mwbrown quit (Ping timeout: 255 seconds) |
19:09:40 | * | mwbrown joined #nim |
19:14:26 | * | Vladar quit (Quit: Leaving) |
19:22:05 | * | Vladar joined #nim |
19:35:15 | Araq | hmm these format strings are super error prone |
19:35:32 | Araq | 8< fails quietly 8< is the right syntax... |
19:36:15 | Araq | er <8 is the right syntax |
19:36:54 | Yardanico | Araq, i must admit I've only used f-strings in python to nicely embed variables (without using features like number formatting, left/right alignment) |
19:38:04 | Araq | well I dream of debugFmt("{x}") expanding to echo("x: " & x) |
19:49:48 | * | yglukhov joined #nim |
19:59:14 | * | nsf quit (Quit: WeeChat 1.9.1) |
20:02:08 | * | chemist69 quit (Ping timeout: 240 seconds) |
20:03:54 | * | Yardanico_ joined #nim |
20:05:45 | * | Yardanico quit (Ping timeout: 264 seconds) |
20:15:53 | * | chemist69 joined #nim |
20:17:18 | * | couven92 joined #nim |
20:22:30 | GitDisc | <treeform> I use this |
20:22:30 | GitDisc | <treeform> https://gist.github.com/treeform/7a41296e7c341c10c97cfe6181c7fe4c |
20:22:33 | GitDisc | <treeform> print x |
20:22:39 | GitDisc | <treeform> >> x=3 |
20:25:33 | GitDisc | <treeform> another cool thing that |
20:25:39 | GitDisc | <treeform> print x+2 |
20:25:46 | GitDisc | <treeform> x+3:5 |
20:25:53 | GitDisc | <treeform> x+2:5 |
20:33:45 | * | MJCaley quit (Quit: MJCaley) |
20:35:03 | * | Yardanico_ quit (Read error: Connection reset by peer) |
20:42:22 | Araq | treeform: cool macro |
20:58:40 | * | Trustable quit (Remote host closed the connection) |
21:02:52 | * | qih joined #nim |
21:12:58 | * | sz0 quit (Quit: Connection closed for inactivity) |
21:26:51 | * | SenasOzys_ joined #nim |
21:29:54 | FromGitter | <matrixbot> `pqflx3` Alexander Ivanov (Gitter): Alexander Ivanov (Gitter) From IRC (bridge bot) (Gitter) |
21:37:17 | FromGitter | <Yardanico> Wtf? |
21:38:07 | * | Jesin quit (Quit: Leaving) |
21:41:23 | * | Jesin joined #nim |
21:42:46 | * | yglukhov quit (Remote host closed the connection) |
22:02:19 | * | Vladar quit (Quit: Leaving) |
22:13:18 | * | yglukhov joined #nim |
22:15:33 | * | Trustable joined #nim |
22:15:36 | * | couven92 quit (Ping timeout: 260 seconds) |
22:17:27 | * | yglukhov quit (Ping timeout: 240 seconds) |
22:24:03 | FromGitter | <Quelklef> Good bot |
22:29:23 | * | Trustable quit (Remote host closed the connection) |
22:36:11 | * | solitudesf quit (Ping timeout: 265 seconds) |
22:48:42 | * | couven92 joined #nim |
22:56:30 | FromGitter | <Yardanico> Araq: is "termux" is being defined somewhere? It seems that the only way to use it is to manually define it in config/arguments |
22:57:00 | Araq | no idea, sorry |
22:58:41 | FromGitter | <Yardanico> Answer to myself: it's not defined anywhere and you should manually define it |
23:00:09 | Araq | now that you mention it ... that's what I remember too :P |
23:03:20 | FromGitter | <Yardanico> BTW, I'll probably make a PR to termux repo after new release (to avoid applying any patches except config) and maybe I can figure out a way to define termux on termux automatically |
23:04:40 | Araq | do we want truecolor support in the terminal? |
23:05:30 | FromGitter | <Yardanico> I saw @data-man's PR, why not? Sadly windows doesn't support it afaik |
23:06:20 | Araq | this PR doesn't work well |
23:06:37 | Araq | the idea of terminal.nim is to be stateless |
23:06:51 | FromGitter | <Yardanico> Ah, sorry, windows 10 actually supports it |
23:06:53 | Araq | proc setForegroundColor*(f: File, color: Color) is exactly what we don't do |
23:06:57 | FromGitter | <Yardanico> https://blogs.msdn.microsoft.com/commandline/2016/09/22/24-bit-color-in-the-windows-console/ |
23:08:28 | Araq | interesting how the terminal emulators are turning slowly into supporting a markup language |
23:08:41 | FromGitter | <RedBeard0531> now that strformat is in stdlib, how hard will it be to teach nimsuggest to do autocomplete inside the fmt"blah blah {expression.here}" |
23:08:57 | Araq | very :-) |
23:09:40 | FromGitter | <RedBeard0531> It seems there are basically two ways to build a gui at this point: embedding in either a terminal or a browser |
23:10:00 | FromGitter | <Yardanico> Build a gui in Nim? |
23:10:20 | FromGitter | <RedBeard0531> It can output to both a browser and a terminal, so sure :) |
23:10:25 | Araq | embedding in a terminal is not a way to build a gui |
23:10:46 | Araq | the 80ies called, they want Turbo Pascal's IDE back |
23:10:54 | FromGitter | <Yardanico> It's TUI :) |
23:11:01 | FromGitter | <RedBeard0531> have you seen vim or htop? |
23:11:23 | federico3 | is strformat not listed in https://nim-lang.org/docs/lib.html ? |
23:11:33 | FromGitter | <RedBeard0531> They even have mouse support in the term now! |
23:11:44 | Araq | federico3, it will be, the docs always refer to the latest release |
23:13:40 | Araq | RedBeard ... so like TP's IDE for DOS in 1985? |
23:13:45 | FromGitter | <RedBeard0531> btw, I think I worked out all the kinks in https://github.com/nim-lang/Nim/pull/6937 so it should be ready to review. With any luck it should make your local testing much faster after the first run. |
23:14:03 | FromGitter | <RedBeard0531> I was born in '86 :) |
23:14:07 | FromGitter | <Yardanico> Araq: I can check for termux by checking if file (which is present in termux only) exists, but I don't know if this is an acceptable solution |
23:15:34 | FromGitter | <Yardanico> But probably shipping edited config file is much better |
23:16:02 | Araq | yeah, that termux patch caused trouble for the people who could build on Android before |
23:17:40 | Araq | mouse support -- oh my what's next? putPixel support? |
23:19:24 | Araq | but my server farm has no monitor -- what do you mean by "why the fuck does it matter? by that logic it couldn't support ascii either" |
23:20:32 | FromGitter | <Yardanico> Well you can change pixels by writing into the framebuffer if you're in TTY :P |
23:21:29 | FromGitter | <RedBeard0531> Also the latest version of gnome-terminal support full-color emoji |
23:22:37 | FromGitter | <RedBeard0531> which I of course immediately put to good use: https://github.com/RedBeard0531/dot_files/blob/master/vimrc#L537-L539 |
23:26:35 | * | xkapastel quit (Quit: Connection closed for inactivity) |
23:28:32 | Araq | Bojack Horseman doesn't twitter emojis |
23:28:33 | * | gokr quit (Ping timeout: 264 seconds) |
23:29:33 | FromGitter | <RedBeard0531> (not sure if that will work over IRC) |
23:31:49 | * | claudiuinberlin quit (Quit: Textual IRC Client: www.textualapp.com) |
23:32:46 | FromGitter | <Yardanico> It will, depending on IRC client and font |
23:42:15 | * | astronavt joined #nim |
23:59:03 | * | oprypin quit (Quit: Bye) |
23:59:13 | * | oprypin joined #nim |