00:01:15 | * | couven92 quit (Quit: Client Disconnecting) |
00:02:52 | * | rupil quit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client) |
00:02:55 | * | alectic joined #nim |
00:08:11 | zachcarter | nevermind :/ |
00:08:14 | * | devted quit (Quit: Sleeping.) |
00:15:15 | zachcarter | I figured it out! |
00:15:19 | zachcarter | it was the word far |
00:15:33 | zachcarter | wtf...... |
00:15:37 | ldlework | what |
00:15:41 | zachcarter | seriously |
00:16:03 | zachcarter | in a source file I had the variable name far everywhere |
00:16:12 | zachcarter | changing it to faaar fixed my compilation issues |
00:16:28 | ldlework | how the fuck did you even come to think it was the issue and to change it |
00:17:05 | zachcarter | well this was only happening when cross compiling from debian to windows amd64 |
00:17:10 | ldlework | Nim: "Oh strange, it compiles now" |
00:17:46 | zachcarter | basically what clued me in was every line was failing on some reference to far |
00:17:48 | ldlework | zachcarter: I bet the underlying reason why is interesting. |
00:17:54 | zachcarter | oh I guarantee it’s a doozer |
00:17:57 | zachcarter | doozie |
00:17:58 | zachcarter | whatever |
00:17:58 | ldlework | hehe |
00:18:09 | ldlework | like "far pointer" or something |
00:18:12 | zachcarter | yeah |
00:19:54 | zachcarter | the source file compiles fine by itself to, only when referenced from another module do compilation issues crop up |
00:51:44 | FromGitter | <Varriount> zachcarter: 'far' is a nonstandard qualifier for pointer types. |
00:52:14 | ldlework | You'd think that compiling Nim would cause name-mangling to ocurr |
00:52:33 | FromGitter | <Varriount> ldlework: It does. But only for standard keyword |
00:52:44 | FromGitter | <Varriount> 'far' isn't standard |
00:57:30 | * | ftsf joined #nim |
01:03:46 | * | vlad1777d quit (Quit: Leaving) |
01:13:11 | * | bjz joined #nim |
01:25:44 | * | alectic quit (Quit: leaving) |
01:39:00 | * | chemist69 quit (Ping timeout: 252 seconds) |
01:52:46 | * | chemist69 joined #nim |
02:10:06 | * | bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
02:44:53 | * | rupil joined #nim |
03:08:36 | * | Snircle quit (Quit: Textual IRC Client: www.textualapp.com) |
03:11:43 | * | Snircle joined #nim |
03:15:01 | * | bjz joined #nim |
03:15:09 | zachcarter | interesting |
03:17:25 | ftsf | o/ morning yall |
03:17:35 | zachcarter | o/ |
03:18:31 | ftsf | how goes it zachcarter? |
03:18:48 | zachcarter | mmm we’ll see shortly ;P attempting to cross compile using docker atm |
03:18:56 | ftsf | oh cool |
03:18:57 | zachcarter | how about you? |
03:19:00 | ftsf | a docker cross compiler would be rad |
03:19:10 | ftsf | just working on my LDJAM game idea |
03:19:14 | ftsf | 40 hours left |
03:19:17 | zachcarter | oh nice! |
03:19:30 | zachcarter | yay! I’m down to linking errors in my docker cross compile |
03:19:42 | ftsf | need any help? |
03:19:50 | zachcarter | not yet but I might |
03:19:58 | zachcarter | I was fighting compile errors previously |
03:20:09 | zachcarter | took me all day to get through those :/ |
03:20:14 | ftsf | aww |
03:21:54 | zachcarter | doh well |
03:21:57 | zachcarter | getting there :D |
03:31:13 | * | bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
03:32:53 | FromGitter | <Varriount> zachcarter: Where can the space invaders game be downloaded? |
03:33:10 | zachcarter | Varriount: I’m working on that now :) |
03:33:17 | zachcarter | what OS are you looking for? |
03:33:45 | FromGitter | <Varriount> OSX |
03:33:54 | zachcarter | oh I can give you a binary now |
03:34:04 | zachcarter | the game’s not complete yet though |
03:34:12 | zachcarter | I still need to add levels and a HUD |
03:35:41 | zachcarter | Varriount: I’m working on a dockerfile that will allow users to cross compile to whatever target without having to install anything but docker |
03:37:53 | zachcarter | wewt |
03:38:07 | zachcarter | I think the cross compile for windows just worked |
03:39:25 | ftsf | \o/ |
03:44:13 | * | xet7 quit (Quit: Leaving) |
03:47:08 | zachcarter | Varriount: https://drive.google.com/drive/folders/0B2CfYyfxKriOb1NaNFh4S1ZCRlE?usp=sharing |
03:48:26 | * | xet7 joined #nim |
03:59:20 | FromGitter | <Varriount> zachcarter: could not load: libbgfx-shared-lib(Debug|Release).dylib |
03:59:45 | zachcarter | whoops forgot to include that |
04:00:46 | zachcarter | Varriount: https://drive.google.com/file/d/0B2CfYyfxKriOeHVFdHNNc1RoLWc/view?usp=sharing |
04:01:02 | zachcarter | needs to go in /usr/local/lib |
04:01:26 | FromGitter | <Varriount> blah. I like Window's dll search model |
04:01:33 | zachcarter | I agree |
04:02:27 | FromGitter | <Varriount> So, I've finally started learning Javascript. :| |
04:02:55 | ldlework | Its not as bad as the social currency you get from being edgy about it. |
04:03:14 | ldlework | But its no real great joy either. |
04:05:09 | zachcarter | hrm I’ve run into a situation with docker |
04:05:11 | zachcarter | again |
04:05:43 | zachcarter | I have a dockerfile building and compiling my project for windows on debian but I can’t figure out how to get the binaries off |
04:06:37 | zachcarter | I know I can do docker run with a volume option, but the thing is, my container doesn’t do anything it just builds the project so when I do docker run, it exist immediately |
04:06:53 | FromGitter | <Varriount> zachcarter: Would you mind if I submitted a sandbox file? |
04:07:06 | FromGitter | <Varriount> For OS X's sandbox-exec |
04:07:19 | zachcarter | nope |
04:09:35 | zachcarter | Idlework: any idea how to deal with ^ |
04:10:26 | zachcarter | oh -t and d flags apparently, sorry nevermind |
04:11:21 | * | rupil quit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client) |
04:11:43 | shashlick | is it possible to kill a thread that is spawn()'d or created via the threads module |
04:14:36 | FromGitter | <Varriount> shashlick: You mean, end it from another thread, forcibly? |
04:15:03 | FromGitter | <Varriount> Why do that, rather than send a signal to end? |
04:15:20 | shashlick | ya, i meant end |
04:16:58 | zachcarter | meh still confused |
04:17:28 | FromGitter | <Varriount> shashlick, have the worker thread read from a channel/data source. When it receives the end signal, have the main thread function return. |
04:17:58 | FromGitter | <Varriount> There are ways to 'kill' a thread (forcibly stop it) but you usually don't want to do that. |
04:18:28 | FromGitter | <Varriount> You end up with possible resource leaks, inconsistent state, etc. |
04:21:39 | shashlick | Varriount: cool, will look at channels |
04:22:13 | ldlework | zachcarter: just run a container `docker cp` |
04:22:39 | zachcarter | okay let me try that |
04:22:40 | zachcarter | thanks |
04:22:57 | ldlework | zachcarter: you can also do the bind mount |
04:23:04 | ldlework | so that it compile the binary into the volume mount |
04:23:23 | zachcarter | okay |
04:24:04 | ldlework | as a third choice, there is undocker |
04:24:14 | ldlework | I would personally likely go with the volume mount |
04:24:38 | FromGitter | <Varriount> docker seems really complex |
04:26:24 | ldlework | I don't mind answering any conceptual questions you mind have if you can author them. |
04:26:29 | ldlework | s/mind/might |
04:27:04 | ldlework | A good roadmap for understanding everything is |
04:27:28 | ldlework | Linux Kernel support for namespaces/cgroups -> Containerization -> Image distribution -> orchestration |
04:28:29 | nchambers | I'm looking at docker for a project of mine right now |
04:28:43 | nchambers | also, hello idlework. not sure if you remember me |
04:32:28 | ldlework | nchambers: name looks familiar, don't know what we talked about |
04:32:42 | nchambers | I was in here a long time ago |
04:32:44 | nchambers | many cycles |
04:34:40 | zachcarter | Varriount: did you manage to get it working? |
04:34:48 | FromGitter | <Varriount> zachcarter: One moment |
04:34:51 | zachcarter | sure |
04:42:25 | FromGitter | <Varriount> zachcarter: Ok, it works. |
04:42:31 | zachcarter | LD |
04:42:35 | zachcarter | err :D |
04:42:48 | FromGitter | <Varriount> zachcarter: It's probably the retina display, but the font was pixellated |
04:43:20 | zachcarter | hrm okay |
04:44:21 | FromGitter | <Varriount> How does the game detect/deal with fonts and resolution? |
04:45:06 | zachcarter | currently the only text in the game is rendered through one of two ways - nuklear or an image |
04:45:14 | zachcarter | so the buttons with the text are nuklear |
04:45:19 | zachcarter | without any skinning |
04:45:53 | zachcarter | nanovg support is on my short list which should give us TTF antialiased text |
04:46:02 | zachcarter | and then bitmap fonts will follow shortly thereafter |
04:46:54 | FromGitter | <Varriount> What is nuklear doing to render text? |
04:47:14 | FromGitter | <Varriount> I can't find any asset files with bitmap fonts in them, nor OT/TTF fonts |
04:48:19 | zachcarter | ah the font is actually stored in source |
04:51:08 | * | libman quit (Quit: Connection closed for inactivity) |
04:51:24 | FromGitter | <Varriount> Ok, I thought Python tutorials were good, but MDN tutorials on Javascript are just wonderful. |
04:53:23 | nchambers | Varriount: They're amazing! |
04:54:06 | FromGitter | <Varriount> Perhaps, one day, Nim documentation can be this good. :D |
04:56:32 | ldlework | MDN is really really good |
04:56:45 | ldlework | Only other resource as good, for a decade or so longer, was MSDN |
05:13:20 | * | Jesin joined #nim |
05:24:50 | shashlick | how do you get channels to work? var flag = Channel[bool] => Error: 'typedesc' metatype is not valid here; typed '=' instead of ':'? |
05:36:03 | shashlick | ugh never mind |
05:42:46 | shashlick | Varriount: how do you modify NimLime to handle --threads:on? |
05:43:45 | FromGitter | <Varriount> shashlick: try looking in user preferences |
05:45:11 | FromGitter | <Varriount> Otherwise, I can add something |
05:51:00 | * | Snircle quit (Quit: Textual IRC Client: www.textualapp.com) |
05:53:00 | shashlick | Varriount: don't see anything - there's a user settings file for NimLime but it's empty, not quite sure what to put in it |
06:01:38 | FromGitter | <Varriount> Look at the default |
06:02:10 | FromGitter | <Varriount> shashlick: default file contains the default settings. You copy those over to the user file and modify them. |
06:02:37 | shashlick | where do you define the nim command line? it's not in the settings? |
06:03:37 | FromGitter | <Varriount> Is there any relevant entry in the default settings file? |
06:03:46 | shashlick | I don't see anything |
06:03:51 | FromGitter | <Varriount> If not, then I'll need to modify NimLime |
06:04:09 | FromGitter | <Varriount> What OS are you on? |
06:05:01 | FromGitter | <Varriount> I'll need an hour (I'm baking at the moment) but you can create a bash file/shell script that invokes Nim with the right arguments as a workaround |
06:06:03 | shashlick | sure, i'll be fine, just curious no rush |
06:06:05 | shashlick | am on Win |
06:12:47 | * | yglukhov joined #nim |
06:41:50 | * | zachcarter quit (Quit: zachcarter) |
06:43:11 | * | yglukhov quit (Remote host closed the connection) |
07:01:21 | * | adeohluwa joined #nim |
07:10:56 | * | yglukhov joined #nim |
07:30:41 | * | gggs joined #nim |
07:34:18 | * | yglukhov quit (Remote host closed the connection) |
07:40:06 | * | bjz joined #nim |
07:40:08 | * | yglukhov joined #nim |
07:42:37 | * | shashlick quit (Ping timeout: 240 seconds) |
07:44:19 | * | shashlick joined #nim |
08:00:41 | * | willprice joined #nim |
08:10:59 | * | yglukhov quit (Remote host closed the connection) |
08:13:32 | * | couven92 joined #nim |
08:18:32 | * | yglukhov joined #nim |
08:31:18 | * | vlad1777d joined #nim |
08:43:58 | * | Tiberium joined #nim |
08:44:54 | * | Tiberium quit (Remote host closed the connection) |
08:45:11 | * | Tiberium joined #nim |
08:46:34 | * | Tiberium quit (Remote host closed the connection) |
08:46:46 | * | Tiberium joined #nim |
08:47:16 | * | Tiberium quit (Remote host closed the connection) |
08:47:28 | * | Tiberium joined #nim |
08:49:22 | * | Tiberium quit (Remote host closed the connection) |
08:49:34 | * | Tiberium joined #nim |
08:50:25 | * | Tiberium quit (Remote host closed the connection) |
08:54:14 | * | Tiberium joined #nim |
08:54:16 | Araq | https://github.com/pragmagic/karax check it out |
08:55:34 | * | Tiberium quit (Remote host closed the connection) |
08:57:27 | * | Tiberium joined #nim |
09:00:26 | dom96 | Araq: Why are some bars pink and others blue? |
09:00:38 | Araq | "Pink" == optimized version |
09:01:02 | Araq | I don't have a better screenshot right now, will update it later |
09:01:27 | dom96 | yeah, needs a legend :) |
09:02:48 | dom96 | also, add it to the package index |
09:02:55 | dom96 | and change your instructions to "nimble install karax" |
09:03:23 | dom96 | or include the git clone command |
09:03:38 | dom96 | since you want people to compile your examples |
09:03:44 | dom96 | Nimble doesn't support that (yet) :) |
09:05:32 | dom96 | Nice job though, looks awesome. |
09:05:32 | * | Matthias247 joined #nim |
09:06:02 | dom96 | I can tweet about it if you'd like |
09:07:22 | dom96 | Guys, I want to include some troubleshooting info in my book for the installation of Nim. Any common problems that you ran into or saw other users run into? |
09:07:59 | couven92 | git clone Nim does not include the dependency binaries on Windows |
09:08:25 | couven92 | like zlib, sqlite, openssl, etc |
09:08:46 | dom96 | Ahh, good one. |
09:09:15 | dom96 | I've got two so far, one is just "command not found: nim" when the user didn't put it in their PATH correctly. |
09:09:27 | dom96 | The other is the "Nim and C compiler disagree on target architecture" error |
09:10:36 | couven92 | I also found that it is convenient to let the Nim installation be under git, and therefore create a nim.cfg in APPDATA instead of modifing the installation nim.cfg |
09:17:38 | couven92 | ah, dom96, when you git clone Nim it ight make sense to checkout the latest release tag instead of the devel branch |
09:17:59 | dom96 | That's not how you should install a release |
09:18:07 | couven92 | ok... :P |
09:18:08 | dom96 | You should download it from nim-lang.org |
09:19:03 | * | adeohluwa quit (Quit: Connection closed for inactivity) |
09:30:07 | * | BennyElg quit (Remote host closed the connection) |
09:30:43 | * | rokups joined #nim |
09:31:13 | * | BennyElg joined #nim |
09:46:51 | Araq | dom96: please tweet later, I like more comments from the friendly Nim community first before the HN crowd destroys my work ;-) |
09:47:55 | FromGitter | <Varriount> Araq: That must mean we don't criticize you enough. :P |
09:50:57 | FromGitter | <Varriount> Though, I must say that this is rather timely - I'm currently learning JavaScript and node.js for work |
09:59:48 | Araq | do yourself a favour and go right after TypeScript (if you cannot convince others to try Nim) |
10:00:08 | Araq | there are language warts in JavaScript that no framework out there can fix |
10:22:39 | * | chemist69 quit (Ping timeout: 258 seconds) |
10:45:19 | couven92 | It is true though, that the nim community is friendly... Over in #csharp people keep telling rather gruesome stories about how hostile #java is :) |
10:49:25 | * | chemist69 joined #nim |
10:59:25 | * | xet7 quit (Quit: Leaving) |
11:03:06 | FromGitter | <Varriount> couven92: The room, or the language? |
11:03:17 | couven92 | the room |
11:03:27 | * | alectic joined #nim |
11:04:31 | * | Snircle joined #nim |
11:06:19 | * | yglukhov quit (Remote host closed the connection) |
11:32:51 | * | yglukhov joined #nim |
11:34:23 | * | yglukhov quit (Remote host closed the connection) |
11:34:36 | * | yglukhov joined #nim |
11:49:42 | * | Tiberium quit (Remote host closed the connection) |
11:50:34 | * | zachcarter joined #nim |
11:50:38 | * | Tiberium joined #nim |
12:15:18 | * | Arrrr joined #nim |
12:15:18 | * | Arrrr quit (Changing host) |
12:15:18 | * | Arrrr joined #nim |
12:27:14 | * | chemist69 quit (Ping timeout: 258 seconds) |
12:28:18 | * | chemist69 joined #nim |
12:40:03 | * | willprice quit (Remote host closed the connection) |
12:47:37 | * | Trustable joined #nim |
12:59:58 | Tiberium | can I somehow see normal Nim code generated by my macro? not AST tree |
13:02:26 | FromGitter | <hbakhtiyor> anyone using nim on production? and what kind of domain (rest api, desktop, ...) are you using? |
13:03:22 | Tiberium | hbakhtiyor: Araq uses Nim in production :) |
13:04:36 | zachcarter | yes |
13:04:40 | zachcarter | there are people that use nim in production |
13:04:44 | zachcarter | Unicredit does |
13:05:02 | zachcarter | I believe there’s another guy in here who works for a company that uses it in production but I’m sparse on the details I’m sorry |
13:05:49 | * | yglukhov quit (Remote host closed the connection) |
13:07:58 | FromGitter | <hbakhtiyor> @Tiberium, for what kind of domain? |
13:08:19 | Tiberium | hbakhtiyor: http://www.3dicc.com/ |
13:08:30 | Tiberium | Araq, is the creator of Nim |
13:09:13 | FromGitter | <hbakhtiyor> i see )) |
13:13:25 | FromGitter | <hbakhtiyor> i stuck with choosing between crystal & nim, but i think crystal has more active communities especially for web development |
13:15:43 | Tiberium | but Nim can compile to JS :) |
13:16:24 | Tiberium | but anyway, it's up to you |
13:17:04 | FromGitter | <gokr> Web dev these days ... IMHO html5 reigns and what you need on the server side is either a REST API or something based on websockets. The client is all js in some form or the other. |
13:17:53 | FromGitter | <gokr> Of course you can compile to js etc, but... I hesitate on the usefulness of such an approach. |
13:18:17 | * | DebugMan97 joined #nim |
13:18:17 | FromGitter | <hbakhtiyor> yeah, i need for rest api side only |
13:18:48 | DebugMan97 | Whats the idiomatic way to handle errors? I want to initialize some bindings on the toplevel. Should i raise some exception? |
13:19:13 | FromGitter | <gokr> Jester IIRC handles that quite fine. Dom96 knows more. |
13:23:03 | DebugMan97 | How do i return failure from toplevel to the os? I neet some equivalent to C's return EXIT_FAILURE; |
13:23:13 | dom96 | jester handles what fine? |
13:23:14 | Tiberium | DebugMan97, quit(1) |
13:23:43 | FromGitter | <gokr> Building REST apis |
13:23:51 | dom96 | Sure, of course. |
13:23:57 | dom96 | And it's used by many people already |
13:24:10 | dom96 | I should have some time to give it some well deserved love soon |
13:24:26 | dom96 | As for JS backend, it's definitely useful. I created this game using it: http://picheta.me/snake/ |
13:24:33 | FromGitter | <gokr> Another quite nice approach we use for Cordova apps is to use MQTT over websockets. |
13:25:14 | DebugMan97 | Tiberium: quit() is too agressive and harsh, and i guess it even skips all defer statements in the current block |
13:26:01 | Tiberium | DebugMan97, I don't know then. you can make some variable "failedCode" and at the end of the program exit with "quit(failedCode)" |
13:26:02 | * | bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
13:26:15 | dom96 | DebugMan97: You can define a "QuitError" or similar and just catch it at the top level. |
13:26:19 | dom96 | That's what I do in Nimble |
13:26:36 | dom96 | when an unrecoverable error occurs I just raise a NimbleError. |
13:30:22 | * | TheLemonMan joined #nim |
13:30:57 | * | bjz joined #nim |
13:31:33 | DebugMan97 | does calling quit(...) as the last toplevel statement has any hidden consequences? |
13:33:43 | Tiberium | What can be the reason of "???(???, 0) Error: internal error: genLiteral: ty is nil" in macro? |
13:33:50 | Tiberium | internal compiler error |
13:40:50 | ftsf | making my Ludum Dare game in Nim at the moment, it's so dreamy and productive to use <3 |
13:41:34 | Araq | Tiberium: it means you should file a bug report |
13:41:41 | Tiberium | Araq, ok |
13:44:00 | FromGitter | <hbakhtiyor> @dom96 how is fast compare with http://kemalcr.com/ crystal version? |
13:44:06 | DebugMan97 | why doesn't error() write anything by default? Should i prefer stderr.write() |
13:44:36 | Araq | DebugMan97: quit() is C's exit(), error() is for the macro system |
13:45:12 | DebugMan97 | i mean logger's error |
13:49:55 | * | alectic quit (Quit: leaving) |
13:50:46 | Araq | dunno, I don't use logging, but it should work |
13:52:47 | Tiberium | Araq, maybe it's not a compiler bug but my stupidity? this is a repro - https://gist.github.com/TiberiumN/66dcf68e71578f01936ea868c687088f |
13:53:42 | Tiberium | Araq, it happens only if I do strCmds.add(anything) on line 16 |
13:53:49 | Tiberium | so even strCmds.add("a") produces an error |
13:53:55 | zachcarter | DebugMan97: you need to add handlers |
13:53:59 | Araq | how is an internal error not a compiler bug? |
13:55:41 | * | nightmared quit (Quit: WeeChat 1.7) |
13:57:29 | Araq | hbakhtiyor dunno, it's fast enough anyway |
13:57:48 | Araq | you're rich before its performance becomes an issue |
13:58:38 | Tiberium | Araq, oh wait, my Nim was on zahary branch, I'll try on devel now. If it will be OK, I'll report it to zah |
13:59:33 | DebugMan97 | nim feels quite lispy and crispy despite having python syntax <3 |
14:00:07 | * | yglukhov joined #nim |
14:00:20 | TheLemonMan | where's the lispyness? |
14:00:24 | Tiberium | Araq, eh, it crashes on devel too :( Will submit an issue now |
14:00:48 | DebugMan97 | TheLemonMan: just look at the cool stuff one can do with template, macros, const expressions |
14:01:15 | zachcarter | DebugMan97: did you figure out logging? |
14:01:33 | dom96 | ftsf: what you making? :) |
14:01:57 | TheLemonMan | a spoonful of metaprogramming features don't make a language lispy, at least IMO |
14:01:58 | * | yglukhov quit (Remote host closed the connection) |
14:02:12 | DebugMan97 | zachcarter: setting up a logger would be overkill. I just print to stderr and return 1 |
14:02:25 | Tiberium | Done - https://github.com/nim-lang/Nim/issues/5746 |
14:02:26 | zachcarter | right but you were asking why error didn’t do anything |
14:02:27 | dom96 | hbakhtiyor: not sure, but what Araq said is true. |
14:02:43 | TheLemonMan | this said I'm enjoying my trip inside the compiler |
14:02:57 | zachcarter | just wanted to make sure you understood why |
14:03:07 | ftsf | dom96, a little puzzle game about making aliens happy. |
14:03:16 | DebugMan97 | zachcarter: i've read your answer but didn't reply ^^ |
14:03:20 | DebugMan97 | thanks |
14:03:29 | zachcarter | haha np I just didn’t want you to be confused |
14:04:22 | dom96 | I see new people. Welcome everyone :) |
14:04:58 | DebugMan97 | and i see nim functions have implicite return values :O |
14:05:01 | zachcarter | dom96: if you get a chance this weekend maybe we can talk about the nim playground |
14:05:29 | zachcarter | because the extremely little effort I put into it, actually produced something that works locally anyway |
14:05:30 | dom96 | zachcarter: sure, I'll have more time tomorrow. |
14:05:36 | zachcarter | sweet :D |
14:06:29 | zachcarter | ftsf: docker cross compiling is working well |
14:06:50 | ftsf | zachcarter, awesome! |
14:06:52 | zachcarter | I think it might be the answer to how to distribute games built with frag |
14:07:35 | ftsf | https://twitter.com/impbox/status/855777847281041408 |
14:08:13 | zachcarter | looks cool! |
14:08:45 | * | nightmared joined #nim |
14:17:09 | * | DebugMan97 quit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client) |
14:40:53 | zachcarter | does anyone have any recommendations for setting up a gnu toolchain on windows? |
14:41:16 | zachcarter | 64 bit |
14:41:50 | zachcarter | is winbuilds the best option? |
14:52:41 | ftsf | zachcarter, i just used mingw64, seemed to work fine |
14:52:49 | ftsf | mingw-w64 |
14:52:56 | zachcarter | hrm it does work but it doesn’t come with make |
14:53:05 | ftsf | true, i installed make separately |
14:53:17 | zachcarter | did you use anything to install make or did you just go find it and install it? |
14:53:31 | ftsf | hmm http://gnuwin32.sourceforge.net/packages/make.htm |
14:53:37 | zachcarter | thanks! |
14:55:51 | * | bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
15:10:25 | TheLemonMan | uhh, I guess #5764 happens because `strCmds` expands to a nkBracket of nkStrLit where the semExpr hasn't been run on yet thus the typ is nil at that point |
15:11:33 | TheLemonMan | I must admit the macro system is pretty sick |
15:15:31 | * | yglukhov joined #nim |
15:27:39 | Tiberium | TheLemonMan, yeah, it is :) |
15:27:49 | Tiberium | TheLemonMan, this crash is fine for me, since I've chose another approach anyway |
15:32:26 | zachcarter | http://community.fragworks.io/t/recruiting-help-wanted/15 |
15:33:29 | FromGitter | <hbakhtiyor> anyone know any dom manipulation library? ⏎ e.g. for golang https://github.com/PuerkitoBio/goquery |
15:34:24 | FromGitter | <stisa> zachcarter : mingw comes with mingw32-make no? |
15:34:45 | zachcarter | I wasn’t finding it but I could have veryw ell missed it |
15:36:16 | * | gokr joined #nim |
15:41:31 | FromGitter | <stisa> @hbakhtiyor with the js backend you can use dom, but it's lower level than jquery, with c I don't know, try looking on https://nim-lang.org/docs/lib.html |
15:49:48 | TheLemonMan | Tiberium, a simple workaround is to use 'var tmp = $strCmd' |
15:52:40 | * | libman joined #nim |
15:58:08 | * | Arrrr quit (Ping timeout: 240 seconds) |
15:58:44 | * | Trustable quit (Remote host closed the connection) |
16:04:21 | FromGitter | <Varriount> @hbakhtiyor There's also the parsexml module |
16:08:27 | * | yglukhov quit (Remote host closed the connection) |
16:18:55 | FromGitter | <Varriount> @stisa Mingw doesn't always come with make installed. |
16:24:43 | FromGitter | <stisa> @Varriount interesting, I got it from https://mingw-w64.org/doku.php/download so I thought it was in the standard bundle |
16:29:34 | * | Vladar joined #nim |
16:35:38 | FromGitter | <Varriount> @stisa there's several variants of mingw floating around |
16:46:22 | * | couven92 quit (Quit: Client Disconnecting) |
17:06:00 | * | Snircle quit (Quit: Textual IRC Client: www.textualapp.com) |
17:11:38 | * | TheLemonMan quit (Quit: "It's now safe to turn off your computer.") |
17:12:50 | demi- | hmmm, is there a method for normalizing a file path? |
17:13:27 | demi- | i see that there is `expandFilename` but that only works for paths that already exist, I want to normalize two file paths to compare them |
17:29:55 | * | Arrrr joined #nim |
17:29:55 | * | Arrrr quit (Changing host) |
17:29:55 | * | Arrrr joined #nim |
17:30:43 | * | krux02 joined #nim |
17:38:02 | * | Matthias247 quit (Read error: Connection reset by peer) |
17:39:55 | Tiberium | ehm, how to get string value from nnkIdent? |
17:40:28 | * | krux02 quit (Disconnected by services) |
17:40:28 | * | krux02- joined #nim |
17:40:31 | * | krux02- is now known as krux02 |
17:40:46 | Tiberium | "Error: field 'strVal' cannot be found" |
17:41:01 | * | krux02_ joined #nim |
17:42:26 | Tiberium | ah, nvm |
17:43:22 | Tiberium | $ident |
17:56:10 | * | gokr quit (Read error: Connection reset by peer) |
17:56:47 | * | nsf joined #nim |
17:59:20 | * | krux02 quit (Remote host closed the connection) |
18:11:10 | krux02_ | Tiberium, repr also works |
18:14:32 | dom96 | please don't use repr for that |
18:19:06 | krux02_ | dom96: why? |
18:19:15 | krux02_ | is repr only for debugging? |
18:20:07 | krux02_ | anyway I have to go |
18:20:11 | * | krux02_ quit (Remote host closed the connection) |
18:26:20 | demi- | dom96: do you have any preferences on how i should implement tests for my PR? |
18:32:17 | * | rokups quit (Quit: Connection closed for inactivity) |
18:43:20 | * | McSoFake joined #nim |
18:45:25 | * | Snircle joined #nim |
19:22:22 | Tiberium | It seems I've found something like pygame in python - https://github.com/oprypin/nim-csfml |
19:22:44 | Tiberium | look at this! https://github.com/oprypin/nim-csfml/blob/master/examples/typing.nim |
19:24:24 | zachcarter | Tiberium: you should just use frag :P |
19:24:34 | Tiberium | zachcarter, it's not that easy at the moment :) |
19:25:05 | zachcarter | hopefully it will be easy to use soon |
19:25:12 | Tiberium | zachcarter, really? |
19:25:21 | Tiberium | zachcarter, you'll start developing high-level API? |
19:25:35 | zachcarter | oh it’s already about as high level as libgdx, do you want something more high level than that? |
19:26:12 | zachcarter | I guess the thing it needs is documentation |
19:27:12 | zachcarter | right now what I’m working on is distribution |
19:27:22 | zachcarter | then I’ll need to refocus on documentation again |
19:27:40 | zachcarter | but this docker thing is working - it’s quite easy now to cross compile the space invaders demo to windows from whatever os you’re on |
19:40:54 | * | chemist69 quit (Ping timeout: 255 seconds) |
19:41:01 | Tiberium | ehm, lol |
19:41:02 | Tiberium | https://jscheid.github.io/nim-sandbox/index.html |
19:41:10 | Tiberium | it's working for simplest code examples |
19:41:13 | Tiberium | https://github.com/jscheid/nim-sandbox |
19:43:46 | zachcarter | oh it’s generating javascript |
19:43:47 | zachcarter | cool |
19:44:02 | zachcarter | well I guess I can throw mine away :P |
19:44:42 | zachcarter | oh maybe not |
19:44:43 | zachcarter | 2 years ago |
19:45:54 | FromGitter | <stisa> Tiberium: Interesting, nim 0.12.0, and it looks like it compiles the compiler with emscripten? |
19:46:00 | Tiberium | yes |
19:46:12 | Tiberium | I don't know how I found it |
19:46:14 | Tiberium | ah, I know |
19:46:26 | Tiberium | "dll inject language:Nim" github |
19:46:28 | Tiberium | latest result |
19:46:33 | Tiberium | (on the first page) |
19:53:19 | * | DebugDude12 joined #nim |
19:54:03 | DebugDude12 | Whats the proper way to get the size of a float matrix [array of an array]? |
19:54:09 | DebugDude12 | I need to allocate its amount on the gpu |
19:54:20 | Tiberium | zachcarter, i'm trying to use it with latest nim out of curiosity :) |
19:54:31 | zachcarter | nice! |
19:55:49 | DebugDude12 | my naive approach would be to: a.len * sizeof(a[0][0]) or something like that |
19:57:09 | FromGitter | <stisa> DebugDude12 : did you try `sizeof(a)` ? If you aren't using ref types in `a` it I think it should work |
19:57:28 | * | Jesin quit (Quit: Leaving) |
19:57:50 | DebugDude12 | stisa: i didn't try anything yet, since i don't know whether sizeof() also considers an array's metatada, length, etc |
19:58:29 | zachcarter | openal is annoying |
19:58:42 | zachcarter | in that they don’t publish just a dll for their stuff they have an installer |
20:01:35 | DebugDude12 | Tiberium: you use opengl. How did you determine the size of a matrix to push as VBO via glBufferdata? |
20:01:50 | Tiberium | DebugDude12, I don't use opengl? |
20:01:55 | Tiberium | (really) |
20:02:12 | DebugDude12 | ah, i tought it was you who is writing game engines here ^^ |
20:02:21 | Tiberium | no, it's zachcarter |
20:02:28 | DebugDude12 | sorry |
20:03:51 | zachcarter | hrm I don’t think you should be buffering matrices |
20:04:07 | zachcarter | unless you’re doing something crazy I don’t know about |
20:04:28 | zachcarter | generally you have a struct representing your vertex / tex coord / color / whatever data |
20:04:46 | zachcarter | and the size of the buffer is the number of vertices you’re buffering * the size of the struct |
20:04:54 | DebugDude12 | just pushing a triangle to the gpu and considered using a matrix. I don't know if a simple array would be more nim-my |
20:06:18 | DebugDude12 | i guess i stick to an array then, since all the C++ tuts do this. Just hoped there was a nim way™ |
20:06:39 | zachcarter | krux02 does all sorts of crazy buffering stuff with nim macros |
20:06:46 | zachcarter | I don’t even use opengl actually |
20:06:52 | zachcarter | I mean I do, but through an abstraction layer |
20:06:58 | ftsf | so adding to a seq while iterating is bad apparently, what's the alternative way? |
20:07:14 | zachcarter | use a for loop |
20:07:15 | zachcarter | or |
20:07:23 | zachcarter | use 2 seqs and concat them |
20:07:33 | zachcarter | when I say for loop I mean |
20:07:37 | zachcarter | for i in 0..<seq.len: |
20:07:49 | DebugDude12 | what does sizeof( some_array ) return? The number of elements? Or the whole internal C struct/wrapper? |
20:08:00 | * | chemist69 joined #nim |
20:08:09 | zachcarter | the size of the array and the elements |
20:08:13 | zachcarter | not the count of elements |
20:08:19 | ftsf | ahh |
20:08:42 | zachcarter | best way DebugDude12 is: |
20:09:01 | zachcarter | some_array.len * sizeof(type_of_some_array_member) |
20:09:27 | ftsf | that works |
20:10:07 | DebugDude12 | zachcarter: i guess thats the way to go. Anything else doesn't seem to be specified and may break in future. |
20:10:41 | zachcarter | *nods |
20:11:32 | FromGitter | <stisa> Dunno, I like sizeof(arr) : https://glot.io/snippets/ep6p12ftv8 |
20:12:51 | zachcarter | https://gist.github.com/zacharycarter/66b5dc47ab0cfd677585fc389c0046df |
20:12:53 | DebugDude12 | stisa: sizeof seems to ignore an arrays internal representation in your case |
20:12:55 | zachcarter | Dockerfiles |
20:18:20 | Tiberium | zachcarter, well, new nim compiler compiled to js (it seems) successfully, but I can't launch local dev server because of some very strange react error |
20:18:31 | Tiberium | so I'll replace remove files from https://jscheid.github.io/nim-sandbox/index.html with my local ones :D |
20:18:31 | zachcarter | gotta love react :/ |
20:18:36 | zachcarter | :D |
20:19:52 | Tiberium | I hope it will be successfull |
20:27:29 | libman | JS sandbox doesn't support `import`... |
20:28:56 | Tiberium | this is two years old sandbox btw |
20:29:08 | Tiberium | I think with enough work we can port current compiler to emscripten :) |
20:31:44 | * | Vladar quit (Quit: Leaving) |
20:32:38 | Tiberium | zachcarter, it works |
20:32:50 | zachcarter | nice! |
20:33:02 | Tiberium | zachcarter, but it's made without any modules |
20:33:08 | Tiberium | (In build config as I think) |
20:33:31 | dom96 | It would still be nice to have a C-backed playground site. |
20:33:44 | Tiberium | yeah, it would be better anyway |
20:33:46 | Tiberium | but woah - http://imgur.com/a/wjX4o |
20:34:29 | * | sz0 quit (Quit: Connection closed for inactivity) |
20:37:28 | Tiberium | wait, resulting code for echo "Hello Nim " & $NimVersion is only 400 lines of JS |
20:37:32 | Tiberium | how is this possible? |
20:40:28 | Tiberium | dom96, wow :) http://dom96.github.io/ |
20:40:59 | dom96 | heh, that's at least 5 years old |
20:41:15 | * | Arrrr quit (Quit: Leaving.) |
20:41:44 | dom96 | how did you find it? |
20:41:46 | Tiberium | dom96, 6 years |
20:41:58 | Tiberium | dom96, https://github.com/search?utf8=%E2%9C%93&q=dom96&type= |
20:42:51 | dom96 | hah, I wonder if Haskell has a better IRC library nowadays |
20:47:40 | * | Tiberium quit (Read error: Connection reset by peer) |
20:50:04 | zachcarter | wewt |
20:50:13 | zachcarter | got a automated windows build of space invaders working : https://drive.google.com/file/d/0B2CfYyfxKriOUVBKWTdrbGh5cmM/view?usp=sharing |
20:50:21 | zachcarter | need 64 bits |
20:51:39 | * | Matthias247 joined #nim |
20:53:16 | * | DebugDude12 quit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client) |
20:55:37 | * | Tiberium joined #nim |
20:59:29 | zachcarter | hmmm |
20:59:57 | FromGitter | <stisa> zachcarter : ``could not load: OpenAL32.dll``, but it's in the folder? I guess I need to install it |
20:59:57 | zachcarter | getWMInfo which calls SDL_GetWindowWMInfo returns SysWM_Unknown when the release flag is set on the compiler |
21:00:17 | zachcarter | crap, I guess so I was hoping to avoid that |
21:00:36 | zachcarter | I’ll have to figure out how to fix that stisa |
21:04:22 | FromGitter | <stisa> zachcarter : works after installing openal |
21:04:27 | zachcarter | sweet! |
21:04:38 | zachcarter | thanks for trying it out |
21:05:49 | zachcarter | stisa: was it slow loading? |
21:05:53 | FromGitter | <stisa> Pretty nice! Is there a way to quit to menu ? Even after winning/losing it just continues running |
21:06:09 | zachcarter | you just have to exit the appliation |
21:06:14 | zachcarter | I haven’t finished the game yet |
21:06:26 | zachcarter | and thank you! |
21:06:29 | FromGitter | <stisa> Yes actually, a couple seconds of blank screen on starttup, and a couple seconds to load the level |
21:06:42 | zachcarter | okay I have a feeling this is due to the debug flag |
21:07:06 | zachcarter | hrm I need to figure out why the release flag makes the sdl2 bindings behave this way |
21:10:47 | zachcarter | this is going to be difficult to debug to since I need to set the release flag to reproduce it :/ |
21:15:22 | zachcarter | Araq: any idea what I can do here? |
21:23:00 | * | PMunch joined #nim |
21:25:14 | * | devted joined #nim |
21:27:42 | * | vivus quit (Quit: Leaving) |
21:29:02 | dom96 | zachcarter: one thing you can look for is assert calls |
21:29:07 | dom96 | remember, they disappear in release mode. |
21:39:36 | zachcarter | ahh okay thanks dom96 that’s probably it |
21:39:47 | zachcarter | in fact that is it |
21:43:35 | dom96 | cool :) |
21:43:36 | dom96 | 'night |
21:54:43 | PMunch | Anyone knows what's up with the graph for Karax: https://github.com/pragmagic/karax |
21:55:17 | zachcarter | good night |
21:55:50 | zachcarter | I think Araq explained it in the forum |
21:55:54 | zachcarter | forum thread* |
21:58:19 | PMunch | https://forum.nim-lang.org/t/2926 |
21:58:21 | PMunch | That one? |
21:58:35 | zachcarter | mmhmm |
21:58:50 | PMunch | I get what it's showing. But what is the teal vs. pink bars? |
21:59:41 | * | McSoFake quit (Ping timeout: 260 seconds) |
22:00:42 | FromGitter | <stisa> This morning he wrote > "Pink" == optimized version < , don't know what he means by optimized |
22:01:07 | PMunch | Ah, interesting |
22:01:14 | PMunch | Should say so in the graph though :P |
22:07:50 | * | McSoFake joined #nim |
22:24:05 | * | bjz joined #nim |
22:28:51 | zachcarter | threading seems super slow on windows |
22:28:55 | zachcarter | or I”m doing something very wrong |
22:33:48 | PMunch | Define slow |
22:35:01 | zachcarter | I think it’s something I”m doing |
22:35:26 | zachcarter | because other code using the same threading logic is executing very quickly |
22:35:52 | zachcarter | ah I figured it out |
22:36:09 | zachcarter | I think it has to do maybe with this sound library I’m using |
22:37:06 | * | vlad1777d quit (Quit: Leaving) |
22:38:47 | zachcarter | yup! |
22:38:53 | zachcarter | took out the sound loading and it’s very quick on windows |
22:38:55 | zachcarter | hrm that’s troubling |
22:48:02 | * | nsf quit (Quit: WeeChat 1.7) |
22:50:44 | * | McSoFake quit (Quit: leaving) |
22:56:55 | zachcarter | does anyone have a link to the nimble package scanner |
22:57:16 | zachcarter | err search rather |
22:57:17 | zachcarter | sorry |
22:57:45 | zachcarter | oh it’s on the homepage now nevermind |
23:00:03 | PMunch | Looking for a new sound engine? :P |
23:00:41 | zachcarter | well I’m definitely looking for options haha |
23:01:50 | zachcarter | I’d like to keep using sound.nim or whatever but it’s literally taking like 5+ seconds to load a single ogg file on windows |
23:02:06 | PMunch | Well that's no good.. |
23:02:42 | zachcarter | nope |
23:03:14 | * | Tiberium quit (Remote host closed the connection) |
23:13:14 | * | Ven joined #nim |
23:13:25 | * | Ven quit (Client Quit) |