« first day (504 days earlier)      last day (4437 days later) » 

5:03 PM
Where is RMF... I need an xkcd reference that I failed to find via Google.
I'm looking for that geek-vs-nongeek time/effort curve
 
e.g.: f = (i){ std.io.print(i) } acts like a C++ template, and one could specialize with: f = (int8 i){ std.io.print(i*8) }
but that would make the assignment kind of dubious IMHO.
 
Proof that, for most questions, short "do this" answers with a single short code block and little explanation are more likely to get accepted than thorough answers that require reading: stackoverflow.com/a/9547901/726361
 
Xeo
I hate support hotlines...
 
@Xeo what about hot support lines?
 
@Xeo I hate phoning support people.
 
Xeo
5:16 PM
@KerrekSB maybe it wasn't xkcd?
 
If I name my threading namespace std.thread, my thread class will be std.thread.thread... hmmm
 
@rubenvb std.concurrency.thread
or like C#, std.threading.thread
@rubenvb did you write a new language?
 
@SethCarnegie I'm having a go at it.
 
@rubenvb sweet, how far along are you?
 
@SethCarnegie initial design stage. In short: nowhere yet
 
5:20 PM
lol
@rubenvb what do you have in mind for it (e.g. what languages will it be like)
 
It will have C-based syntax, be imperative, procedural, generic and will support OOP.
 
@LucDanton are you writing it too?
 
No.
 
Dialing is misspelled in the room caption thing
 
5:31 PM
i just wonder
does anyone know what are the reasons some of the most active contributors left?
 
What contributors where?
 
like neil and roger for example
 
"You have struck mica!" -> zoom to site, oh look! native gold. Oh yeah, and mica, too.
 
5:53 PM
@LucDanton So C++, then? :P
 
@DeadMG thatsthejoke.jpg
 
@SethCarnegie It's C-ish, but without all the cruft. Syntax overhaul, in the long run a beautiful library, while maintaining low level coding ability. Libraries will consist of LLVM bytecode, hopefully improving the classic long link times.
there will be no "header" concept, so a module like replacement (which improves parsing time, as the "modules" already contain the parsed form in contrast to textual headers. Documentation will take the place of bare header comments of course.
But as I said, currently, I have nothing. It's a hobby project, started in my thesis year, so don't go expecting proof-of-concepts by the end of the year
 
sounds kinda like Wide, but more pathetic
:P
 
@DeadMG dude, you're just jealous of my awesome currently non-existent bug-free compiler
 
hey
I have an awesome currently partially-existent bug-free compiler
my existence > yours
 
6:04 PM
FUUUUU
 
pwned
 
@DeadMG What's the most expressive code it can currently compile?
 
I believe that the last time I left it, it could parse the whole language
or pretty much all of it, anyway
 
What's the most expressive concept the language can express, then :-)
 
heh
uh
well, I'm pretty sure that it can express any concept
that was kinda the point
 
6:06 PM
lol
I wonder how hard decent type inference would be.
 
I mean
I invented it for the sole purpose of being far more powerful, especially at compile-time, than C++
you can have concepts and shit, for example
 
I wish there were a static version of StarCraft, where all the matches were decided already at compile time. It would save so much hassle.
 
lol
 
@KerrekSB and a lot of mouse clicks (although the pro's probably use the keyboard more)
 
@rubenvb Yeah. Much cheaper on the hardware.
 
6:10 PM
I'm also thinking about including a parallel_for. But then again, it will be mightily abused and might be almost impossible to implement decently as long as LLVM doesn't have auto-parallelization
 
speaking of which
IPL Team Arena final OGS vs Prime
winnnn
@rubenvb You don't need auto parallelization - look at the implementation of TBB or PPL.
 
@DeadMG won't that mean me having to implement it manually? Thus buggy and untrustable and stuff? Vs LLVM being awesome in all ways and having teh kewl feature in itself?
 
ok guys, I need some travel advice
NYC or Alaska?
 
@rubenvb LLVM won't have any particularly better ability to implement it than you.
@TonyTheLion Alaska is fucking cold
besides, if you target newer OS APIs, they provide thread pools and stuff
 
oh yes, I almost forgot: I'm totally abolishing the Standard C library. It sucks, hence you shouldn't use it.
One thing C++ got quite wrong, IMHO.
 
6:14 PM
yeah, everyone got that much
except D
of course, D got many, many things wrong
 
@DeadMG in winter yes, but not in summer
 
Alaska is fucking cold all year round, it's like Russia
 
ok, 16 degrees celcius average in summer
not that warm
 
This one's even better:
@DeadMG at least I'm writing my language's spec in XeLaTeX. Your web page will look very very shabby compared to my shiny pdf :P
 
6:20 PM
lol
 
(tbh I started in Word 2010, then figured it was a horrible idea and would make a lot of Open Source proponents very angry, and thereafter decided all my source code would be Public Domain)
 
but it doesn't work
spec documents for complex things like languages need to be hierarchical, not flat
 
@DeadMG correction: something that has not yet been written cannot "not work".
 
what, I haven't written my algorithm to solve the Halting Problem, therefore it doesn't not work?
 
@DeadMG uh, no, more like: there is no Halting Problem, cause there's nothing to produce Halting Problem code.
 
6:23 PM
right
 
You have like a full year of a head start.
 
I didn't mean that your language doesn't work
 
cut me some slack ;-)
 
I meant that writing your spec in Latex isn't going to work
 
@DeadMG how so?
 
6:24 PM
2 mins ago, by DeadMG
spec documents for complex things like languages need to be hierarchical, not flat
 
@DeadMG my thesis is complex, yet written in Latex. I think I'll manage that.
 
uh, there's a big difference
a thesis is like, "A, therefore B, therefore C."
it works because A -> B -> C is a straight line
a language is most definitely not a straight line
for example, take specifying classes in C++
classes -> constructors -> copy constructor -> references -> variables -> types -> classes
it's circular
 
you can "forward declare" a concept. That helps break circular dependencies
everyone knows what is meant with a "class".
 
sure
 
or can know without knowing all the nitty details about special member functions
 
6:28 PM
but then the majority of my spec would just be "Like it is in C++"
that's not a full specification
 
C++ spec is in LaTeX.
 
Someone not following your hierarchy while reading your spec will still understand the part he is reading I think (without continually following all links to the detailed explanation.
 
@CatPlusPlus Which, IMO, is a mistake.
 
@DeadMG what makes a static web page full of cross-links better?
 
There is no better typesetting system than TeX.
It sucks in many ways, but there simply isn't anything better.
 
6:30 PM
probably because the cross-links more naturally emulate the shape of the language, which is inherently cyclical
it's much easier to browse and find what you want
 
@DeadMG I didn't know \ref wasn't a cross-link?
 
You can cross-link in PDFs easily.
And compile LaTeX to HTML.
 
the C++ spec is full of links
@CatPlusPlus exactly.
A dynamic web page might have a case going for it, but the boundary between a document and an animated encyclopedia becomes a thin line then.
Is there a fundamental need for a try block? With a "Zero-Cost ABI", can't you "assume" a try block until the subsequent catch block? Or are there lots of ambiguous cases?
 
uh
if you have a catch, how do you know which part of the code to catch the exception from without try?
 
@DeadMG everything before it. I haven't thought it through completely, it did seem a sensible question though.
Exception types are matched anyways.
 
6:42 PM
so in other words, the equivalent of f(); try { g(); } catch... is impossible?
 
Hmmm, if you don't want to catch f's exceptions at that point, I guess you have a good point.
 
the real interesting innovations to be made over C++, apart from ditching C's legacy, are mostly to be made in compiler technology and compile-time power
 
Indeed, it does make the language feel like "nothing new" though. The C++ syntax can use a ton of improvement as well.
 
heh
it's easy to show "something new" with a lot of new compile-time power
 
@DeadMG ah, yes, I need to actually write a compiler. I almost forgot about that :P
 
6:49 PM
heh
the grammar is where I'm really picking right now
I introduced a lot of new semantics and it needs a lot of new syntax
getting rather ambiguous
and convoluted
 
Something I hope to avoid. Probably going to fail.
 
well, the fundamental problem is simply that more powerful languages need more semantics, and more syntax to express them
 
Not really
 
Yay, new GCC build fresh from the oven!
Crap, the stupid std::thread problem is still there. Why does that other guy NOT have it.. grrrrrr
 
7:12 PM
@DeadMG I was thinking, could someone not write a compile-time virus in your language
So that when you compile someone's code, it harms your computer
 
glskel has two source files that compile to 2MB library.
 
already?
 
Could someone write my previous two messages to DeadMG, I think he has me on ignore for disagreeing with him about const char*
 
@SethCarnegie I don't think the @DeadMG uses ignore lists, he just ignores. He can read your messages on his screen nonetheless.
 
@rubenvb he said "gotta love that ignore button" or something like that
at the end of our discussion
 
7:17 PM
oh wow, you must have pissed him off badly
@DeadMG Are you really ignoring (by use of the "ignore everywhere" button) Seth Canegie?
 
@rubenvb I was saying I was using const char* in my code and he said never to use it but couldn't come up with a reason (that I agreed with)
 
yes
 
Well, in that case, he told us to tell you this:
I was thinking, could someone not write a compile-time virus in your language

So that when you compile someone's code, it harms your computer
 
@rubenvb you can read the transcript somewhere
 
const char* is pretty much useless.
 
7:19 PM
@SethCarnegie why the hell would I do that? I waste enough time in here already.
 
@rubenvb in case you are curious
 
so what? you can write a run-time virus in C or C++ and harm the dev machine during testing
 
@DeadMG so you see me talking to him, and about him, but not his messages?
 
I didn't say you would, I said you could
 
@rubenvb That is how the "ignore" button works, too
 
7:20 PM
@rubenvb it must look like you are talking to yourself lol
 
It must look like I'm talking to myself
 
the "@SethCarnegie" thing gives it away
 
ah dang. Forgot about that :P
 
So much wind outside, I'm scared.
 
40 users talking in 12 rooms and Lounge<C++> has 33
7
 
7:25 PM
@SethCarnegie What? The Lounge is awesome? Stop the presses!
 
i declared array pointer int *jagged[5]; ? how to i get length of this array when i use sizeof() function it give me 2 ...
 
sbi
DRONES THINK THAT IF YOU KNEW HOW IT FELT TO HAVE A KERNEL PANIC YOU WOULD NOT TREAT MACHINES WITH SUCH DISRESPECT. — @DroneInsertion
 
sizeof() is not a function.
 
std::array<int*, 5> jagged;
../src/windows/window_impl.cpp(266): Throw in function register_class
Dynamic exception type: boost::exception_detail::clone_impl<glskel::error>
std::exception::what: std::exception
[glskel::tag_error_message*] = Could not register window class.
[glskel::tag_os_error_code*] = 0
[glskel::tag_os_error_description*] = The operation completed successfully.
Kewl.
 
16
A: Computing length of array

avakarYou can use the following function template. If you're using Boost, you can call boost::size. template <typename T, std::size_t N> std::size_t size(T (&)[N]) { return N; } int iLength = size(carray); As others have already stated, however, you should prefer std::vector to C-styl...

 
7:35 PM
well played
 
Of course, I inverted the logic in throwing macro.
Go me.
 
a throwing macro?
ur code is teh uglies
 
I want to record file, line and function.
Try doing that without macros.
 
fair play
but I usually just use a breakpoint for that and then look at the call stack
 
Yay, window creation works.
(And yes, it is ugly, but it's a prototype so whatever.)
 
7:40 PM
@CatPlusPlus ugly prototype is ugly
 
7:52 PM
hmm... every function generic (and longer compile times) or an explicit generic marking for those that are meant to be general... Decisions decisions...
 
sbi
> If you don't understand the difference, then please stay out of the discussion. — Bill the Lizard to a meta-cop demanding deletion of old and popular questions
3
 
@sbi Yeah, I saw that question. That Gilles guy is angsty. Maybe he should take a walk or something.
 
@EtiennedeMartel "a walk or something". You should go for psychologist!
 
@rubenvb A beer also works.
 
sbi
@rubenvb I'm afraid there's a bit more to that profession that suggesting a walk if someone throws a fit.
 
8:03 PM
Or at least I hope so.
 
@EtiennedeMartel If a beer doesn't work, try two beers!
 
Or vodka.
 
@sbi good find on this, that's the only reassuring thing i've seen since yesterday
 
Whiskey!
 
sbi
@GeorgFritzsche Yeah, but it's very reassuring. Essentially, all the answers are by old farts, and they are all against this.
 
8:06 PM
@sbi Meta must be a smelly place if it's filled with old farts.
 
sbi
@EtiennedeMartel If a bad smell was the worst problem meta has, SO would be a much better place. Unfortunately, with the attitude of the meta regulars, you won't even have time to notice the bad smell before you are clubbed over your head.
 
typed function arguments or everything a template? I NEED INPUT!
 
yeah, the real problem with meta is that a very small part of the user-base tries to make the decisions as "the community"
 
@sbi It's a pity I can't go and roundhouse kick them in the face.
@rubenvb Template the shit out of it.
 
sbi
@EtiennedeMartel Actually you can. Every time someone says something sane on meta, the meta-cops feel like they have been kicked into their nuts.
 
8:10 PM
@EtiennedeMartel won't that kill compile time? (it's not for C++, but a non-existing language)
 
When Jeff said "Meta is Murder", I don't think he realized how right he was.
@rubenvb It's not like you can't go grab a beer while it compiles.
 
In Haskell nearly all functions are polymorphic, and it compiles way faster than C++ ever will.
 
@EtiennedeMartel lol, the problem is that I want to reduce compile times (and link times) and with what I have in mind now, fully generic functions will push a lot of time into linking (where the generics are instantiated). :(
 
@JohannesSchaublitb !
 
8:15 PM
@CatPlusPlus However, type-classes vs static duck-typing may or may not have a lot to do with that, doesn't it?
 
where's the love!?
 
sbi
@EtiennedeMartel What's worse is that Jeff doesn't realize how much meta being murderous is his fault. It's exactly his attitude of dismissing, belittling, and deleting dissent that spread through the meta crowd and leads to them looking down their noses at the grunts answering questions out in the trenches.
 
Typeclasses beat C++ templates anyway.
 
@CatPlusPlus WTF are typeclasses?
 
8:15 PM
c++ templates beat typeclasses by large
 
@CatPlusPlus So the lesson is: do polymorphism, but carefully!
 
since they are turing complete, but type classes are not (they are a static table)
 
Try doing polymorphic constants with C++ templates.
 
@sbi Yeah, I've heard Jeff wasn't the most open minded guy.
 
Oh, right, throw enough boilerplate at it and it'll work.
Also, apparently, there's Eclipse plugin for Haskell.
 
8:18 PM
@CatPlusPlus there's an eclipse plugin for everything. Eclipse invented the app market before there were apps
 
@EtiennedeMartel "this stuff is not available for your country because the GEMA has not granted the necessary rights."
 
Yeah, but most of them doesn't work.
 
@CatPlusPlus and the difference with real apps is...?
 
@JohannesSchaublitb Well, fuck.
 
8:23 PM
The wiki page on typeclasses makes me believe it is compile-time inheritance. WTF is that all about? Nice template error messages for a lot of extra source code?
 
Have to do with the type system.
 
Do anyone knows, How much Stack Overflow would charge for putting an advertisement?
 
@ThinkDifferent You need to email or call them: stackexchange.com/about/contact
 
@ThinkDifferent Just contact them and ask?
 
In Haskell, even the boilerplate is terse.
 
8:25 PM
@rubenvb I'd mailed them, but I need some rough idea of charge.
@GeorgFritzsche I did.
 
Typeclasses are bit like interfaces or concepts, but awesomer.
 
but a C++ template lets you get away with all that without the typeclass, no?
 
Also if you start calling language agnostic features by the name of the C++ implementation of a similar feature your credibility as a language designer is going to fall a long way down. There are no templates outside of C++.
 
@CatPlusPlus How so?
 
@LucDanton generics/templates/whatevertehfuckyouwannacallem
the only difference is runtime or compile-time generic
all the rest is bullocks
 
8:27 PM
@DeadMG He's a Haskell fanboy, of course they're awesomer.
 
You're wrong.
 
@LucDanton I live to be enlightened. Please enlighten me.
 
@Luc "there are no templates outside of c++" HUH? D has them
 
@JohannesSchaublitb one of D's many fails
 
Java has them too, but calls them "generics"
 
8:29 PM
Right okay. Compare generic programming in Golang to generic programming in OCaml. Does it matter that one is runtime and the other is compile-time? Languages are tied to their implementations eventually but you don't want to cripple upfront design imo.
 
generics != templates
 
that comparison doesn't make sense
 
@JohannesSchaublitb Haha. There's no need to lawyer up on that assertion, it was rhetorical.
 
i can equally well say std::string != java.lang.String
 
you just said generics == templates
 
sbi
8:29 PM
I have just removed the duplicated content of the The Definitive C++ Book Guide and List from the tag wiki for the second time in a week. I have now left a strongly-worded HTML comment in the tag wiki that copying this stuff is stupid and shouldn't be done. Please have an eye on this.
I have also taken my 3k rep at meta and changed the suggestion to delete that question so that it now proposes to not to delete it. I'm already wearing my asbestos suit.
 
all I'm saying is generics != templates
 
@DeadMG i didn't make such a comparison expression
 
1 min ago, by Johannes Schaub - litb
Java has them too, but calls them "generics"
 
i said that java has templates but calls them generics
 
From MSDN: `Generics were added to version 2.0 of the C# language and the common language runtime (CLR). Generics introduce to the .NET Framework the concept of type parameters, which make it possible to design classes and methods that defer the specification of one or more types until the class or method is declared and instantiated by client code`
Sounds like templates to me.
 
8:30 PM
that is different from trying to put up a formal equation of some sort
 
@sbi Fuck 'em up!
 
so Java's generics are templates, i.e., generics == templates
 
Is metaprogramming in Lisp or a Forth-derived language compile-time or runtime? Both? Does it matter anyway?
 
@rubenvb Not at all.
templates are Turing-complete and vastly more powerful than generics
in either Java or C#
 
Turing complete means shit
 
8:31 PM
@DeadMG no. generics are an implementation of a feature that templates implement too
it doesn't mean that templates are generics.
you have it wrong
 
templates implement many, many features, and generics implement a tiny amount of the amount that templates implement
so your assertion that Java has templates but calls them generics is so wrong
 
What is the most general name for whatever I originally was talking about?
 
Stuff?
 
Clearly it's not template, nor generics, what is it?
 
java.lang.String too has more features than std::string but still both will be called "the string types of the language"
 
8:32 PM
@sbi Fuck, that @JoshCaswell guy as already reverted your edit.
 
eh
I usually think of them as compile-time metafunctions
 
sbi
@EtiennedeMartel Yep. I suppose it's not worth to start an edit war?
 
@rubenvb Parametric polymorphism.
 
I thought type classes were ad-hoc (or are you just talking about templates?)
 
@CatPlusPlus is that Turing complete?
 
8:34 PM
@sbi I don't see anything about book lists in the tag wiki.
 
not that I care, but @DeadMG seems to.
 
C++ templates are just particular implementation of that.
 
@sbi This whole thing is getting quite annoying.
 
sbi
@DeadMG That's because I deleted it. (@Etiennede was speaking about the deletion audit question @ meta.)
 
Turing completeness is more of a by-product than design goal.
 
8:34 PM
@sbi Ah. OK.
 
You don't have to use the same feature for both param. polymorphism and metaprogramming lol.
 
@CatPlusPlus is it absolutely necessary for something like this?
 
@CatPlusPlus Originally. I think it should absolutely be an explicit design goal to make it as generally useful as possible.
 
Template metaprogramming is a mess.
 
@LucDanton Technically, no. But in reality, why have two separate systems which both do pretty much the same thing?
 
8:35 PM
Compare that to Template Haskell.
 
the problem is that templates were a stupid mistake from the beginning
 
Oh, I got a clean TMP system going.
 
World of difference.
 
@DeadMG Long compile times, verbosity, horrible errors?
 
@LucDanton That's because templates suck, not because of any effect of using a proper metaprogramming language to do parametric polymorphism.
 
8:37 PM
@DeadMG I'd question that 'they do pretty much the same thing' anyway.
 
making constexpr turing complete was a design goal
 
@LucDanton Metaprogramming: Functions which take and return arbitrary objects. Parametric polymorphism: Functions which take and return types, and maybe ints and such too.
 
Take one of those languages that do their metaprogramming in the language. There's no 'single system' taking care of two completely unrelated features.
 
clearly parametric polymorphism is just a subset of metaprogramming
 
@DeadMG Your definitions are out of whack.
2
And on that note I'm going to bed.
 
8:38 PM
@LucDanton thanks
 
sbi
> No matter whether you roll back that edit or not, the statement as it is in the question is simply wrong. It has not been moved to the tag wiki and should not be moved. As has been explained here, the tag wiki is insufficient for keeping so much information. The C++ folks is maintaining the question, and duplicating its content is stupid. It started to drift apart about two days after it had been duplicated. — sbi
 
Hi
 
@sbi where is that quote from?
 
sbi
@EtiennedeMartel ^see my comment.
 
sbi
8:40 PM
@JohannesSchaublitb Have you tried to click the link? On the web, this sometimes helps.
1 hour ago, by Seth Carnegie
40 users talking in 12 rooms and Lounge<C++> has 33
@SethCarnegie Actually, this also gives us considerable power.
A lot of users come here. We're a strong community. At least 50% of the high-rep users of the C++ tag are here more or less regularly.
 
and we have few internal divisions
unlike, say, the Android tag
 
sbi
If we decide we are fed up with the meta-police interfering with our work out in the trenches, and stop posting answers to C++ questions just for a single day, this might make a considerable dent into SO's shiny face.
 
"internal divisions"
 
I want to fight the power
 
@rubenvb There are like, three or five Android rooms or something ridiculous
we have one room and we generally act as a group in resisting the Meta Police
 
sbi
8:44 PM
@Pubby Then you have come to the right place. :)
 
@DeadMG oh, yeah, Fuck the meta police :P
 
heh
FIGHT DA POWAH!
 
Appropriate Dutch term: en.wiktionary.org/wiki/mierenneuker (lit. ant fucker)
 
For the record, I would always try the Android room with the little Diamond in its title, All the rest seem illegitimate
 
8:50 PM
Shit's getting real.
 
sbi
Wile you make nice statements here, me and @Dead are thes one who actually are fighting.
> I did edit it to be correct. The question was not in the tag wiki, and the highest-voted answers demanded to not to delete it. Your personal opinion on this is all nice and well, but it doesn't seem to line up with the community's opinion. I suggest you undo your rollback. — sbi
 
@ScottW about C++?
Oh wait of course, you said "good dreams".
 
Didn't someone here dream about Bjarne all the time?
 
lol
the gang of two. @sbi and @deadmg
 
sbi
@Pubby I bet it was @Fred. Or wait. Didn't he dream about STL?
 
8:58 PM
I only dreamt about SCons and premake4 when it comes to programming.
 

« first day (504 days earlier)      last day (4437 days later) »