<< 15-09-2013 >>

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:13shafirehi
12:54:17Araqho
12:56:42shafirehow are you today?
12:56:56Araqbusy
13:00:40shafire"As of version 0.8.5 the compiler is maintained in Nimrod. (The first versions have been implemented in Object Pascal.)"
13:00:45shafireWhere there other languages too?
13:01:22Araqthe first version*s*
13:01:39Araqthe build system used to be in python
13:01:48Araqno other languages have been used
13:01:59*JStoker quit (Ping timeout: 246 seconds)
13:03:26*JStoker joined #nimrod
13:04:04Araqfirst I used the boehm GC but that kept crashing so that the pascal version simply leaked instead
13:09:18shafireah okay
13:11:10shafirewill be right back
13:11:25*shafire quit (Quit: Page closed)
13:40:47*shafire joined #nimrod
13:41:01shafirehi
14:21:25Araqho
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:14Araqhi guaqua, welcome
16:44:28shafireAraq:
16:44:40shafirewhy are there the {. .} statements?
16:44:53shafireWhy do I need to say, that I am using a {. closure .}?
16:45:44AraqI wanted to support a mode that supports the common {} instead of indentation
16:46:06Araqalso a mode that uses "end if" etc., hence "end" is a keyword
16:50:17shafireAraq: so the {} mode will come?
16:50:41Araqif somebody implements it
16:51:07shafireI don't know, if it is a good idea
16:51:38shafireThen, I have 3 options to choose
16:52:20shafireindentation, {}, (begin)?/end
16:58:56shafireSee you tomorrow
16:59:52Araqno
16:59:59Araqyou don't have to choose
17:00:19Araqyou should use indentation based syntax because the alternatives suck
17:00:49guaquausing indentation saves you from extra syntax
17:00:54guaquaone should do indentation anyway
17:01:58shafireyeah
17:02:09Araqyeah but actually imo the tool should render the AST as you prefer it
17:02:36AraqI am tired of ascii text based tooling
17:03:16Araqso the idea was to support all 3 and this ensures a painless interoperability
17:03:41Araqwhich is also the reason for nimrod's style insensitivity btw
17:05:19shafireOk, 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:44BitPuffinAraq: Binding bullet physics could be a cool (and useful) way to test out c++2nim
21:30:57Araqso do it
21:31:23BitPuffinWell, maybe
21:31:55BitPuffinI am not sure I would start using C++ libraries until modules can be separated into C and C++ stuff
21:32:12BitPuffinSo that using a C++ libraries doesn't go all GPL on my code and forcing all of it to compile to C
21:32:15BitPuffin++
21:32:29BitPuffinSince the compiling to C++ is less mature right?
21:33:39*ltbarcly joined #nimrod
21:33:55BitPuffinAraq: 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:53Araqwell bootrapping with c++ works
21:50:08BitPuffinIt does?
21:50:13BitPuffinThat's good
21:50:21Araqworked for me the last time I tried
21:50:24BitPuffinBut how do we know it doesn't have a lot of hidden bugs
21:50:57*ltbarcly joined #nimrod
21:53:50BitPuffinWell
21:53:59BitPuffinisn't there a huge potential for regressions Araq?
21:55:26*ltbarcly quit (Ping timeout: 245 seconds)
21:56:00Araqwhen isn't?
21:56:39BitPuffinWell
21:56:43BitPuffinI mean compared to the C generator
21:56:53BitPuffinsince that's what's been exposed the most
21:56:57BitPuffinslash 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:38AraqBitPuffin: the real problem is that some modules might not be compatible with c++ due to c++'s stricter type checking
22:10:53AraqI don't think you'll get any new crashes or runtime or something
22:11:10Araqwhen it compiles as C++ it works as C in my experience
22:11:11BitPuffinAraq: you mean in the stdlib?
22:11:19*ltbarcly joined #nimrod
22:11:22Araqyes
22:11:23BitPuffinhmm well then maybe it is worth doing
22:11:34BitPuffinstill the isolation would definitely be nice to have
22:12:08Araqthe isolation is like 5 lines in the compiler but I don't want to touch it until my talk is over :P
22:12:30BitPuffinalthough on the other hand I haven't kept up with the development of newton. Maybe that's gotten better these days
22:12:34BitPuffinAraq: Your talk? :)
22:13:22Araqyeah
22:14:13BitPuffinwhen are you doing a talk?
22:14:32BitPuffintell me more this is exciting :)
22:15:51*ltbarcly quit (Ping timeout: 245 seconds)
22:16:40Araqhttps://thestrangeloop.com/preconf
22:18:29BitPuffinlol
22:18:32BitPuffinthe J programming language
22:20:23BitPuffinAraq: Haha I thought the Clayton Bauman talk was nimrod related first :)
22:20:52Araqyeah. right.
22:21:16BitPuffinAraq: where is this conference?
22:21:28BitPuffinwill it be recorded?
22:22:01Araqfor the 1000th time
22:22:06Araqyes it will be recorded
22:22:12BitPuffinYaaaaaaaaaaaaaaay!
22:22:22Araqand even if not, I can put the slides online myself
22:22:32Araqand have lots of notes written down to the slides
22:22:34BitPuffinyes but the important thing is that we hear you talk
22:22:40BitPuffin:D
22:22:44Araq:-/
22:22:58BitPuffinbecause then we can finally imagine your voice as we talk to you in irc
22:23:26Araqyou could skype :P
22:23:38BitPuffinI suppose :)
22:23:50BitPuffinalthough first I have to fix my linux audio haha
22:24:27Araqbut then you would know that I'm a single person and not a team of people :P
22:24:47BitPuffinhaha
22:24:51Araqthough I guess people only ever suspect Mike Pall is a team
22:24:56BitPuffinwell, that never crossed my mind
22:25:04Araqyeah too bad
22:25:13Araqmeans I'm not productive enough :P
22:25:34BitPuffinbut now you have me suspcious!
22:25:44BitPuffinhehe :)
22:25:47BitPuffinWell
22:25:58BitPuffinnot only that you also have zahary to do some of your bidding :P
22:27:17BitPuffinI don't think anyone suspects that I am more than one person
22:27:21BitPuffinbut I am gonna change that!
22:27:24BitPuffinit is my goal!
22:28:13Araqyeah well
22:28:16AraqI need to sleep now
22:28:23BitPuffinyou do look very zen in that picture though Araq. It is like you are writing 1337 loc/s
22:28:29BitPuffinin your mind
22:28:46BitPuffinsleep well!
22:28:56BitPuffinif you can
22:29:08Araqwell I do write lots of code sometimes
22:29:14Araqand never read it
22:29:27BitPuffinin your mind?
22:29:32Araqso the argument "code is read way more often than written" is false
22:29:34BitPuffinor for real
22:29:53Araqnobody *reads* thousands of lines of code
22:29:54BitPuffinYeah I tend to write code more often than I read my own code
22:29:59BitPuffinI only read it when I change it
22:30:03Araqyep
22:30:12Araqit's only a concern if it doesn't work :P
22:30:18Araqanyway, good night
22:30:27BitPuffinbut it is important to be able to read it when you will change it
22:30:29BitPuffinhehe
22:30:31BitPuffinnight!
22:49:47*zahary quit (Quit: ~ Trillian Astra - www.trillian.im ~)
22:51:50BitPuffin#ifndef dLong
22:51:52BitPuffin #define dLong long long
22:51:54BitPuffin#endif
22:51:56BitPuffintoo hard for c2nim to handle
22:52:30BitPuffin(52, 0) Error: identifier expected, but found '[NewLine]
23:17:45AraqBitPuffin: use #def instead of #define tehn
23:18:29BitPuffinAraq: shouldn't you be sleeping :)
23:18:36BitPuffinThanks though I will try!
23:19:25AraqI can't sleep
23:19:41BitPuffinshould all #define be #def Araq ?
23:19:57Araqyou should read c2nim's documentation
23:20:21Araqit's sparse for a reason :P
23:20:50Araqthe idea of the sparse docs is that people might read it this way ...
23:20:58BitPuffinhttp://nimrod-code.org/c2nim.html ?
23:21:37Araqyeh
23:22:14BitPuffinit seems like it should be able to handle define right there?
23:22:43AraqI don't think so
23:22:55Araqit's a type not a constant or template
23:23:09Araqc2nim wants to translate #define into const or template
23:23:15BitPuffinah
23:23:22BitPuffinbut where does this mention def?
23:23:41BitPuffinhere we go
23:24:21BitPuffinso in other words pretty much any define can be a def?
23:24:41Araqyeah
23:24:56Araqunless you want to translate it :P
23:25:32Araqwell anyway coming up with heurstics when it should handle it as a #def or a #define is a planned feature
23:27:03BitPuffinthat would be nice
23:27:05BitPuffinhmm
23:27:22BitPuffin #else
23:27:24BitPuffin #def NEWTON_API
23:27:25BitPuffin #endif
23:27:28BitPuffinwhy does it whine about that
23:27:40BitPuffinsame whine as before
23:28:12BitPuffinah
23:28:16BitPuffinit wants it to have a type
23:28:25BitPuffinWill define work here Araq ?
23:28:58Araqnope #def looks correct
23:28:58BitPuffinnope
23:29:04Araqno idea why it does complain
23:29:47BitPuffinare there any known issues with nested ifdefs?
23:30:35Araqyeah well
23:30:58Araqc2nim needs to process these in a special way too
23:31:47BitPuffinI don't even know if this stuff is needed
23:31:59BitPuffinBasically it defines NEWTON_API
23:32:08BitPuffinwhich is like dllexport stuff
23:33:02BitPuffinWhich 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:19BitPuffinand perhaps dyimport etc if you want that
23:35:02BitPuffinSo basically it handles weather the code is used as a static library or if it is a dynamic one
23:36:56Araqjust do:
23:37:09Araq#def NEWTON_AP __declspec(dllimport)
23:37:23Araqand don't nest it in an #if(def)
23:37:30Araqthis should work
23:37:36BitPuffinAraq: But what if it is a static lib?
23:38:22Araq--dynlibOverride, user defined pragma etc etc
23:39:10BitPuffinNow I am having trouble with an anonymous union
23:39:11BitPuffinor whatever it is
23:39:18BitPuffinit's a union { stuff }
23:39:23BitPuffinwithout an identifier
23:41:48Araqthat's not C89 I think
23:42:15BitPuffinI don't have any idea
23:42:19BitPuffinbut how should I deal with it?
23:42:25BitPuffinI can't think of anything
23:42:54Araqunion { stuff } u; ?
23:43:02BitPuffinah
23:43:05Araqor even better get rid of the union
23:43:05BitPuffinso that won't break the api?
23:43:23BitPuffinwhy would it even have the union
23:43:25BitPuffinI cannot grasp
23:43:31Araqand pick the most important field of the greatest size
23:43:47BitPuffinhttp://pastebin.com/7sbBnYwV
23:48:45Araqthat's a nice union you got there
23:49:16BitPuffinthe union is my friend
23:49:56AraqI especially appreciate the 'm_' and 'Newton' prefixes
23:50:28BitPuffinlol :)
23:50:28BitPuffintypical C though
23:51:03BitPuffinWe can have prefixes stripped remember so that it is TBoxParam etc
23:51:25BitPuffinbut I guess for that to be 100% nice we still need renamed imports hehe
23:51:43BitPuffinuntil then we are kind of stuck with the C way of prefixing it with library specific stuff
23:51:46Araqwell the real question is why C has prefixes even though it is case sensitive :P
23:52:04Araqbut I digress
23:52:34Araqwell you should wrap the dFloat ... [64]; part of the union I think
23:53:20Araqwith a bit of luck that's the maximum size of all the union's fields
23:55:55BitPuffinAraq: it depends on a __USE_DOUBLE_PRECISION__ constant
23:56:13BitPuffinor wait
23:56:16BitPuffinwhat do you mean wrap?
23:56:27Araqedit the C code
23:56:37BitPuffinYes but how do you mean
23:56:39Araqand get rid of the union
23:56:47Araqand instead have
23:57:07AraqdFloat ... [64]; in the struct
23:58:10BitPuffinbut what about the other stuff?
23:58:30Araqchances are you don't need to access it directly
23:58:48Araqand if you do you can provide accessor procs that 'cast' to the proper type
23:59:41Araqcast[ptr ProperType](addr(thestruct.dFloat))