« first day (1990 days earlier)      last day (2973 days later) » 

12:00 AM
@Borgleader Heh.
@sehe Status of what?
 
My life in our beloved code base
 
I'm falling asleep. I'm leaving to actually reify that sleep.
See you another day.
 
@Morwenn night
 
@Telkitty Are you attending that? ;)
 
12:05 AM
@Borgleader Thanks :)
 
@wilx no, just posted that because I think it's funny :p
 
@Telkitty Is it?
 
It is funny she thinks it is
 
I should start a meetup group: 'equality for chickens'
but I guess chickens don't use internet much ...
 
user406009
12:50 AM
Eh, people joke about men's rights groups, but they do have some valid grievances.
 
user406009
Parental leave for men, inequality in family court ...
 
user406009
The military draft as well is another big one.
 
Ell
@Telkitty I love the blue eyes
 
I love fur/fluffy feather balls :p
 
1:08 AM
hey all
is this the place to ask for a bit of vote brigading?
(it's harmless, I promise)
 
user406009
@APerson trying to kill a really bad question or answer?
 
user406009
You could, but most of the people here are asleep.
 
I'm trying to bring down a horrible dupe
 
plz dont one box shit for no reason
 
@Borgleader I apologize; I thought it would be helpful
 
1:11 AM
i can click on a link just fine
 
user406009
@APerson eh, I wouldnt bother too much. Both of those are quite old.
 
@Lalaland the reply arrows, they call to you
 
I know; it's just that I feel like it should be cleaned up
 
oh wait, you on mobile m8?
 
user406009
Yeah. I am on mobile.
 
1:15 AM
ah
 
user406009
Which makes replying a pain.
 
1:29 AM
std::tie( ob, A, B, C, D, F, G0, G1, H, I, J0, J1, K0, K1, L0, L1 )
    = lua.get<int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int>(
        "ob", "A", "B", "C", "D", "F", "G0", "G1", "H", "I", "J0", "J1", "K0", "K1", "L0", "L1"
    );
> tfw this code works perfectly
At least I know my framework scales.... ?????
 
user406009
@ThePhD Is it webscale?
 
user406009
Will it run on the cloud?
 
Only if you run it with MongoDB™℠
vOv tests say we're okay
time to compile with g++ and cry hot, kinky tears of sadness
 
user406009
@ThePhD Nice.
 
user406009
@ThePhD For interest's sakes, did clang ever start working?
 
1:33 AM
@Lalaland Never tried it again. :B
 
user406009
That's ok. We all know that gcc > clang anyways.
 
p. much
 
user406009
Don't listen to the LLVM propaganda machine.
 
user406009
We all know what LLVM really stands for. Lies and Lying Verbose Manuals.
 
user406009
/s of course.
 
1:47 AM
hi
 
user406009
@HassenDhia Welcome to the Lounge!
 
@ThePhD Don't run with scissors MongoDB!
 
2:09 AM
@TonyD welcome to Boost Assign gift from a decade ago — sehe 30 secs ago
Good old operator overlording
And please don't call a vector that contains strings and int bools... :( — sehe 6 secs ago
Off to bed. Night all )
 
night
 
Niiighty night.
 
night
 
2:59 AM
My lunch ... mini surf n turf - cooking with telkitty™
 
3:43 AM
@Xeo The ending of Schwarzesmarken makes me rage a bit. I won't spoil anything through.
 
4:06 AM
hi @Mystical
 
 
1 hour later…
5:30 AM
@Borgleader I basically replaced it some time ago, and decided to leave that one as kind of a time-capsule. It has some parts that are pretty much worn out, and replacing them is now a non-trivial prospect, so I decided to just hang it up, and ride a (somewhat) newer one. As to how much I ride: I'd guess the old bike has around twenty five to thirty thousand miles on it. The newer one probably about the same or a little more.
Unlike the older bike, I've kept the newer one pretty much up to date, so the frame's just about the only part that's really old.
 
 
2 hours later…
7:12 AM
@Telkitty Looks yummy.
Morning.
 
fuck its too early for monday
 
morning
 
7:36 AM
I'm trying to write my new year resolution, but my brain isn't cooperating.
 
My new year resolution was 220 DPI
 
 
1 hour later…
user1804599
8:59 AM
New year resolutions are dumb circle jerking.
6
 
@KhaledKhnifer Then don't.
@Zoidberg I agree.
 
@wilx well I'm probably not doing it right either, I'm being too specific
I think it's useless, since most of the stuff I wrote so far are quite obvious
like.. Drink more water daily, Lower sugar consumption, Lower coffee consumption
 
@KhaledKhnifer Why the coffee?
@KhaledKhnifer How many cups of coffee do you drink daily now?
 
9:32 AM
void HelloWorld()
{
static std::atomic<short> static_counter = 0;
short val = 0;

val = static_counter++; // or val = ++static_counter;
}

Ie if it's accessed by two threads, can the local variable val be 1 in both threads?
 
try asking on stack overflow
 
val = statck_counter++; //until it overflows
 
@wilx strong coffee will disturb the ability to focus for long period of time during the day, I'm trying to limit myself to one cup of light coffee in the morning or on occasions.
 
@Telkitty I could have used unsigned int, or unsigned long long, but that wasn't the question
 
Oo ^_^
 
user1804599
9:39 AM
@Phantom no that is impossible
 
@melak47 not becoming a trend, huh?
 
user1804599
Disgusting. Municipalities are sabotaging referendum not only by decreasing amount of voting stations, but now also by not delivering voting passes.
 
9:57 AM
which referendum is this?
 
user1804599
10:24 AM
@Puppy Referendum about NL signing the association treaty between the EU and Ukraine.
 
user1804599
Since the government knows that many people detest EU imperialism, they try to sabotage it in various ways. At least 30% of people allowed to vote have to vote otherwise the outcome is not valid.
 
I'm listening to some music on YouTube, reading the comments when:
> Pornhub brought me here. Literally.
 
user1804599
At the cost of corruption, and animal welfare, and human rights.
 
@Morwenn porn-website jokes on Youtube are starting to rise these days
 
10:42 AM
Hahaha, I finally found why my indirect_adapter<mel_sorter> didn't work: I just forgot to rebuild the relevant test case, so it would still run the one compiled with the faulty algorithm.
I should claim a master degree in dumbidumbness.
 
they don't give 'em out left and right you know
fierce competition
 
Melsort: really efficient but slow as fuck apparently.
~250 times slower than heapsort.
 
@Morwenn is it true that every sorting algorithm reflect a datastructure in which they are the most effective?
 
Not really. Some of them are slow no matter the data structure.
But yeah, some of them can be really more efficient if they take into account the data structure.
 
11:01 AM
@Zoidberg Which line of code do you find more readable?
if (moveRight('\n') == false) break;

if (!moveRight('\n')) break;
 
user1804599
if (!moveRight('\n')) {
    break;
}
 
I have seen people who believe break inside braces breaks from the if ;)
 
user1804599
== false is confusing. As if it's a Boolean that could be null or something.
 
^ agreed
 
How about this?
if (moveRight('\n') != PERFORMED) break;
 
11:04 AM
if (not performed(moveRight('\n')) break;
 
if (!movedRight('\n')) break;
 
love the bikeshedding!
 
then write movedRight function to invoke moveRight, return true if it was moved, false otherwise
 
Anyway, here is the whole function:
private void moveRightWithinRow(int amount)
{
    for (int i = Math.min(amount, afterCursor.length() + afterSelection.length()); i > 0; --i)
    {
        if (moveRight('\n') == false) break;
    }
}
 
11:08 AM
is that like keep shifting to the right the end of string till it reach either the amount place in the string or the afterCursor?
 
perhaps clearer as a while loop if so?
 
@fredoverflow you're biased towards noobs students
#bikeshredding
 
@Zoidberg Why did you make that your new year's resolution (seems you were already quite accomplished?)
@набиячлэвэлиь had to google that :(
 
Why the long face?
 
11:12 AM
Now, finally I know what Doom's (? or was it Duke Nukem) RPG was supposed to be be
 
@KhaledKhnifer Move to the right within a line by the amount. You could hit a newline or the end of the string first.
 
@fredoverflow why not use min(amount, currentPos-lineStartPos) or min(amount, amountFromLineStart)? wouldn't that make more sense?
 
Because the way the text is represented internally, I have no idea where the line breaks are unless I actively search for them ;)
Oh wait, moveRight already checks for end of string! Then it's super simple:
private void moveRightWithinRow(int amount)
{
    for (int n = amount; n > 0; --n)
    {
        if (moveRight(WITHIN_ROW) == false) break;
    }
}
or even:
private void moveRightWithinRow(int amount)
{
    while (amount --> 0 && moveRight(WITHIN_ROW));
}
 
arrow operator
 
5184
Q: What is the name of the "-->" operator?

GManNickGAfter reading Hidden Features and Dark Corners of C++/STL on comp.lang.c++.moderated, I was completely surprised that the following snippet compiled and worked in both Visual Studio 2008 and G++ 4.4. Here's the code: #include <stdio.h> int main() { int x = 10; while (x --> 0) // x goes ...

Why are trivial syntax questions like this so popular?
 
11:27 AM
Still: 143 downvotes.
 
I'm tempted to downvote as well, because 144 is a square number.
 
Actually, considering how much melsort sucks for random values, its adaptative capacities for any hint of order already existing in the collection to sort are quite impressive.
@fredoverflow You can't do that.
Oh wait, I thought it was still locked :o
 
Did you just downvote? :)
 
Did I? :D
 
@JerryCoffin Oh damn, that's a lot of mileage :O
 
11:44 AM
I settled with a less trolly solution:
private void moveRightWithinRow(int amount)
{
    while (amount > 0 && moveRight(WITHIN_ROW))
    {
        --amount;
    }
}
 
clearer imo
 
Xeo
wheee, mini-me!
 
12:02 PM
Hello!
 
7 messages moved to bin
 
Back to learning sockets.
 
54
Q: Humans can now run 40 mph. How do I keep the stupid people alive?

TrEs-2bLet's assume that humans can now run 40 mph and the human body can handle it. I know and understand that this is not feasible, but let's just play pretend. Naturally people would have all kinds of fun, but as we all know most people are idiots. I imagine that there would be millions of people who...

wtf
 
nwp
worldbuilding has some neat questions
there is a variant where people can fly
but the answers are boring, basically "Darwin will sort it out" and "not much will change"
 
12:45 PM
@Borgleader I don't ride nearly as much since I got married, but when I was single, I rode quite a bit. For years in Colorado Springs, this was my normal Sunday afternoon ride (well, that was half of it--then I had to run around and ride home).
 
BREAKING: Senator's bold pro-podium stand leads to primary challenge from prescriptivist base.
2
 
Xeo
wheeee
 
1:21 PM
@JerryCoffin Ohhhhh that looks gorgeous, full of montains and wooded areas.
 
I have not ridden a bicycle at all after I lost half a tooth to a piece of rock while mountain biking
 
So I came to this chatroom expecting discussion on C++, instead I get screenshots of games...
 
You must be new here
 
Yes, I just recently got enough reputation to chat
 
Xeo
@Isaac How strangely relevant your username is, in this case.
 
1:24 PM
What about it is relevant?
 
@Borgleader And so it is--which is a good thing, because it's also a serious grind (something like 4000 feet of elevation gain). Something pleasant to occupy your mind is definitely a good thing.
 
@JerryCoffin Oh wow, tell me you climb on the way there as opposed to when you get back
 
I am amazed at the lacking of multi-day tracks near Denver, because I thought where they are mountains, there will be trails
 
Xeo
@Isaac The game is called "The Binding of Isaac"
 
@Xeo Ahh, I've heard of that, unfortunately I didn't like it's visual appearance :(
 
1:27 PM
@Borgleader Yes, definitely (though on the way back, here was still one fairly serious climb).
 
@ScarletAmaranth what is?
 
@melak47 check the conversetion going on then
 
ohhh. :D
 
@Telkitty They definitely exist--not sure why you would have had difficulty finding them. The most obvious/best known would probably be the Colorado Trail. If you want truly long distance, go for the Continental Divide Trail instead.
 
@melak47 it is definitely becoming a trend
with telkitty supporting it I am not one bit surprised, but unfortunately also other people indulge, looking at you funny @JerryCoffin
 
1:40 PM
@ThePhD hm so would the auto typename thing allow perfect forwarding of templates? template<template<auto Args...> typename T> :D
 
@JerryCoffin the first one is a mountain biking trail while the second one is not well documented on the internet ...
By looking at the info, I would not mind doing the first one on a mountain bike
 
user1804599
2:03 PM
How do you make a raw UTF-32 string literal?
 
just combine all the things
 
user1804599
oh UR""
 
user1804599
ok
 
2:29 PM
UR"(so fucked)"
 
Wow, bad bad me.
 
wait.... a mintue lol, the line ends are specified in this code, I'm just being dumb (I think) ... nvm, they are set correctly, something else is wrong
 
@GiantCowFilms open the file in binary mode to avoid line ending shenanigans
 
@melak47 how do I do that
 
2:36 PM
@ScarletAmaranth I did it again! I'm sorry
@GiantCowFilms you're using C style file I/O, so I dunno :D
 
Managed to find the answer :D
@melak47 Thanks for the help!
 
user1804599
3:15 PM
Nasty code of the day: lpaste.net/7039733221013061632
 
3:26 PM
@Zoidberg why does object::begin() skip sizeof(object) chars after this?
how is this used? struct something : object { object* arr[field_count]; }; or something?
 
Random question, if my answer to an SO question is completely wrong, should I delete it, or simply edit it to tell everyone that it is wrong?
 
If it's not yet that popular (no comments and very little upvotes), and you can't fix it, I think you should remove it
 
deleting it is the best outcome
 
@Isaac If you can provide a better answer than any other there, edit it to do so. Otherwise, delete.
 
3:39 PM
All the other ones don't work either :(
 
@Isaac Can you write one that does work?
 
@Jerry I spent quite some time trying, but in the end I just gave up.
I feel like I'm missing something really simple...
 
@Isaac Can you link the question here? I'm starting to get curious about it.
 
@Jerry I somehow didn't read one of the other answers, and it works, so mine is pointless, I'll delete it now
 
user1804599
@melak47 objects are layed out as two integers followed by two arrays of runtime length
 
3:49 PM
why two? :D
first one is pointers to objects (fields/members?), what's the other one
 
user1804599
The first one is pointers to GC-managed objects (e.g. car and cdr in a cons cell). The second one is arbitrary data not GC-managed (e.g. code points in a string).
 
and object doesn't know it has these array members?
 
user1804599
You can't do that in C++.
 
oh, is this like a struct string { int len; char[1] buf; }; kinda deal?
 
user1804599
object has a private ctor and friends GCs.
 
user1804599
3:56 PM
struct object { std::size_t field_count, data_size; };
 
user1804599
operator new(sizeof(object) + sizeof(object*) * field_count + data_size)
 
@Xeo I do not know what am I looking at?
 
Xeo
@wilx OP run in Binding of Isaac
 
@Xeo OP?
 
Xeo
Overpowered
 
4:04 PM
@Xeo Oh. OK.
 
Xeo
aka found increadibly good stuff and had a good run
 
4:29 PM
you found my face?
 
user1804599
4:45 PM
s/found/pound/
 
5:03 PM
Dang.
Boost has join
template<typename SinglePassRange1, typename SinglePassRange2>
joined_range<const SinglePassRange1, const SinglePassRange2>
join(const SinglePassRange1& rng1, const SinglePassRange2& rng2)
I need
template<typename SinglePassRange1, typename SinglePassRange2, ...>
joined_range<const SinglePassRange1, const SinglePassRange2, ...>
join(const SinglePassRange1& rng1, const SinglePassRange2& rng2, ...)
 
@Xeo Not as much OP as "mid-tier Lilith run"
 
Xeo
Anything that allows me to basically just stand there and own anything counts as OP for me
I really like Lilith's mechanic with the familiars
 
I like how { scope } even if the block doesnt belong to a function
Is it bad practice if I use that to my advantage? o-o
 
She's that op just once at Boss Rush, so meh
But Car Battery + Battery + Box Of Friends synergy is dope
 
Xeo
ye
car battery is evil
 
user1804599
5:14 PM
@ReousaAsteron no
 
Awesome
 
Xeo
@набиячлэвэлиь as in, awesome
 
Xeo
the charged baby is also nice
 
user1804599
5:15 PM
Use it to prevent accidental use of a variable when it shouldn't be used anymore. Also use it to control when destructors are called.
 
@caps ...so you need fold.
 
@Zoidberg Yarr, I was thinking of also using them to let unique_ptr know when to destroy its self
 
user1804599
unique_ptr doesn't destroy itself. It destroys the pointee. } destroys it.
 
user1804599
} is the destruction operator.
 
April Open Beta /cc @slaphappy @Nooble @melak47
 
5:25 PM
:v
 
@Zoidberg Yeah that's what I meant
 int *ptr;
{
std::unique_ptr<int> p(new int);
ptr = p.get();
*ptr = 5;
std::cout << *ptr << "\n\n";
}
std::cout << *ptr;
took it for a spin, it's pretty neat.
 
@Zoidberg foo.}(); :D
 
#define } delete
 
@ReousaAsteron Not bad practice at all.
@Griwes Yes.
 
5:58 PM
So, my hard drive 62% full a while ago and now it's only 49% full without doing anything. What Windows stores to rollback updates is quite heavy.
 
6:11 PM
@Feeds Hard to imagine anybody not knowing this immediately. The podium is basically the stage--the little raised area you stand on so you're visible to the entire audience. The thing in front of you with the sloped top for holding a book, notes, etc., is a lectern.
@Morwenn It would be a lot heavier if you had to store it on 360K floppy disks!
 
@JerryCoffin Why would anyone ever do that?
 
@Morwenn For that information, I can't quite imagine anybody doing it. At one time, we stored our data on floppy disks, because we didn't have a whole lot of choice. I can remember when a (10 megabyte) hard drive cost about as much as a new car.
 
6:25 PM
> 9. The Queen has the word "plonk" in her vocabulary.
 
@caps but it doesn't scale. at all
 
Xeo
wtf. my download speed seems to have taken a sharp dive
1mbps... that's... 1/50th of what it should be
upload speed is still fine
 
Surprisingly, Cristina Ramos liked my tweet
 
Maybe she likes bears.
 
6:41 PM
Landed, BUD.
Things liek tath so tempt to respond with "I'm not your homey, BUD"
@StackedCrooked oh man. he really sticks it out
 
yeah he does
 
In the second part he almost blows his cover :)
 
6:56 PM
@Puppy The migration process is complete, I replaced the gap buffer with a persistent char vector zipper :)
 
posted on March 28, 2016 by Scott Meyers

Et Voilà! The French edition of Effective Modern C++ has just arrived at my desk, so it should be available for you, too. This version of the book uses only one ink color (black), so if you're comfortable with technical English, I suspect you'll prefer the four-color English (American) edition. But if you like your C++ in French (including the code comments!), this new edition is your am

 
I'll probably have to record a video about this to get the excitement out of my system ;)
@Feeds The French version doesn't have "modern" in the title, weird.
 

« first day (1990 days earlier)      last day (2973 days later) »