« first day (1137 days earlier)      last day (3805 days later) » 

6:00 PM
DAFUQ CHAT I DIDN'T PRESS ENTER
 
Your Enter gained sentience
 
Xeo
Apparently you did while trying to erase the ,
 
Don't leave any sharp objects near the keyboard
 
@melak47 This happens to me sometimes :\
 
Xeo
@melak47 No, we said you sucked. :P
 
6:01 PM
@Mysticial I am not familiar with the editing process. What is an audit message? Is this just the user-input reason for changes? (sort of like in version controls commits)
@ScottW you any good at AI?
 
@Pawnguy7 Ah, you've never been in the suggested edit queue. It's the message you leave when you make or suggest and edit.
 
@ScottW well, there are definitely levels of bad.
 
@Pawnguy7 When you're reviewing suggested edits, the system inserts a few (fake) bad edits, to make sure you're actually reviewing the suggested edits, not just going through the motions to get a badge.
 
And what it makes sure of is that you're paying attention to whether you're getting audit edits
They're usually pretty obvious
 
How are these fakes generated?
 
6:07 PM
@CatPlusPlus True -- but people who are just going through the motions often aren't paying any attention at all.
 
@ScottW I have been working on AI for snake
 
@Pawnguy7 As @Mysticial already say, mostly by copying edits that have already been rejected as bad.
 
@Xeo What exactly do you mean by that?
 
I once picked wrong answer on audit edit
 
Xeo
@FredOverflow Content- / explanation-wise
 
6:08 PM
I was rejecting it because it was terrible, but the correct answer was accept or something
 
@Xeo So some of the stuff he says is actually wrong?
 
Xeo
Not wrong per-se, but misleading rather
 
@Xeo aw :(
 
Xeo
well, he calls Just and Nothing "type constructors" all the time
so I guess he does say wrong stuff
 
@JerryCoffin I wasn't sure how you take what makes one edit bad, and apply it to different content
 
6:09 PM
@CatPlusPlus A few times I've picked the "wrong" answer -- usually clicking to improve, when the edit was clearly bad, but the post also needed editing.
 
I so do not bother with that :v
 
@Pawnguy7 Doing it well would probably be difficult, which is part of why (as @CatPlusPlus already commented) they're usually pretty obvious.
 
mwuahaha, it works!!1!
 
@Pawnguy7 The secret is that all edits are bad
Haven't eaten sushi in a while
 
6:11 PM
@Xeo Just is a type constructor. You give it a type, and it gives you back a type.
 
Xeo
@FredOverflow No
Maybe is a type constructor
 
It's data constructor
 
Xeo
Just and Nothing are data constructors.
 
6:11 PM
@ScottW eh... they kill themselves with disturbing frequency.
 
Oh right. Brainfart on my part. Brainpart.
 
thanks to my colleague this tune keeps repeating in my head
 
@melak47 WTF is AngelScript?
 
@ScottW basically what I did. But looking one ahead does not end well.
And even looking ahead more in a recursive fashion, the problem is the movement of the other snakes.
 
@FredOverflow a scripting language with a terrible C++ API :D
 
6:15 PM
@melak47 what's the point of static_print?
 
I have concluded that they must be taken into account somheow.
 
@StackedCrooked to see if binding a static member function as a global script function works :)
 
@melak47 Well, at least it seems to support lambdas.
 
@FredOverflow hehe, yeah, right. cough
 
@ScottW See A and B
 
6:16 PM
Wait, does it support stateful lambdas?
 
I wonder if there are people that use the "blue" colorscheme.
 
@FredOverflow it supports member function pointers and instance pointers. :p
 
@StackedCrooked I think I do. You're talking VS, right?
 
I have improved it slightly since then, but not enough.
 
@FredOverflow Vim :)
I mean Vim.
 
6:17 PM
You seem to forget.
They kill themselves.
Like, it is annoying how fast, because the human doesn't have time to do anything.
 
@FredOverflow what you see in that screenshot are my wrapper functions that allow lambdas, and automagically produce a string of the desired function signature so you don't have to do it :E
 
This is without any humans trying to trap them.
 
@StackedCrooked Nobody who's intelligent would. But then, nobody who's intelligent would use vim, regardless of color scheme. <GD&R>
 
You moron.
Stupid moron.
 
The Vimpire strikes back.
 
6:19 PM
what is vim?
 
He didn't see that coming.
 
@Abyx A false prophet of editing, worshiped by idolaters, hated by all others.
 
@ScottW what I was thinking was, get a list of all squares enemies can reach within 2 moves, and add these as.. negative points. More negative the closer it is to the enemy. In this way, they would play more defensively, and hopefully not go into very close situations which always kill them.
 
@StackedCrooked So I take it you don't know what "<GD&R>" means?
 
goes ducking & runs?
 
6:22 PM
@FredOverflow Close. "Grinning, ducking, and running"
 
yeah I heard there was a text editor with that name, but noone use it right?
 
@JerryCoffin First time I see this.
 
This is so Usenet
 
@Abyx Some do, but by doing so show themselves to have such poor taste that their opinions must all be discounted as meaningless.
 
Ell
6:26 PM
why didn't I invest in bitcoin :'(
 
@CatPlusPlus Not at all certain, but I believe this particular one actually originated on Fidonet, and migrated from there to Usenet.
 
@StackedCrooked was that new to you?
 
@bamboon no
 
@StackedCrooked you made me wonder ^^
 
How can I generate a std::string which contains the sequence of all printable characters? I.e. from space (0x32) up to '~'.
In a nifty way.
Because I know how to write a for loop :)
 
6:35 PM
That's not all printable characters
 
Isn't it?
 
@StackedCrooked Assuming they're contiguous, std::iota. std::string printable('~'-' '); std::iota(printable.begin(), printable.end(), ' ');
 
CR & LF are considered printable. Also BEL, I guess.
 
@JerryCoffin Thanks I'll check out std::iota.
 
> error C2587: 'Else' : illegal use of local variable as default parameter
what the hell :E
 
6:39 PM
@melak47 else is all lower-case.
 
Maybe he has an 'Else' var, or a macro, (either horrible).
 
0
Q: How do I print what I see on the screen/debugger with as few lines of code as possible?

user2881079hello I have a c++ program that my class group for C++ are working on. It is due in 7 minutes. How do I print what I see on the screen/debugger with as few lines of code as possible?

7 minutes you say.
 
6 minutes now
somebody please help him!
 
@chris .model tiny\nmain proc\nint 5h\nmain endp\nend main (works for MS-DOS).
 
6:42 PM
Lines of code?? Cntl-Alt-PrtSc ?
 
how does this constexpr stuff work :E
 
@melak47 Pretty nicely, IMO.
 
@JerryCoffin any chance what I'm doing here is gonna work? :p
 
@StackedCrooked How do you like the following solution?
std::string s(126, 1);
std::partial_sum(s.begin(), s.end(), s.begin());
s.erase(0, 31);
 
I ended up with this:
std::string t('~' + 1 - ' ', ' ');
std::iota(t.begin(), t.end(), ' ');
@FredOverflow Thanks, now I need to check out partial_sum.
 
6:44 PM
Oh, and I didn't know / forgot about iota :)
 
@FredOverflow Hey, that's clever :)
 
user1804599
Go’s iota is cooler.
 
is there no way to do if then else with constexpr? :/
 
user1804599
?:.
 
@melak47 return x == y ? yes() : no();
 
6:45 PM
derp. lol
 
In C++14 if/else will be allowed.
And for loops as well.
 
why isn't someone throwing "the standard doesn't guarantee that any characters are contiguous besides 0-9" in @StackedCrooked face?
 
I wouldn't care anyway.
 
@StackedCrooked not just for loops, any type of loop will be accepted
 
@StackedCrooked So we don't get to show off our recursion skills :3
 
6:46 PM
@Polymer yeah, it's a pity
 
Ell
@StackedCrooked static if?
 
user1804599
Make everything constexpr!
 
de facto standards > official standards
@Ell no, that's something else
 
how do I know if constexpr is working? :D
 
static if was rejected
@melak47 use the return value to instantiate a template
 
6:48 PM
@melak47 define "working"?
@StackedCrooked use the return value in a constant-expression is a far better way to put that
 
user1804599
if (true) { // after optimisation this is static if :D
    foo();
}
 
template<unsigned n> struct value{}; value<my_test(3, 4)>();
@refp sorry for not meeting your standards :P
i'm just a chump
 
user1804599
@StackedCrooked What if its return type is not an integral type?
 
@StackedCrooked no worries mate.
I'm just black.
 
@rightfold then it won't compile
now I want a constexpr malloc
:P
 
6:50 PM
Fucking bullshit, train was 50 min late this morning, so I got to my 3h class 1h late. Teacher finished 1h early. >.<
 
@refp is that you in the pic?
 
@bamboon what would you like the answer to be?
 
user1804599
@StackedCrooked In that case I never got the point of constexpr constructors. :v
 
@bamboon that is me in the pic, and yeah.. I'm more brown than black
 
@refp I don't care, I would just find it funny if it was and you wouldn't look very swedish.
 
6:52 PM
@ScottW I left my house at 7:50AM got to class at 10:30AM
T_T
 
@bamboon it is me. born and raised (partly) in sweden. swedish father + mother from senegal = refp
 
Xeo
@rightfold Nope
 
user1804599
@Xeo It was a bad joke.
 
@refp Ah ok
 
user1804599
I know the difference in semantics.
 
Xeo
6:52 PM
Your joke was rejected on the grounds of badness.
 
@ScottW Not that far but public transport here sucks fucking balls
 
user1804599
> Lisp is shit.
> If it ain't Lisp, it's crap.
 
How can you implement a debugger without UB? (It typically needs to be able to inspect uninitialized memory.)
 
@StackedCrooked don't write your debugger in c++; done.
 
@refp which cool companies are there in Stockholm besides Spotify?
 
user1804599
6:54 PM
@StackedCrooked By writing the otherwise UB parts in assembly.
 
@bamboon I wouldn't know, I work as a model.
 
@StackedCrooked try/catch all the things ;)
 
Hm, I guess the debugger runs in a separate process. So that makes it outside of the realm of C++ anyway.
 
user1804599
@StackedCrooked By initialising the memory.
 
@refp rofl lol what? On the other side, the picture makes sense now ^^
 
6:55 PM
@rightfold how do you know it's uninitialized :)
 
@refp Because we're pretty sure he's not using EBCDIC.
 
user1804599
@StackedCrooked By being an interpreter instead of an observer!
 
idk
 
user1804599
@ScottW Indeed. We’ll have to change the C++ standard such that MSVC follows it. Then it’ll be good.
 
@ScottW I think you have a twist there, the standard is good, MSVC is terrible
 
6:57 PM
@JerryCoffin I'm a language-lawyer; bite me.
 
I've been thinking that percent-encoding is a nice way to escape strings. It replaces the special characters instead prepending an '\' or something. This makes it easy for tokenizing and splitting on single characters.
 
@ScottW probably, if you say so
 
@refp You're a wannabe language-lawyer. I'm one of only two real language lawyers.
 
@JerryCoffin lol
 
hmm do you think typeid will work in constexpr? :D
 
6:59 PM
@melak47 no.
 

« first day (1137 days earlier)      last day (3805 days later) »