01:25:00 | * | EXetoC quit (Read error: No route to host) |
01:34:49 | * | Associat0r quit (Read error: Connection reset by peer) |
01:44:55 | * | Associat0r joined #nimrod |
01:44:55 | * | Associat0r quit (Changing host) |
01:44:55 | * | Associat0r joined #nimrod |
02:30:42 | * | q66 quit (Quit: Leaving) |
02:34:28 | * | Associ8or joined #nimrod |
02:34:32 | * | Associ8or quit (Changing host) |
02:34:32 | * | Associ8or joined #nimrod |
02:36:31 | * | Associat0r quit (Ping timeout: 264 seconds) |
02:59:01 | * | OrionPK quit (Quit: Leaving) |
05:23:46 | * | Associ8or quit (Quit: Associ8or) |
06:02:16 | * | brson quit (Quit: leaving) |
06:36:06 | * | MFlamer_ joined #nimrod |
07:09:48 | * | shodan45 joined #nimrod |
07:12:55 | * | MFlamer_ quit (Ping timeout: 250 seconds) |
08:44:50 | * | Associat0r joined #nimrod |
09:18:15 | * | Associ8or joined #nimrod |
09:18:15 | * | Associ8or quit (Changing host) |
09:18:15 | * | Associ8or joined #nimrod |
09:20:18 | * | Associat0r quit (Ping timeout: 264 seconds) |
10:22:02 | * | io2 joined #nimrod |
10:33:37 | * | q66 joined #nimrod |
12:21:48 | * | io2 quit () |
12:54:11 | * | shafire joined #nimrod |
12:54:13 | shafire | hi |
12:54:17 | Araq | ho |
12:56:42 | shafire | how are you today? |
12:56:56 | Araq | busy |
13:00:40 | shafire | "As of version 0.8.5 the compiler is maintained in Nimrod. (The first versions have been implemented in Object Pascal.)" |
13:00:45 | shafire | Where there other languages too? |
13:01:22 | Araq | the first version*s* |
13:01:39 | Araq | the build system used to be in python |
13:01:48 | Araq | no other languages have been used |
13:01:59 | * | JStoker quit (Ping timeout: 246 seconds) |
13:03:26 | * | JStoker joined #nimrod |
13:04:04 | Araq | first I used the boehm GC but that kept crashing so that the pascal version simply leaked instead |
13:09:18 | shafire | ah okay |
13:11:10 | shafire | will be right back |
13:11:25 | * | shafire quit (Quit: Page closed) |
13:40:47 | * | shafire joined #nimrod |
13:41:01 | shafire | hi |
14:21:25 | Araq | ho |
14:55:06 | * | OrionPK joined #nimrod |
15:03:00 | * | ltbarcly quit (Ping timeout: 260 seconds) |
15:36:15 | * | guaqua` joined #nimrod |
15:36:59 | * | guaqua` is now known as guaqua |
15:59:00 | * | Associ8or quit (Quit: Associ8or) |
16:29:14 | Araq | hi guaqua, welcome |
16:44:28 | shafire | Araq: |
16:44:40 | shafire | why are there the {. .} statements? |
16:44:53 | shafire | Why do I need to say, that I am using a {. closure .}? |
16:45:44 | Araq | I wanted to support a mode that supports the common {} instead of indentation |
16:46:06 | Araq | also a mode that uses "end if" etc., hence "end" is a keyword |
16:50:17 | shafire | Araq: so the {} mode will come? |
16:50:41 | Araq | if somebody implements it |
16:51:07 | shafire | I don't know, if it is a good idea |
16:51:38 | shafire | Then, I have 3 options to choose |
16:52:20 | shafire | indentation, {}, (begin)?/end |
16:58:56 | shafire | See you tomorrow |
16:59:52 | Araq | no |
16:59:59 | Araq | you don't have to choose |
17:00:19 | Araq | you should use indentation based syntax because the alternatives suck |
17:00:49 | guaqua | using indentation saves you from extra syntax |
17:00:54 | guaqua | one should do indentation anyway |
17:01:58 | shafire | yeah |
17:02:09 | Araq | yeah but actually imo the tool should render the AST as you prefer it |
17:02:36 | Araq | I am tired of ascii text based tooling |
17:03:16 | Araq | so the idea was to support all 3 and this ensures a painless interoperability |
17:03:41 | Araq | which is also the reason for nimrod's style insensitivity btw |
17:05:19 | shafire | Ok, thanks for the explanation |
17:06:59 | * | shafire quit (Quit: Page closed) |
20:18:07 | * | Associat0r joined #nimrod |
20:18:07 | * | Associat0r quit (Changing host) |
20:18:07 | * | Associat0r joined #nimrod |
20:53:29 | * | BitPuffin joined #nimrod |
21:30:44 | BitPuffin | Araq: Binding bullet physics could be a cool (and useful) way to test out c++2nim |
21:30:57 | Araq | so do it |
21:31:23 | BitPuffin | Well, maybe |
21:31:55 | BitPuffin | I am not sure I would start using C++ libraries until modules can be separated into C and C++ stuff |
21:32:12 | BitPuffin | So that using a C++ libraries doesn't go all GPL on my code and forcing all of it to compile to C |
21:32:15 | BitPuffin | ++ |
21:32:29 | BitPuffin | Since the compiling to C++ is less mature right? |
21:33:39 | * | ltbarcly joined #nimrod |
21:33:55 | BitPuffin | Araq: do you get where I am coming from? :) |
21:41:02 | * | ltbarcly quit (Ping timeout: 264 seconds) |
21:42:48 | * | ltbarcly joined #nimrod |
21:49:47 | * | ltbarcly quit (Ping timeout: 260 seconds) |
21:49:53 | Araq | well bootrapping with c++ works |
21:50:08 | BitPuffin | It does? |
21:50:13 | BitPuffin | That's good |
21:50:21 | Araq | worked for me the last time I tried |
21:50:24 | BitPuffin | But how do we know it doesn't have a lot of hidden bugs |
21:50:57 | * | ltbarcly joined #nimrod |
21:53:50 | BitPuffin | Well |
21:53:59 | BitPuffin | isn't there a huge potential for regressions Araq? |
21:55:26 | * | ltbarcly quit (Ping timeout: 245 seconds) |
21:56:00 | Araq | when isn't? |
21:56:39 | BitPuffin | Well |
21:56:43 | BitPuffin | I mean compared to the C generator |
21:56:53 | BitPuffin | since that's what's been exposed the most |
21:56:57 | BitPuffin | slash tested |
21:57:04 | * | ltbarcly joined #nimrod |
22:02:16 | * | ltbarcly quit (Ping timeout: 264 seconds) |
22:04:14 | * | ltbarcly joined #nimrod |
22:08:45 | * | ltbarcly quit (Ping timeout: 245 seconds) |
22:10:38 | Araq | BitPuffin: the real problem is that some modules might not be compatible with c++ due to c++'s stricter type checking |
22:10:53 | Araq | I don't think you'll get any new crashes or runtime or something |
22:11:10 | Araq | when it compiles as C++ it works as C in my experience |
22:11:11 | BitPuffin | Araq: you mean in the stdlib? |
22:11:19 | * | ltbarcly joined #nimrod |
22:11:22 | Araq | yes |
22:11:23 | BitPuffin | hmm well then maybe it is worth doing |
22:11:34 | BitPuffin | still the isolation would definitely be nice to have |
22:12:08 | Araq | the isolation is like 5 lines in the compiler but I don't want to touch it until my talk is over :P |
22:12:30 | BitPuffin | although on the other hand I haven't kept up with the development of newton. Maybe that's gotten better these days |
22:12:34 | BitPuffin | Araq: Your talk? :) |
22:13:22 | Araq | yeah |
22:14:13 | BitPuffin | when are you doing a talk? |
22:14:32 | BitPuffin | tell me more this is exciting :) |
22:15:51 | * | ltbarcly quit (Ping timeout: 245 seconds) |
22:16:40 | Araq | https://thestrangeloop.com/preconf |
22:18:29 | BitPuffin | lol |
22:18:32 | BitPuffin | the J programming language |
22:20:23 | BitPuffin | Araq: Haha I thought the Clayton Bauman talk was nimrod related first :) |
22:20:52 | Araq | yeah. right. |
22:21:16 | BitPuffin | Araq: where is this conference? |
22:21:28 | BitPuffin | will it be recorded? |
22:22:01 | Araq | for the 1000th time |
22:22:06 | Araq | yes it will be recorded |
22:22:12 | BitPuffin | Yaaaaaaaaaaaaaaay! |
22:22:22 | Araq | and even if not, I can put the slides online myself |
22:22:32 | Araq | and have lots of notes written down to the slides |
22:22:34 | BitPuffin | yes but the important thing is that we hear you talk |
22:22:40 | BitPuffin | :D |
22:22:44 | Araq | :-/ |
22:22:58 | BitPuffin | because then we can finally imagine your voice as we talk to you in irc |
22:23:26 | Araq | you could skype :P |
22:23:38 | BitPuffin | I suppose :) |
22:23:50 | BitPuffin | although first I have to fix my linux audio haha |
22:24:27 | Araq | but then you would know that I'm a single person and not a team of people :P |
22:24:47 | BitPuffin | haha |
22:24:51 | Araq | though I guess people only ever suspect Mike Pall is a team |
22:24:56 | BitPuffin | well, that never crossed my mind |
22:25:04 | Araq | yeah too bad |
22:25:13 | Araq | means I'm not productive enough :P |
22:25:34 | BitPuffin | but now you have me suspcious! |
22:25:44 | BitPuffin | hehe :) |
22:25:47 | BitPuffin | Well |
22:25:58 | BitPuffin | not only that you also have zahary to do some of your bidding :P |
22:27:17 | BitPuffin | I don't think anyone suspects that I am more than one person |
22:27:21 | BitPuffin | but I am gonna change that! |
22:27:24 | BitPuffin | it is my goal! |
22:28:13 | Araq | yeah well |
22:28:16 | Araq | I need to sleep now |
22:28:23 | BitPuffin | you do look very zen in that picture though Araq. It is like you are writing 1337 loc/s |
22:28:29 | BitPuffin | in your mind |
22:28:46 | BitPuffin | sleep well! |
22:28:56 | BitPuffin | if you can |
22:29:08 | Araq | well I do write lots of code sometimes |
22:29:14 | Araq | and never read it |
22:29:27 | BitPuffin | in your mind? |
22:29:32 | Araq | so the argument "code is read way more often than written" is false |
22:29:34 | BitPuffin | or for real |
22:29:53 | Araq | nobody *reads* thousands of lines of code |
22:29:54 | BitPuffin | Yeah I tend to write code more often than I read my own code |
22:29:59 | BitPuffin | I only read it when I change it |
22:30:03 | Araq | yep |
22:30:12 | Araq | it's only a concern if it doesn't work :P |
22:30:18 | Araq | anyway, good night |
22:30:27 | BitPuffin | but it is important to be able to read it when you will change it |
22:30:29 | BitPuffin | hehe |
22:30:31 | BitPuffin | night! |
22:49:47 | * | zahary quit (Quit: ~ Trillian Astra - www.trillian.im ~) |
22:51:50 | BitPuffin | #ifndef dLong |
22:51:52 | BitPuffin | #define dLong long long |
22:51:54 | BitPuffin | #endif |
22:51:56 | BitPuffin | too hard for c2nim to handle |
22:52:30 | BitPuffin | (52, 0) Error: identifier expected, but found '[NewLine] |
23:17:45 | Araq | BitPuffin: use #def instead of #define tehn |
23:18:29 | BitPuffin | Araq: shouldn't you be sleeping :) |
23:18:36 | BitPuffin | Thanks though I will try! |
23:19:25 | Araq | I can't sleep |
23:19:41 | BitPuffin | should all #define be #def Araq ? |
23:19:57 | Araq | you should read c2nim's documentation |
23:20:21 | Araq | it's sparse for a reason :P |
23:20:50 | Araq | the idea of the sparse docs is that people might read it this way ... |
23:20:58 | BitPuffin | http://nimrod-code.org/c2nim.html ? |
23:21:37 | Araq | yeh |
23:22:14 | BitPuffin | it seems like it should be able to handle define right there? |
23:22:43 | Araq | I don't think so |
23:22:55 | Araq | it's a type not a constant or template |
23:23:09 | Araq | c2nim wants to translate #define into const or template |
23:23:15 | BitPuffin | ah |
23:23:22 | BitPuffin | but where does this mention def? |
23:23:41 | BitPuffin | here we go |
23:24:21 | BitPuffin | so in other words pretty much any define can be a def? |
23:24:41 | Araq | yeah |
23:24:56 | Araq | unless you want to translate it :P |
23:25:32 | Araq | well anyway coming up with heurstics when it should handle it as a #def or a #define is a planned feature |
23:27:03 | BitPuffin | that would be nice |
23:27:05 | BitPuffin | hmm |
23:27:22 | BitPuffin | #else |
23:27:24 | BitPuffin | #def NEWTON_API |
23:27:25 | BitPuffin | #endif |
23:27:28 | BitPuffin | why does it whine about that |
23:27:40 | BitPuffin | same whine as before |
23:28:12 | BitPuffin | ah |
23:28:16 | BitPuffin | it wants it to have a type |
23:28:25 | BitPuffin | Will define work here Araq ? |
23:28:58 | Araq | nope #def looks correct |
23:28:58 | BitPuffin | nope |
23:29:04 | Araq | no idea why it does complain |
23:29:47 | BitPuffin | are there any known issues with nested ifdefs? |
23:30:35 | Araq | yeah well |
23:30:58 | Araq | c2nim needs to process these in a special way too |
23:31:47 | BitPuffin | I don't even know if this stuff is needed |
23:31:59 | BitPuffin | Basically it defines NEWTON_API |
23:32:08 | BitPuffin | which is like dllexport stuff |
23:33:02 | BitPuffin | Which basically means that these functions that use the NEWTON_API thingy in C before the function type (I don't know what it is called) Should use the importc pragma |
23:33:19 | BitPuffin | and perhaps dyimport etc if you want that |
23:35:02 | BitPuffin | So basically it handles weather the code is used as a static library or if it is a dynamic one |
23:36:56 | Araq | just do: |
23:37:09 | Araq | #def NEWTON_AP __declspec(dllimport) |
23:37:23 | Araq | and don't nest it in an #if(def) |
23:37:30 | Araq | this should work |
23:37:36 | BitPuffin | Araq: But what if it is a static lib? |
23:38:22 | Araq | --dynlibOverride, user defined pragma etc etc |
23:39:10 | BitPuffin | Now I am having trouble with an anonymous union |
23:39:11 | BitPuffin | or whatever it is |
23:39:18 | BitPuffin | it's a union { stuff } |
23:39:23 | BitPuffin | without an identifier |
23:41:48 | Araq | that's not C89 I think |
23:42:15 | BitPuffin | I don't have any idea |
23:42:19 | BitPuffin | but how should I deal with it? |
23:42:25 | BitPuffin | I can't think of anything |
23:42:54 | Araq | union { stuff } u; ? |
23:43:02 | BitPuffin | ah |
23:43:05 | Araq | or even better get rid of the union |
23:43:05 | BitPuffin | so that won't break the api? |
23:43:23 | BitPuffin | why would it even have the union |
23:43:25 | BitPuffin | I cannot grasp |
23:43:31 | Araq | and pick the most important field of the greatest size |
23:43:47 | BitPuffin | http://pastebin.com/7sbBnYwV |
23:48:45 | Araq | that's a nice union you got there |
23:49:16 | BitPuffin | the union is my friend |
23:49:56 | Araq | I especially appreciate the 'm_' and 'Newton' prefixes |
23:50:28 | BitPuffin | lol :) |
23:50:28 | BitPuffin | typical C though |
23:51:03 | BitPuffin | We can have prefixes stripped remember so that it is TBoxParam etc |
23:51:25 | BitPuffin | but I guess for that to be 100% nice we still need renamed imports hehe |
23:51:43 | BitPuffin | until then we are kind of stuck with the C way of prefixing it with library specific stuff |
23:51:46 | Araq | well the real question is why C has prefixes even though it is case sensitive :P |
23:52:04 | Araq | but I digress |
23:52:34 | Araq | well you should wrap the dFloat ... [64]; part of the union I think |
23:53:20 | Araq | with a bit of luck that's the maximum size of all the union's fields |
23:55:55 | BitPuffin | Araq: it depends on a __USE_DOUBLE_PRECISION__ constant |
23:56:13 | BitPuffin | or wait |
23:56:16 | BitPuffin | what do you mean wrap? |
23:56:27 | Araq | edit the C code |
23:56:37 | BitPuffin | Yes but how do you mean |
23:56:39 | Araq | and get rid of the union |
23:56:47 | Araq | and instead have |
23:57:07 | Araq | dFloat ... [64]; in the struct |
23:58:10 | BitPuffin | but what about the other stuff? |
23:58:30 | Araq | chances are you don't need to access it directly |
23:58:48 | Araq | and if you do you can provide accessor procs that 'cast' to the proper type |
23:59:41 | Araq | cast[ptr ProperType](addr(thestruct.dFloat)) |