« first day (1202 days earlier)      last day (3744 days later) » 

4:04 AM
int inline long constexpr static unsigned const long foo();
I really want to do that on my exam.
 
user3010322
@chris Wish I was taking a computer class so I could actually do it. =[
 
user3010322
@ScarlettAmaranth I got the camera working and I has raytracer which outputs in real time.
 
user3010322
It's much faster than the real time output shows, though. Having to stop every 16 milliseconds to display current progress is actually really bad for pixel throughput. I should probably put it on another thread.
 
@chris that's not valid....
 
user3010322
The first "int" seems invalid?
 
4:08 AM
@MooingDuck Clang compiles it and it should be AFAIK.
 
whaaaat?
 
Well, minus warnings for const being ignored.
 
cpx
Is there any point to learn MFC before using Qt?
 
int ----- long ----- ---- unsigned ---- long ?
@cpx no
 
cpx
4:09 AM
I was thinking if by learning MFC I'd get to know my Operating system better.
 
user3010322
@cpx You monster.
 
cpx
But Qt is so easy
 
I was wondering why exactly typedef could be used like int typedef int_;, and then I found that so many other keywords could be used the same way.
 
@chris that's so wierd
 
The relevant text in N3485 is § 7.1/2.
 
4:16 AM
@chris Mix it up by sneaking a just as fucked up typedef alongside.
 
@LucDanton int long unsigned typedef const long foo;
 
@cpx If you really want to get nitty gritty with windows, i'd suggest stabbing yourself with Win32Api.
 
I’d keep the ().
 
cpx
I was already doing Win32Api.
 
@cpx If you wanna ship stuff with C++ though, get qt and be done with it.
 
cpx
4:19 AM
I better just do assembly language :D
 
@LucDanton Oh right, forgot this isn't the function pointer.
 
MFC is an abstraction on win32, AFAIK. I don't see how it will teach you more about your OS.
 
I've never used MFC, but no one really likes it. Then again, I've done a lot of winapi and no one likes that.
 
@chris yeah. because .net pretty much obsoleted win32, for most business apps.
 
@xslr Yeah, I like .NET enough, too.
 
4:25 AM
@MooingDuck The problem is that Python 2 Unicode handling is rather crappy, and those errors sometimes appear even when they're theoretically impossible
 
cpx
Does MFC not allow you to see the code behind it's classes to learn how it is doing it in Windows API?
 
@LucDanton I don't know whether to be happy or sad that Clang compiles this at all: coliru.stacked-crooked.com/a/5520175831a20ff4
 
cpx
If no then I'd pick Qt btw.
 
Don't do UIs with WinAPI
It's tedious, error-prone and completely unnecessary
 
@CatPlusPlus Agreed from personal experience.
 
4:28 AM
@cpx the code ships with Visual Studio, or the SDK or something
 
The only worse idea is probably doing an UI with just X11
 
hahahahah
 
You only get MFC with VS Pro and up afair
 
@chris Apparently you can put ref-qualifiers for *this as well :D No idea if that should be accepted though.
 
cpx
Learning more about the Windows API was my primary reason to pick MFC.
 
4:29 AM
Also maybe whatever shit OSX uses on account of being Apple API and Objective-C
 
@cpx why do you want to learn winapi?
 
@LucDanton Oh boy. And this doesn't even include references or pointers.
 
user3010322
There's no need to learn Win API unless you absolutely have to.
 
@cpx The only thing you need to learn about WinAPI is that "learning WinAPI" is silly, mostly impossible goal
 
Arrays!
 
user3010322
4:30 AM
It's not a skill you just soak up and then put on your resume. It's experience-based and only to be used when there is no other option.
 
cpx
Because I have been using Windows API for quite a while.
 
user3010322
Stahp.
 
Also there are so many parts of that API it's not even funny
 
So have we had any trolls since we changed the room name?
 
@LucDanton I'm actually genuinely curious why you can attach ref qualifiers now.
 
4:30 AM
time for something new then.
 
user3010322
@Mysticial Not that I've noticed.
 
@Mysticial No, but it's night
 
user3010322
But I've not spent a lot of my time here.
 
user3010322
@Mysticial Clearly, our title needs to be more fabulous.
 
The new name draws my colleagues unwanted attention :v
 
cpx
4:31 AM
Moving straight to Qt I feel kind of detached from my windows programming.
 
Good
That's the point
 
@cpx obviously, since it is a much higher abstraction.
 
Welcome to the concept of abstraction
 
@cpx You should also consider wxWidgets, which isn't that bad as some say.
 
It's a p useful concept to know in programming
 
4:32 AM
uhh
 
user3010322
Lounge<Gay>: Fabulous Code, More Fabulous Butts
 
@chris I’ve always found those special case rules too specific.
 
user3010322
@Mysticial ^ That might get more attention.
 
@MarkGarcia wx is about as good as MFC
 
@LucDanton Oh, they're explicitly allowed for "the top-level function type of a function typedef declaration or alias-declaration"
 
4:32 AM
+cat
 
I.e. not very much
If you don't want Qt, get gtkmm
There's p much no other choice for C++
 
user3010322
Yeh.
 
user3010322
That is,
 
user3010322
until I finish my UI framework~~
 
@CatPlusPlus It's nice if you just want an abstraction to WinAPI (e.g. using the underlying HWNDs in some libraries).
 
4:34 AM
@MarkGarcia You can get native handles from any toolkit
 
user3010322
qtwindow.Handle()
 
user3010322
Solved!
 
@ThePhD how's your progress? Got a public repo?
 
user3010322
@xslr My progress is slow. No, the repo isn't public.
 
@ThePhD :v Is it cross paltform?
 
4:35 AM
@ThePhD Qt "standard" library. And moc. And all other stuff to set-up.
 
@chris Kinda suggests that they’re pretty much allowed anywhere, save of course for actual declarations where it’s nonsensical. Although I don’t know about template arguments — can you imagine if you could pass an alias to a ref-qualified function type, but not an actual such type?
 
user3010322
@xslr Yes.
 
user3010322
Or rather, I'm working on it.
 
@ThePhD ... on windows. :P
 
@ThePhD I look forward to the day you finish it.
 
user3010322
4:36 AM
DX11, XAudio, GDI+ and Direct2D/DirectWrite are all wrapped up into platform-agnostic wrappers: the abstraction is very strong, making sure no client-facing code includes windows.h or anything remotely related to it.
 
user3010322
Keepin' dem namespaces clean, yo.
 
user3010322
I'm working on OpenGL porting right now in Windows. After that, I have to port X11 and FreeType (not looking forward to that shit).
 
why freetype and not pango/pangocairo?
complex language will be a pain in FT.
 
@xslr Why not freetype? ;)
 
30 secs ago, by xslr
complex language will be a pain in FT.
 
user3010322
4:38 AM
FreeType is crossplatform and well-proven and vetted. When I get sick of GDI+, I can use FT everywhere. It also has gone out of its way to make sure it's not using any patent-protected algorithms (all of which has expired related to it, but it's nice to know it's checked).
 
@LucDanton I don't know. How would you even use that type alias? AFAICT, you can't assign anything to any objects created with it.
 
user3010322
@xslr Pango and Cairo do actual rendering, AFAIR. And that's not something I want to actually deal with: I just want the text representations, the rendering is something I take care of by myself (or let the underlying graphics system (D3D/D2D) handle).
 
Objects?
 
lunchtime. see you guys later.
@ThePhD you can probably extract layout info from pango. maybe ICU too.
 
@LucDanton Like if you had a typedef void foo() &;, it's not like you can do foo f; and actually assign anything to f.
 
4:41 AM
That would declare a function, not an object.
 
@LucDanton Eh, I'm not completely sure what does and doesn't qualify as an object. I should have said initialized, though, as functions can't be assigned to.
 
int& i; // no object here :D
 
But what would you initialize f to?
 
virtual foo f = 0? That’s not an actual initializer of course.
 
@LucDanton Actually, I guess this works.
 
4:50 AM
Yes, but there’s no initialization going on.
 
Well, I wasn't as focused on initialization. I was wondering what use allowing it on a typedef like that could have.
 
Should have asked that.
 
Well, here's another interesting one based on the standard's example.
typedef char *Pc;
void foo(unsigned Pc); //void foo(unsigned int)
unsigned Pc bar; //error
 
I’m guessing typedef long i; void foo(i int); does not follow though.
 
@LucDanton Doesn't look like it.
 
5:03 AM
void foo(i unsigned); is pretty mind fucking on the other hand!
 
Interestingly enough, void foo(unsigned Pc arg); is also an error.
I have no clue why I wouldn't be able to name the parameter.
 
Then doesn’t void foo(unsigned Pc); involve a parameter named Pc?
 
@LucDanton Oh, good point.
For some reason, I took the "name being redeclared" and turned it into garbage or something.
 
FTR char* unsigned doesn’t make too much sense. I thought the Pc typedef was meant to be e.g. char.
 
@LucDanton Well, both work the same way.
The example in N3485 uses char *.
 
5:11 AM
unsigned char is a thing though :Þ
 
@LucDanton Yeah, good one for the books: coliru.stacked-crooked.com/a/1be7215ecb15b00f
Also, Coliru was freezing up for a while, so I switched to Ideone. Lo and behold, I go back to Coliru and get a nice unused parameter warning, making what I was missing before obvious.
 
5:31 AM
0
Q: How to hide negative reputation in reputation tab

Amarnath BalasubramanianI want to hide negative reputation which appears in the reputation tab. I want to know the settings do so. Please help

If you check out the OP's rep history. It looks like he got busted for sockpuppeting. lol
Or not. It's too recent. He wouldn't have had enough time to go in and out of suspension.
 
Is there any plan to change the lounge name soon?
I am a bit concerned with entering a gay lounge
people would misunderstand
If someone take a screenshot & post the picture on the web
my reputation would be ruined!
Nothing against gay of course
 
Can I still confess? :P
 
5:46 AM
@sudorm-rfTelkitty People see a picture on the internet and start downvoting everything of yours?
 
@sudorm-rfTelkitty Because your reputation is so spotless to begin with?
 
@ScottW link
 
Thanks to you guys in this gay lounge, your advise is invaluable!
by being me of course
I have my 'fans'
people LOVE to hate me
I am naturally talented
^_^
 
0
Q: Creat a dynamic class in java

Blue BoyI want to create java class dynamically(When run time). Following is the requirement : I have a method, which takes in parameters Class Name and List of fields and their type . public void create Class(String ClassName, List <fields> fields) { }

 
BURN IT!!!
IT'S JAVA!!!
gay lounge talking about java, this is so great, I will leave the loungers until they become normal
 
6:05 AM
@chris TIL you can define an enum outside. Nice.
 
@MarkGarcia Today is quite the day for learning :)
 
@MarkGarcia ???
 
@chris BTW, does the OP mean he wants to include the definition file from a remote server?
 
@MarkGarcia TIL it works the same way in classes as out? lol
 
Not sure about inside classes, but outside of classes, you'd need to specify the underlying type. Edit: Yeah, try removing the underlying type from here. — chris 5 mins ago
 
6:07 AM
@MarkGarcia I have no idea, really.
 
@MarkGarcia TIL
 
@chris I experimented once some time ago and found out. Great way to prevent too much nesting and 80-column rule overflows.
 
@MarkGarcia Good point.
TIL "corroborate".
Now there's a nice word.
Btw, to all of those TILs about forward declaring enums, I remembered that I learnt it from Wikipedia's C++11 page :)
Gah, it's over an hour after I should have gone to bed.
 
@chris Is there a reason why you specified the enum-base here ?
 
6:23 AM
@xslr C++11 requires the size of the enum if you're forward declaring it, so doing : int, you are specifying its storage type, consequently its size.
 
gotcha. ty :)
 
@chris Some rationale might be found in this answer here. It seems you already know about that though, given from your example. — remyabel 16 mins ago
I find this question sounding very militaristic.
 
Well, I have CS tomorrow (today). I think we're doing a stack or something using a data structure and free functions that take references now and then maybe finally starting classes.
It is a data structures course I guess.
Anyway, I keep looking for an excuse not to sleep, so I am now. At least it'll be around 6h on the dot, which works out better than halfway through a sleep cycle.
 
0
Q: Lets create a dutch part of stackoverflow

D3l4n0Dutch user here, i'm a student learning c#. There are far to few good sites where dutch people can ask dutch questions about code and get good legit answers. So me and my fellow classmates and some other guys from school where thinking, why not ask stackofverlow to create a dutch part ! Most of t...

 
cpx
7:01 AM
I'm going to go with WxWidgets because it has native look, uses standard C++ with no extra things to build, can be statically linked, mfc-like, and free.
 
@MarkGarcia I love how he's asking to make a dutch SO and one of the comments is "please learn how to ask questions in English" xD
@TonyTheLion <3<3<3<3<3 Hai
 
@cpx Pretty much everything's covered in the docs.
 
cpx
I would prefer docs if they are easy to follow and has tutorials.
 
@Borgleader hai <3 <3
9 hours ago, by Xeo
@StackedCrooked break a leg and you'll have more time on your hand than you'll know what to do with
I don't advice this ^
having experienced broken legs myself, the agony is just not worth it
 
7:15 AM
@cpx I found the large amounts of links daunting at first, but it's actually easy to understand. After the tutorial, it's just like other GUI libs for you to familiarize with the controls.
 
@TonyTheLion Says the guy who hasn't programmed in a month :P
 
You can break your brain instead
 
@Borgleader Hahah
@CatPlusPlus Good morning Cat!
 
I need to go to dean's office, possibly stand in a queue for an hour, just to turn in an empty piece of paper that says that I never set foot in a library and therefore don't have a filled piece of paper to turn in
So yeah good morning sure w/e
 
@CatPlusPlus Don't you love bureaucracy!
 
7:22 AM
(Also haven't slept, because my day is 32 hours long or whatever)
 
oh gawd :/
 
@TonyTheLion I once witnessed my brother faint just because of a toe sprain.
 
I just noticed the new room name.
@MarkGarcia damn :(
 
@TonyTheLion Probably compounded by stress and exhaustion. Also first time I saw an actual man faint.
 
Before you only saw imaginary people faint?
 
7:27 AM
@CatPlusPlus TBH, I actually thought of typing "real" first.
 
@MarkGarcia I saw a lady faint because she saw a drop of blood, quite literally.
@CatPlusPlus I think you're not helping yourself being up for that many hours at a time. Just saying.
 
I can't see blood, I won't faint but I will feel sick
possibly because subconsciously I associate blood with menstruation & it used to very painful
 
cpx
I fainted when I saw someone getting an injection.
 
through years reinforcement, nowadays I just feel sick seeing blood
 
cpx
When the doctor drove needle the inside.
 
7:37 AM
every woman is different though
 
@TonyTheLion Alos noticed the new description? Big orgy on June 7th, don't miss the fun.
 
I'm excited about the orgy!!! I LOVE ORGIES! :P
3
 
dafuq?
 
Notice the :P at the end
I was being silly
 
JBL
7:59 AM
@TonyTheLion The fack. In the morning. Such violence.
 
user1804599
@TonyTheLion meh, the smiley screws it up.
 
user1804599
I broke a car.
 
user1804599
8:14 AM
Oh wait. I braked a car.
 
Is that a pun?
 
user1804599
No.
 
8:30 AM
git-annex installer creates a shortcut that a) doesn't point to the executable, because I've changed the install path and it's just too difficult of a situation for git-annex installer b) uses a global fucking key binding. FOR A GODDAMN CLI APPLICATION. WHY THE FUCK DO YOU MAKE KEYBINDINGS FOR CLI SHIT
IT'S NOT THAT DIFFICULT WHEN YOU ACTUALLY THINK ABOUT WHAT THE FUCK YOU'RE DOING FOR TEN GODDAMN SECONDS
 
For the brainless among us, it can be quite hard.
 
fuck's sake
 
> Template argument deduction cures cancer and solves the halting problem.
6
lol
 
ergh.... another 'meeting'?
 
@FredOverflow I always knew it!
 
8:38 AM
@TonyTheLion did you call up?
 
@FredOverflow Seriously STL is awesome.
 
template<typename T> struct decays : std::false_type {};
template<typename T, size_t n> struct decays<T[n]> : std::true_type {};
template<typename R, typename... A> struct decays<R(A...)> : std::true_type {};
Yay variadic templates!
 
JBL
@FredOverflow Awesome haha!
 
8:54 AM
I wish Java had some macros or anything else similar working at compile time.
 
I'm actually glad Java doesn't have a C-like preprocessor :)
Or what kinds of macros were you thinking about?
 
Yeah.
 
Java has something "working" at compile time: Generics. They remove type-information at compile time :-)
 
Well, I need something to do stuff like if (logger.isEnabledFor(DEBUG)) { logger.debug(msg, params); }
It is annoying having to write that if all the time.
 
Can't you put the if inside the logger?
 
8:57 AM
@FredOverflow: The point is to avoid evaluating the parameters.
 
@wilx what do you want to do?
@wilx AspectJ
 
Hmm...
Any examples?
 
you can use so that any call to 'logger.debug' can 'fucked around with' to have the 'isEnabled'
 
if the debug message is an object with a method to generate the log entry, only a pointer/reference needs to be passed in. The logger can either then return or evaluate the text and output it.
 
@wilx You could emulate call by name with lambdas.
 
8:59 AM
@FredOverflow I am restricted to Java 6.
 
@wilx also, what logger you using? log4j?
slf4j is able to do something clever to avoid evaluating parameters when logging at a level that is not enabled.
 
@thecoshman no. Decided I'm not going.
 
@thecoshman I believe it is slf4j in the backend but the code is sprinkled with both log4j and Apache commons logging and SLF4J instances of Logger.
@thecoshman Interesting. Reference?
 
JBL
Mmmh. Does someone know how long do shared code samples stay on Coliru ? (poke @StackedCrooked)
 
@wilx so it's a cluster fuck, what less would you expect.
@JBL until he manually deletes them
 
JBL
9:02 AM
@thecoshman Ok so "inderteminate" :)
Thanks !
 
user1804599
@abstractmethod y u ignore __call__.
 
@TonyTheLion oh, shame. Going to have a look for hotels, save being in your hair main the entire time (or at all, see how prices go)
@wilx what do you mean? it's a claim the slf4j make themselves.
 
@thecoshman I want to see where it is written that it does that. :)
 
@wilx Dang. Otherwise, you could have used logger.debug(() -> msg, () -> params); or something.
 
@thecoshman oh ok
if you want, we could still meet up
 
9:04 AM
@TonyTheLion oh sure :)
 
JBL
Silly me, that was right there in the feedbacks: "As long as Coliru stays alive"
 
@thecoshman :)
 
@wilx vOV go read their site yourself
 
lol
@thecoshman I am already searching...
 
@wilx IIRC it's only for when a log message contains one or two parameters, any more and it can't do it.
 
user1804599
9:08 AM
Fucking dynamic typing.
 
@rightfold typing dynamic fucking
@TonyTheLion what about a festival in August? CoF playing there too
 
user1804599
Why can I subclass an abstract class without implementing abstract methods or making the subclass abstract too.
 
user1804599
Instead, it raises an error at instantiation time.
 
user1804599
Python is a terrible programming language. Even PHP is better in this regard.
3
 
@rightfold that is a bold claim :p
 
JBL
9:17 AM
Bleh.
 
@rightfold why are you trying to instantiate it then?
 
JBL
Where's the "Must demonstrate a minimal understanding of the problem" in the close reasons ?
 
user1804599
@thecoshman The point is that I am using abstract classes to raise an error when subclassing them without implementing all methods.
 
@JBL Too idiot-- I mean, newbie-unfriendly.
 
user1804599
Why else would you have an abstract class in a dynamically typed language.
 
9:18 AM
@JBL So they nuked it.
 
JBL
@Griwes Yeah I understand. But when someone asks for something really, really, really basic or easy to find using a quick google search...
 
JBL
I always have a hard time finding the good close reason and use way much the "Other, describe" than anything else. (Especially w.r.t. "Should be moved to another SO site", where if it's not Super User or Server Fault you're screwed)
 
dan
good morning yawn
 
JBL
Good morning!
 
9:26 AM
Average morning!
 
JBL
> # no erreur!
Lol
 
@JBL I wish we were just able to put LMGTFY links in "duplicate".
 
JBL
@Griwes That'd be cool.
 
@rightfold To not write raise NotImplementedError everywhere
You probably don't need ABCs
Also for overloading isinstance
Also your second example doesn't even inherit from the abstract class you dummy
 
JBL
0
Q: How to concatenate a char * and a const char*?

UdayI need to put "Hello World" in str3. How can I do this ? const char *one = "Hello "; char *two = "World"; char *str3;

 
9:41 AM
Also if it worked like you want it to work, you wouldn't be able to make inherited abstract classes
 
JBL
As per absence of "Must show research done" in the close reasons, this question is then fine. Great.
Sigh
Oh well.
 
It's an SO question, what'd you expect, quality?
 
JBL
I don't expect quality (though there are good questions), I expect to be able to vote to close/put on hold bad questions.
 
Why
I'll tell you a secret
 
JBL
Ugh
 
9:44 AM
You don't get anything for putting up with shitposts on SO
hth
 
JBL
I like to think it's somehow "Contributing".
But I (kinda) know what you'll answer to this.
 
Ain't worth it
 
JBL
I expected this.
 
There, duplicate vOv
 
JBL
"Duplicate of a question which itself shows a lack of minimal understanding". :P
 
cpx
9:47 AM
What big orgy?
 
JBL
(The original at least showed some effort)
 
sbi
Hi. I got a problem.
It's here and it requires some TMP skills.
Also, there's a deadline involved.
Anyone here?
 
Urgent questiondumping, /ban
Nah I don't really know probably
 
sbi
@CatPlusPlus Not do I just dump a question, since Björn just asked me to give his refactoring ideas a reality check, I will even leave immediately after I have done so. :-b
I'll be back later, though.
 
I'd probably write it myself instead of going into MPL/Fusion mess
tbh
You can use Boost.PP to generate pseudo-vararg templates
 
sbi
9:53 AM
So would I. However, I keep being bashed here for bringing in my well-used TMP tools from a decade ago: "That's all in TR1 and in boost nowadays, you old fool!" :) And I am not opposed per se to learn something.
Anyway, lemme shot down Björn's ideas now. I'll be back!
 
In MPL it'd probably be vector + fold I guess boost.org/doc/libs/1_52_0/libs/mpl/doc/refmanual/fold.html
 

« first day (1202 days earlier)      last day (3744 days later) »