<< 21-07-2014 >>

00:02:26*io2 quit (Quit: ...take irc away, what are you? genius, billionaire, playboy, philanthropist)
00:21:41*def- quit (Ping timeout: 240 seconds)
00:22:43*def- joined #nimrod
00:34:50*saml_ quit (Quit: Leaving)
00:58:07*noam quit (Ping timeout: 245 seconds)
01:01:43*Matthias247 quit (Read error: Connection reset by peer)
01:16:21*johnsoft quit (Ping timeout: 256 seconds)
01:16:35*johnsoft joined #nimrod
01:30:35*q66 quit (Quit: Leaving)
01:45:12*Jessin quit (Ping timeout: 260 seconds)
01:51:00*Jesin joined #nimrod
01:59:27*Jesin quit (Ping timeout: 245 seconds)
02:02:23*Jesin joined #nimrod
02:13:47*Jesin quit (Ping timeout: 264 seconds)
02:23:11*goobles joined #nimrod
02:25:51*fowl joined #nimrod
02:26:59*springbok joined #nimrod
02:32:02*Jesin joined #nimrod
02:32:37*Jesin quit (Read error: Connection reset by peer)
02:39:48*johnsoft quit (Ping timeout: 260 seconds)
02:40:52*johnsoft joined #nimrod
02:45:54*kshlm joined #nimrod
02:48:25*brson quit (Quit: leaving)
03:32:41*adoniscik joined #nimrod
03:39:23*kshlm quit (Quit: Konversation terminated!)
03:55:23adoniscikis it possible to set the return type depending on the argument types? for example, if your arguments or int|float, to set it to int if all inputs are int and float otherwise?
03:59:53Skrylarproc foo[T](a, b: T): T
04:00:18SkrylarUse generics
04:00:21adoniscikwhat's T explicitly?
04:00:28SkrylarT is nothing, its a generic
04:00:36adoniscikso how does that solve my problem?
04:00:57Skrylarif a and b are int, the compiler will infer that T is int
04:01:02Skrylarthus int -> int -> int
04:01:09adoniscikgreat, what if at least one of them is not?
04:01:17SkrylarThen it will moan because they are not the same
04:01:28adoniscikI want it to work, nto moan :)
04:01:36SkrylarIIRC its generally considered poor practice to freely intermix float and int anyway
04:02:02adoniscikbut it's not free, I want to treat the all int case separately
04:02:36adoniscikif they're mixed, I will promote the ints to floats
04:02:55Skrylari don't recall if generics have specializations like in C++
04:03:14SkrylarI know we have term rewriting macros that do something like that, but its for something else
04:06:04Skrylarlooks like it *should* be doable with templates
04:06:06adoniscikinside the proc I can do when type(foo) etc. but not in the proc signature
04:06:45Skrylaradoniscik: for that you would do proc foo[T: int|float](...), which allows either
04:07:02Skrylarwhich would allow either all floats or all ints
04:07:04adoniscikhow about the return type? you can't do int|float there
04:07:19Skrylaralso make it T
04:07:23Skrylar(or 'auto')
04:07:35adoniscikbut that's not what's desired; I don't want to just have all floats or all ints but all ints vs. everything else
04:07:37adoniscikthere's a difference
04:08:03adoniscikall ints -> return int else return float
04:08:04Skrylarwell 'auto' will infer from whatever type you *actually* return
04:08:13adoniscikgreat let me try that
04:08:23adonisciksince I can use when inside the proc
04:08:34Skrylarotherwise you probably need a macro or an override
04:08:38Skrylarmacro/template
04:09:00Skrylaryou can also have multiple generic types
04:09:10Skrylarblah[J,K,L]
04:09:39adoniscikyes, but there's this: https://github.com/Araq/Nimrod/issues/1385
04:11:12*boydgreenfield joined #nimrod
04:12:10Skrylarwhat function are you specifically trying to implement?
04:13:04adoniscikbasic linear algebra
04:15:08SkrylarIIRC nimrod will eat division and always return a float, unless you do specific div/mod integer calculations with it; so i would probably still just do an all-int and all-float implementation as two procs
04:15:31adoniscikthanks, I'll consider that
04:15:40Skrylarits not ideal for the mixed case, but mixing int/float implicitly has caused a lot of subtle programming bugs
04:16:07Skrylarthe worst you'd have to do is 0.float or 0.0
04:26:12*mwbrown quit (Ping timeout: 260 seconds)
04:27:15*kshlm joined #nimrod
04:27:55*superfunc joined #nimrod
04:39:51*Demos quit (Read error: Connection reset by peer)
04:40:18gooblesnimrod iterators r weird or what
04:40:33Skrylargoobles: eh, compared to C# maybe
04:40:41Skrylarthey're pretty efficient in nimrod
04:41:23gooblesi am used to the C++ style, they do seem weird to me when I look at them
04:42:45gooblesis there a way to like chain/cmpose them
04:42:48Skrylari like 'for e in y' more than blah != blah.end_iterator() and such
04:43:07SkrylarNot really; an iterator in nimrod is basically just a while loop
04:43:11gooblesthats old C++
04:43:13Skrylarthey aren't objects
04:49:59*superfunc quit (Ping timeout: 256 seconds)
05:13:37*boydgreenfield quit (Quit: boydgreenfield)
05:22:47*flaviu quit (Ping timeout: 264 seconds)
05:24:49*boydgreenfield joined #nimrod
05:47:23*bjz joined #nimrod
05:56:51*adoniscik quit (Ping timeout: 256 seconds)
06:03:36*bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
06:03:55*bjz joined #nimrod
06:08:12*bjz quit (Ping timeout: 240 seconds)
07:02:15*ics quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
07:08:50*boydgreenfield quit (Quit: boydgreenfield)
07:20:54*kunev joined #nimrod
07:32:06*adoniscik joined #nimrod
07:45:49*kunev quit (Quit: Lost terminal)
07:51:46*kunev joined #nimrod
08:01:18*adoniscik quit (Quit: Leaving)
08:03:43*io2 joined #nimrod
08:06:12*Trustable joined #nimrod
08:29:50*ARCADIVS joined #nimrod
08:46:13*adoniscik joined #nimrod
08:52:23adoniscikHow does the auto type work for proc outputs, because I get a "cannot instantiate" error?
08:53:25def-adoniscik: sometimes the type can't be inferred, then you have to write it by hand
08:53:39def-but i don't remember seeint that error
08:54:24adoniscikthat's a bummer, because I was hoping to use it to be able to set the type depending on the arguments.
08:54:44def-you can still use generics and do that by hand
08:54:58adoniscikplease take a look: http://pastebin.com/akvjj6pF
08:56:07def-adoniscik: compiles for me with the devel branch
08:56:19adoniscikoh interesting
08:56:26adoniscikthat's encouraging.
08:57:32adoniscikcan you think of a cleaner way ?
08:59:17def-for the return type?
08:59:40adoniscikyes, primarily
09:00:09def-Oh wait
09:00:16def-It just compiles because I don't have code using it I think
09:00:42adonisciktry echo (2*[1,2,3]).repr
09:00:58def-Ok, getting your error now!
09:01:21adoniscikjoin the club :)
09:04:27def-This may be difficult since you only find the return type out in the proc body
09:04:46adoniscikno, you don't, you know as soon as you have the args
09:04:57def-and I guess it's not your goal to have a proc for each combination
09:05:11adoniscikI just couldn't figure out how to express it in proc signature
09:05:40def-adoniscik: neither can I
09:06:09adoniscikI'm closing to just giving ints the finger :)
09:06:25adoniscikmaybe I'll add 'em back when I better know the language
09:09:37def-also, there are many more number types than just int and float. Maybe it's easier/cleaner to use just 1 type for everything in your `*` proc
09:13:15adoniscikI need to come up with a numeric type policy. When the code is more mature, I'll post it for review
09:16:26*shevy left #nimrod ("I'll be back ... maybe")
09:17:09adoniscikapparently .5 is not a valid floating number?
09:19:36*gsingh93 quit (Quit: Connection closed for inactivity)
09:23:46def-adoniscik: indeed
09:36:44*BitPuffin joined #nimrod
09:48:03*BitPuffin quit (Ping timeout: 240 seconds)
09:49:57*BitPuffin joined #nimrod
10:11:42def-Oh wow. Using clang instead of gcc I get 50% smaller binaries, 4 times faster compilation and slightly faster execution
10:11:59def-(for some bigints test programs)
10:31:58*ARCADIVS quit (Quit: WeeChat 0.4.3)
10:40:21*adoniscik quit (Ping timeout: 250 seconds)
10:56:03*kshlm quit (Ping timeout: 256 seconds)
11:19:52*kshlm joined #nimrod
11:21:30*kshlm quit (Client Quit)
12:13:54*mwbrown joined #nimrod
12:18:14*darkf quit (Quit: Leaving)
12:20:59*Varriount_ joined #nimrod
12:24:12*Varriount quit (Ping timeout: 240 seconds)
12:30:07*darkfusion quit (Ping timeout: 256 seconds)
12:31:18*darkfusion joined #nimrod
12:33:53*untitaker quit (Ping timeout: 250 seconds)
12:39:38*untitaker joined #nimrod
12:43:25*mwbrown quit (Ping timeout: 250 seconds)
12:51:51*Jesin joined #nimrod
13:03:29*BitPuffin quit (Quit: See you on the dark side of the moon!)
13:06:58*BitPuffin joined #nimrod
13:43:14*saml joined #nimrod
14:01:30*askatasuna joined #nimrod
14:21:49*flaviu joined #nimrod
14:29:01*Machielo joined #nimrod
14:32:01*Machielo quit (Client Quit)
14:36:41*x2f0 joined #nimrod
14:37:36x2f0Hey everybody, thought I'd drop by and say "hi". New to nimrod, loving the language thus far
14:39:50*goobles quit (Quit: Page closed)
14:40:55*goobles joined #nimrod
14:51:28samlx2f0, how are you learning the langu?
14:52:56gooblesbanging head on keyboard
14:53:23samlcan i make web scale web site using nimrod
14:53:55x2f0going the euler road
14:54:49samlthat's great
14:55:24x2f0the C interface is fantastic, I needed some kind of bignums library (not sure if it exists already) for some of the problems on euler. Wrapping gmp was really easy
14:55:57def-x2f0: https://github.com/def-/bigints
14:56:28def-x2f0: i would be interested to know if the examples work with this too
14:56:54x2f0ah great, thanks for that. Didn't know that existed. Will test it out today evening
14:57:38def-x2f0: it's not in any list yet, because I need a lot of tests
15:00:03x2f0bookmarked for later
15:00:43gooblesso in nimrod shit is GC if u new it, otherwise it is stack allocated?
15:01:15x2f0Probably a bearded question (so apologies in advance), but are there any efforts to wrap something like wxwidgets?
15:02:17flyxx2f0: there's a GTK binding
15:02:44def-goobles: or you can alloc it on heap without GC
15:03:22flyxI don't think wxwidgets would be nice to use in nimrod, since it uses its own types for everything
15:03:33flyx(like most bloaty C++ libs)
15:03:56*io2 quit (Quit: ...take irc away, what are you? genius, billionaire, playboy, philanthropist)
15:04:52x2f0flyx: not a big fan of gtk tbh, but I see your point
15:05:22flyxx2f0: neither am I. I didn't yet find a GUI lib that's good enough for me to be a fan of
15:06:32x2f0flyx: everything considered, qt's not too bad. Not a true fan of that one either though...
15:09:01*kunev_ joined #nimrod
15:09:38flyxx2f0: qt has its merits. I didn't use it much and I didn't really like or dislike it
15:10:15flyxWPF is surprisingly pretty good, if you're developing Windows-only
15:10:37*kunev quit (Ping timeout: 245 seconds)
15:33:13*flaviu quit (Remote host closed the connection)
15:33:40*flaviu joined #nimrod
15:43:07x2f0flyx: never worked with wpf (not a win dev as such), but I can imagine that it is pretty decent actually. The crossplatform stuff is always a chore, to be expected I guess
15:50:14flyxx2f0: depends. GTK is cross-plattform throughout, which gives a more consistent look. Qt tries to emulate the platform's native look which looks weird sometimes. wx uses the native toolkit as backend which makes it very bloat. but WPF *could* be ported to other platforms if someone has the time to do it; it isn't using the native Windows APIs.
15:56:33x2f0flyx: in regards to osx, has GTK support improved at all? Had to rely on gtk some time ago (not sure exactly when, but not too far into the past) in one of my lisp tools. Bindings were fairly stable, etc. However, getting all of this up, packaging, etc. was a massive hassle. Ended up using qt in the end
15:57:21flyxx2f0: well you need to know your way around autotools. once you have built the quartz stack once, it's not too hard to bind and bundle
15:59:06flyxx2f0: or you can use the X11-based GTK, which is more stable and has packages provided through macports and find
15:59:08flyx*fink
16:00:35x2f0flyx: I did get it to run in the end, but it just felt somewhat wrong haha... But then again, I was prepared for all kinds of things to happen.
16:01:32*johnsoft quit (Ping timeout: 245 seconds)
16:02:00*johnsoft joined #nimrod
16:02:15x2f0flyx: in terms of distribution, isn't x11 gone (on newer macs). Sorry not to knowledgable in this area. Would need to rely on quartz in the end no?
16:03:21flyxx2f0: you can still download and install XQuartz. of course, it's very ugly
16:03:47flyxgtk-quartz is of course more natural
16:04:21flyxan since Mono/Xamarin is using it extensively, it got fairly usable
16:04:28x2f0flyx: noted down. While I'm playing around with nimrod might as well give it another try
16:05:02x2f0flyx: what I'd really love to see is something like openframeworks for nimrod
16:05:19flyxx2f0: never heard of that one
16:06:06x2f0flyx: C++ toolkit for generative art and such
16:06:14flyxah
16:06:30flyxwell you can write a nimrod binding for it
16:06:36x2f0flyx: I do this semi-professionally, would be great to use something besides C++
16:07:11flyxbut I don't know exactly how much C++ features can be tranparently wrapped with nimrod. never did C++ wrapping
16:07:54flyxI'm afk, showering. it's pretty hot here. later.
16:07:55x2f0flyx: honestly, I might just do that. Granted, my skills aren't all that, but I've got time
16:08:07x2f0np
16:08:14x2f0cheers
16:09:03def-x2f0: nice, good luck!
16:11:02x2f0def-: thanks. Def need to explore c2nim a slight bit more though haha
16:11:54def-x2f0: I don't understand it much myself. I just comment out until it works and write the rest by hand
16:12:19x2f0def-: that would be pretty much my approach I guess
16:25:02*Boscop quit (Read error: Connection reset by peer)
16:25:52*Boscop joined #nimrod
16:27:37*boydgreenfield joined #nimrod
16:36:03*darkfusion quit (Ping timeout: 240 seconds)
16:36:56*adoniscik joined #nimrod
16:44:07*darkfusion joined #nimrod
16:45:24*kunev_ quit (Ping timeout: 260 seconds)
16:51:02*x2f0 quit (Quit: Page closed)
17:06:54*ics joined #nimrod
17:08:40*brson joined #nimrod
17:10:42*leru joined #nimrod
17:10:43*rixx joined #nimrod
17:10:52*rixx quit (Client Quit)
17:11:06*rixx joined #nimrod
17:13:12*rixx left #nimrod (#nimrod)
17:13:21*boydgreenfield quit (Quit: boydgreenfield)
17:13:32*ics quit (Ping timeout: 245 seconds)
17:16:11*ics joined #nimrod
17:16:42*q66 joined #nimrod
17:18:54*boydgreenfield joined #nimrod
17:20:02gooblesany one write super duper meta nimrod?
17:23:03*kunev joined #nimrod
17:26:23def-goobles: hm?
17:26:23*Trixar_za quit (Ping timeout: 250 seconds)
17:27:09gooblesmeta programming like in C++ with boost etc
17:27:22gooblesi guess nimrod should be good at dis but I don't see many examples
17:27:59def-goobles: I tried to do some physical units in nimrod, but I didn't get far: https://github.com/def-/units/blob/master/units.nim
17:28:50*Trixar_za joined #nimrod
17:29:31gooblesoh not bad, you can make nimrod do: var v = 12.5.volt
17:30:18def-and volts!
17:30:29def-which is automatically defined as well
17:30:53def-and everything is typechecked at compile time and then at runtime you just have floats
17:31:15goobles# Compiler bug: Doesn't work with borrow
17:31:20gooblesdoes nimrod doing borrowing?
17:31:25goobleslike rust?
17:31:48def-I don't know about rust, but here: http://nimrod-lang.org/manual.html#distinct-type
17:31:52flaviugoobles: No, I think thats refering to something else
17:32:09def-"The borrow pragma makes the compiler use the same implementation as the proc that deals with the distinct type's base type, so no code is generated."
17:33:35gooblesdistinct type is something i wish C++ had
17:37:32adoniscikhow do you access the default value of a proc's arg?
17:37:42adoniscikI want to set a constant to it
17:37:59flaviuadoniscik: I'm not sure what you mean
17:38:01adoniscikis it possible without defining the constant outside the proc?
17:38:29adoniscikfoo: proc (x: T = val). How do you access val inside foo?
17:38:36def-adoniscik: don't think you can
17:38:46flaviuCan't you just access x?
17:38:52*kunev quit (Ping timeout: 240 seconds)
17:39:02flaviuIf nothing is passed in, x == val
17:39:12adoniscikyeah, so you don't get val otherwise
17:39:31adoniscikI want val in all instances; it's the "worst case"
17:39:41flaviuWell, the name of that construct is optional parameters
17:39:57adoniscikyeah, and I set its default value to the worst case
17:40:42*boydgreenfield quit (Quit: boydgreenfield)
17:42:15adoniscikx : int = (const MAXVAL : int = 1000) didn't work :|
17:43:51dom96const MAXVAL = 1000
17:43:59dom96proc foo(x: T = MAXVAL) ?
17:44:17*Matthias247 joined #nimrod
17:44:30adoniscikthat separates MAXVAL from foo but it's the only way I could find.
17:47:01adoniscikis there a list of common exceptions that we are encouraged to use or do we have to just define our own?
17:47:40flaviuadoniscik: tut2 has a list
17:48:04adoniscikflaviu, thanks. that's the one
17:51:15*io2 joined #nimrod
17:53:06*Demos joined #nimrod
17:54:49*darkfusion quit (Ping timeout: 256 seconds)
17:54:56*darkfusion joined #nimrod
17:55:25*kunev joined #nimrod
17:58:05*untitaker quit (Quit: ZNC - http://znc.in)
17:59:11*untitaker joined #nimrod
18:05:42*flaviu quit (Remote host closed the connection)
18:11:53*flaviu joined #nimrod
18:14:13*Johz joined #nimrod
18:24:34*mwbrown joined #nimrod
18:26:05*fran__ joined #nimrod
18:27:41*darkfusion quit (Ping timeout: 256 seconds)
18:28:49*Francisco quit (Ping timeout: 256 seconds)
18:30:41*y2f0 joined #nimrod
18:31:15Araqhi y2f0 welcome
18:31:36y2f0Araq: Hey there
18:32:07y2f0Araq: gotta say, I'm really quite impressed with nimrod so far!
18:32:33Araqthank you
18:33:36y2f0I just submitted a request on hackerrank.com to get nimrod up there as a supported language
18:34:09y2f0apparently it was added to the todo list. Hopefully this will give it some more exposure (once added that is)
18:34:16def-y2f0: awesome
18:35:34*Araq looks up hackerrank.com quietly
18:36:43Araqah cool stuff
18:37:50y2f0similar to the old spoj. They've got a bunch of smaller languages up there so I think they are pretty open to all kinds of things
18:38:49*Matthias247 quit (Read error: Connection reset by peer)
18:39:23*Matthias247 joined #nimrod
18:51:24*untitaker quit (Quit: ZNC - http://znc.in)
18:52:27*untitaker joined #nimrod
19:05:40gooblescan u do unique types in nimrod?
19:05:57flaviugoobles: I think distinct types do what you want
19:06:16goobleshum no i mean like an object that can only have 1 owner
19:06:26gooblesso doesn't need GC etc
19:07:05flaviuNo, nimrod does not have those
19:09:13Demosgoobles, you can use the stack
19:09:26Demosor use destructors to create something like c++'s unique_ptrs
19:10:44Demosgoobles, don't try and avoid the GC at all costs. Avoid lots of heap allocation but if you do need the heap then using the GC is usually just fine
19:10:49Demosnimrod's gc is really fast
19:12:04gooblesare there any performance tests showing how nimrod GC performs?
19:12:50flaviugoobles: Sure. Run your program with gc off and with gc on. You'll leak memory, but you'll also hopfully be able to see how much slower it makes things
19:13:47Demosthat is hardly a fair benchmark
19:14:05Demosalso note that for microbenchmarks the GC may just not bother to free anything
19:14:18flaviuYou can trigger it though
19:14:29Demosthat will not be represnetitive
19:15:16Araqin the benchmarks that I've seen the GC performs rather poor. But it kicks ass in real world applications.
19:15:44Araqmicro benchmarks suck and got worse with modern architectures
19:16:09*io2 quit (Quit: ...take irc away, what are you? genius, billionaire, playboy, philanthropist)
19:17:01Demoslets be honest here, GC being a perf problem is largely a myth. Dynamic memory can be a performence problem and many languages with GC encourage the use of dynamic memory
19:18:49adoniscikis it possible to pass types (without values) as args, e.g., foo(int) if its the type itself I'm interested in?
19:19:09flaviuproc foo(a: typedesc) I think should work
19:22:39adoniscikcan you tell me what's wrong with http://pastebin.com/MABCz63f
19:23:16adoniscikI get Error: cannot instantiate: 't:type'
19:23:48adoniscikwhen I don't pass t and "Error: cannot evaluate at compile time: n" when I do
19:24:02def-adoniscik: you can't pass back an array of a size you will only find out at runtime
19:24:25gooblesya i don't care about microbenchmarks, those would either make it super easy for GC(it never collects) or make it look slow if it uses lots of RC.. more interested in making sure GC never has long pauses
19:24:25adoniscikso I should use a sequence or what?
19:24:43def-adoniscik: generics would be better if you want an array and know the size at compiletime, otherwise a seq, yes
19:25:28adoniscikI know the size: it's one of the args
19:25:48def-adoniscik: but you can call arange(userInputHere)
19:25:56flaviuadoniscik: It has to be known at compile time, arrays aren't like in java
19:26:49adoniscikso generics are not a solution in my case?
19:27:22Demosgoobles, you are unlikely to get long pauses, esp since the gc is thread local. If they do become a problem you can activate the real-time GC and you can give it a deadline and even disable it and control when it runs yourself
19:27:30adoniscikflaviu, def- This is basic proc you see in many languages
19:27:55Demosand you will really find that you need to use heap allocation much less than in other languages
19:27:56def-adoniscik: then return a seq and it's basic in Nimrod too
19:28:08flaviuadoniscik: Fixed it for you: https://gist.github.com/344c3f6231e6afae361e
19:29:33Araqadoniscik: http://forum.nimrod-lang.org/t/499
19:29:45Araqyou can use alloca, but it's a bad idea
19:29:56adoniscikthanks, guys, I'll digest this
19:30:41mwbrownJust to confirm, c2nim and pas2nim are no longer part of the main git repo, correct?
19:31:02flaviuYes
19:31:06mwbrownok, good
19:31:17mwbrownI wanted to make sure of that before filing a bug report on this package that builds it from git
19:31:25mwbrownthe build process was erroring out because it couldn't find them
19:32:43*kunev quit (Ping timeout: 240 seconds)
19:32:47*Trustable quit (Quit: Leaving)
19:39:47*fran__ quit (Quit: Leaving)
19:40:04*Fr4n joined #nimrod
19:59:13*jh32 joined #nimrod
20:00:43adoniscikflaviu, how would you do that with a default T?
20:02:40flaviuhmm, I don't think its possible. Adding proc arange*(n: int): seq[float] = arange[float](n) makes the call ambigious
20:02:58*leru quit (Ping timeout: 246 seconds)
20:03:58*io2 joined #nimrod
20:04:06*io2 quit (Changing host)
20:04:06*io2 joined #nimrod
20:07:34adoniscikif T is a typedesc, why doesn't the conversion T(foo) work?
20:08:13gooblescause foo don't like T
20:08:57flaviugoobles: But it does. T is a float, foo is an int
20:09:04adoniscikit says "type expected", as if typedesc != type
20:09:36flaviuI'm not really sure what the problem is, maybe someone else knows
20:09:43Araqtypedesc suffers from a non existing spec
20:09:52adoniscikwas I able to explain it ?
20:10:00Araqit was hacked into the language ... :-/
20:10:14Araqso please make a bug report
20:10:53*jh32 quit (Remote host closed the connection)
20:10:56adoniscikvery simple example: var T: typedesc = int ; T(1.0)
20:11:09*jh32 joined #nimrod
20:11:32Araqwell
20:11:40AraqT is not 'int'
20:11:48Araqit's typedesc[int]
20:12:06Araqvar T = someType should not compile
20:12:19AraqI'll make this an error soon
20:12:50Araqthis "types as values" feature is a bizzare clusterfuck
20:13:28adoniscikyou recommend using strings or enums instead?
20:13:47flaviuOk, I got it to work!
20:13:57flaviuhttps://gist.github.com/7cce3d8775861351abe4
20:16:48adoniscikinteresting!
20:16:58goobleswooooooooozers
20:17:09gooblesidk what that does but good job
20:17:21dom96Well. We got rejected by Wikipedia again https://en.wikipedia.org/wiki/Draft:Nimrod_%28programming_language%29
20:17:26flaviuIt exploits type inference to get it to work
20:17:35dom96I'm too tired to even argue with them now
20:18:57Araqjust reddit it and create a shitstorm
20:19:32goobleswhy do they delete it?
20:19:33adonisciktitle it "nimrod fastest language in the world. true or false?"
20:20:14gooblesi have seen other mostly unknown languages on wikipedia
20:20:38y2f0pretty ridiculous...
20:20:50flaviugoobles: https://en.wikipedia.org/wiki/Wikipedia:Other_stuff_exists
20:21:06Araqflaviu: I'm considering to delete this other stuff
20:21:14*goobles quit (Quit: Page closed)
20:21:27*goobles joined #nimrod
20:22:43goobleshttp://en.wikipedia.org/wiki/Felix_(programming_language)
20:22:49Araqthis "other stuff exists" is a poor excuse to not have to 80% of wikipedia's content
20:23:02adoniscikflaviu, why can't you do T: typedesc = typedesc[int] or T:typedesc=int ?
20:23:26Araq*to not have to remove
20:23:31flaviuThat would just make you an ass, and it wouldn't be in good faith. it would also decrease the likeliness of the nimrod page ever being accepted even further
20:23:45dom96I think wikipedia's rules are "You need to be notable, unless you are friends with one of the editors"
20:24:04flaviudom96: Their main rule is https://en.wikipedia.org/wiki/Wikipedia:Assume_good_faith
20:24:42Araqflaviu: that's most ridiculous
20:24:46adoniscikno, what you need to do is find some credible source to write about nimrod
20:25:03adoniscikthey are complaining that you guys are writing about yourself ("primary" sources)
20:25:06Araqmy personal actions have nothing to do with wether nimrod is acceptable for wikipedia
20:25:06adoniscikthat's a big no no
20:25:26Araqadoniscik: well but it's wrong
20:25:34Araqwe have secondary sources
20:25:50Araqand besides this rule is stupid enough to begin with
20:26:00y2f0Was drdobbs not enough or?
20:26:12Araqso if random joe writes a wrong book about nimrod, that is a good source
20:26:23Araqand if I myself write a book about it, it doesn't count
20:26:36dom96Take a look at this article: https://en.wikipedia.org/wiki/D_programming_language
20:26:49dom96Do you guys see any non-primary non-self-published sources?
20:27:16dom96A lot of the references point to the D forum, the D website, or books written by Walter.
20:27:24dom96Perhaps a blog post is in order.
20:27:47Araqdom96: def- gave a talk about it
20:27:55dom96Araq: That's self-published
20:28:06Araqdom96: well the drdobbs article is not
20:28:12dom96Yeah, but it's primary.
20:28:19Araqthis is absurd
20:28:48y2f0Gogol would be proud...
20:28:50dom96Yep.
20:29:21adoniscikdon't worry about it, just work on the language. Wikipedia is not the only venue to publicize the language. they are a conservative bunch; they will react in due time
20:29:35Araqthey are not conservative at all
20:29:43AraqI'm sure Swift already is in Wikipedia
20:29:55Araqthey are however political
20:30:10adoniscikSwift is more notable than nimrod
20:30:13flaviuAraq: Swift is notable.
20:30:13*Ven joined #nimrod
20:30:21adonisciknimrod needs to gain notability
20:30:22Araqyeah ok
20:30:23flaviuEvery tech news source published an article on it
20:30:44dom96I don't see why D is notable but Nimrod isn't.
20:30:56gooblesD has been around longer
20:30:59dom96Swift is a bad example.
20:31:08Araq"notable" doesn't mean anything
20:31:10flaviudom96: Big companies use D in production
20:31:27Araqit means "worth to put onto Wikipedia"
20:31:29dom96goobles: My grandpa is 70 years old, does that make him notable?
20:31:42gooblesno but more people are aware of D
20:31:46Araqwhich is classical cyclic reasoning
20:31:47gooblesbecause its been around
20:31:59flaviuAll the crappy language articles seem to be from around 2005
20:32:13gooblesand it has Andrei pushing it, who is fairly well known in C++ world
20:32:33dom96ugh, fuck it. I don't care anymore.
20:32:46dom96adoniscik is right. Let's focus on the language instead.
20:32:59flaviudom96: That's the spirit!
20:33:03gooblesnimrod could get there eventually, language seems solid
20:33:07adoniscikyep, true me: I know WP well
20:33:10flaviuNo point in stressing over it, they'll add it eventually
20:33:18adoniscikthey will
20:33:27dom96However, I just remembered that the only reason I found out about Nimrod was because it was on WP at the time...
20:33:55*darkfusion joined #nimrod
20:34:47adoniscikI think I was on SO
20:34:47NimBotnimrod-code/packages master 345cf7e Julien Aubert [+0 ±1 -0]: add nim-sndfile to packages.json
20:34:47NimBotnimrod-code/packages master 2d744a9 Dominik Picheta [+0 ±1 -0]: Merge pull request #72 from julienaubert/master... 2 more lines
20:36:41*Hat_and_Cloak joined #nimrod
20:36:52*ics quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
20:36:54Araqhi Hat_and_Cloak welcome
20:37:08Hat_and_Cloakah thanks!
20:38:21gooblesi found nimrod on D forum i think
20:38:43gooblesD is lame though, stupid Java model
20:42:43*vbtt joined #nimrod
20:53:17*jh32 quit (Remote host closed the connection)
20:57:07*Fx00F joined #nimrod
20:57:35*Mat3 joined #nimrod
20:57:38Mat3hello
21:00:20Araqhi Mat3
21:00:32Mat3hi Araq
21:00:50Mat3bbl
21:00:54*Mat3 quit (Client Quit)
21:09:07flaviudom96: It seems that def-'s talk isn't considered a reliable source, unfortunately we can't use that as a secondary source then
21:10:05*askatasuna quit (Quit: WeeChat 0.4.3)
21:15:24AraqWikipedia itself is not a reliable source
21:19:33flaviuNimrod isn't metacircular a metacircular evaluation
21:20:20flaviuor bootstrapping, I'm not even sure what that line means
21:20:29flaviuAnyway, its meaningless
21:21:06*Ven quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
21:21:21gooblesit means lisp
21:21:37flaviuI know, but that line on the wikipedia article is meaningless
21:21:57flaviunimrod has nothing to do with metacircular anything
21:23:50*Hat_and_Cloak left #nimrod ("Leaving")
21:25:23Fx00Fis this one really notable? https://en.wikipedia.org/wiki/Pure_(programming_language)
21:26:16Fx00Fnot many references/external links there
21:27:41flaviuI'm not sure what "named return value optimization" has to do with nimrod
21:34:36AraqFx00F: it's notable because wikipedia has an article about it
21:35:09Araqflaviu: result is named return value optimization
21:35:34flaviuIt makes named return value optimization possible, but so does var result
21:36:33*Johz quit (Ping timeout: 240 seconds)
21:42:46*xtagon joined #nimrod
21:44:52*Boscop quit (Read error: Connection reset by peer)
21:48:50Araqflaviu: are you sure you know what "Named return value optimization" means?
21:50:25*ics joined #nimrod
21:55:52*Mat3 joined #nimrod
21:56:37adoniscikis there a way to know if an optional argument has been passed without using its default value?
21:57:30Araqif arg != defaultValue
21:57:44Araqotherwise use an overload instead of a default value
21:58:15adoniscikoverload, got it.
22:02:33flaviuAraq: I think so, I looked over the wikipedia page on it. I don't see that the C compiler would special case the result variable and not some other variable name. I'm also pretty sure that the C compiler can do RVO even on unnamed returns.
22:04:36flaviuYep, the wikipedia page shows unnamed RVO occurring, where there is no named variable
22:06:52*mwbrown quit (Ping timeout: 240 seconds)
22:08:08*Boscop joined #nimrod
22:08:08*Boscop quit (Changing host)
22:08:08*Boscop joined #nimrod
22:10:39Araqflaviu: ok ... but don't trust WP :P
22:11:48*io2 quit (Quit: ...take irc away, what are you? genius, billionaire, playboy, philanthropist)
22:13:08flaviuAraq: How about emprical evidence?
22:13:15flaviuRun their code, they are correct
22:13:44flaviu`clang++ ./test.cpp; ./a.out` prints just "Hello World!"
22:14:00Araqhow about helping with nimrod development?
22:15:40flaviuI'm actually the one having trouble with git this time!
22:16:32Araqimpossible
22:21:12*Matthias247 quit (Read error: Connection reset by peer)
22:27:49*superfunc joined #nimrod
22:27:57Araqgood night
22:28:18Mat3good night
22:30:22*Mat3 quit (Quit: Verlassend)
22:41:43*johnsoft quit (Ping timeout: 240 seconds)
22:42:16*johnsoft joined #nimrod
22:43:23*Fx00F quit (Quit: leaving)
23:01:38adoniscikis there a name for throwaway variables?
23:04:22flaviuadoniscik: Nimrod provides nothing special in that regard
23:06:55*darkf joined #nimrod
23:09:39*saml_ joined #nimrod
23:10:19*ics quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
23:11:08*mwbrown joined #nimrod
23:14:31*q66 quit (Quit: Leaving)
23:22:20*superfunc quit (Quit: leaving)
23:23:04*superfunc joined #nimrod
23:33:33*q66 joined #nimrod
23:38:18gooblesrvo
23:56:21flaviuWhats going on here: https://github.com/Araq/Nimrod/blob/devel/compiler/sem.nim#L99 ?