« first day (744 days earlier)      last day (4210 days later) » 

Xeo
7:00 PM
It's really helpful having those standard guys lurking on SO. :>
I really like how unique_ptr deals with self-assignment, though. this->reset(other.release()).
 
@Xeo Haha, nope. It doesn't deal with it.
> the implementation may assume that this parameter is a unique reference to this argument
 
Xeo
@R.MartinhoFernandes Okay, it doesn't deal with it specifically. It just does the above in the move-assign operator and it works for self-assignment.
 
if(this == &other) std::ub();
this->reset(other.release());
return *this;
// valid
@Xeo Unless it specifies that it must work for self-assignment, the implementation is still free to make the non-aliasing assumption.
Obviously, only Hell++ would ever do such a thing.
 
Xeo
Heh
Btw, I wonder why the OP said that the v = std::move(v); deals also with self-move assignment of T, it does not.
 
it'd be interesting to have a compiler/library that was like a super-debug thing, for catching as much UB as possible. Just for testing, not for releases.
 
Ell
7:05 PM
"However, given a finite amount of time, a Turing machine (like a real machine) can only manipulate a finite amount of data."
why? Can't it just keep moving the tape in one direction and changing the symbol?
@R.MartinhoFernandes why is it not specified to work? some optimisation? o.O
 
@Xeo he probably assumed it moves the internal Ts.
 
Xeo
@Ell You can only move the tape so far in a finite amount of time.
 
Make more time!
 
Ell
ahh darn I read finite as infinite
 
Xeo
@Ell Sure, the optimization being that you can leave out the if(this == &other) check
 
Ell
7:06 PM
but then you will self assign o.O so surely it's not an optimisation if it means the side effects will be different?
 
this->reset(other.get());
other.ptr = nullptr;
return *this;
// not as machiavellic, still ok
 
Ell
If we wanted to write a rule table for a turing machine of a simple for loop for(int i =0; i <10; i++)
 
Xeo
auto p = other.get();
other.ptr = nullptr;
this->reset(p);
return *this;
would be the correct long form of this->reset(other.release())
 
Ell
and each time, it moves the head right and prints a 1 to the tape or whatever, then would it need 10 states?
 
Xeo
I wonder if for vector you could just do exactly the same thing?
 
7:14 PM
My precious rep :(
 
Xeo
tuple<T*, T*, T*> _Release(){
  auto t = make_tuple(first, last, end);
  tie(first, last, end) = make_tuple(nullptr, nullptr, nullptr);
  return t;
}

void _Reset(tuple<T*, T*, T*> t){
  this->clear();
  tie(first, last, end) = t;
}
Any errors?
 
I have no idea what that is.
 
Xeo
The this->_Reset(other._Release()) implementations for vector. :P
 
(To be honest, I prefer first = last = end = nullptr.)
 
Xeo
@R.MartinhoFernandes Derp, right.
 
7:21 PM
Looks fine from here.
 
Ell
first = last = end = nullptr looks weird
 
Xeo
Probably less efficient than the naive this->clear(); this->swap(other); due to the pointer copies, though.
But heck, who cares about three damn pointers?
 
Game developers.
 
Xeo
o_o
 
Ell
do game developers have the reputation for optimising to high heaven and beyond?
 
7:25 PM
(I'm not being serious; I'm using "game developers" as a demeaning term)
 
Xeo
Guessed as much.
 
Oh, wait, I almost forgot what @Xeo is going to work on.
Sorry.
 
You still in Berlin, btw?
 
Xeo
Yes. :(
 
7:26 PM
Wanna meet before you leave?
 
Game developers are actually above average.
 
Xeo
You in Berlin now too?
 
I arrived some hours ago.
 
Awesomeness.
 
Xeo
Cool.
Sure, why not. I don't know about this week, though, since I don't know when I'll have to travel to the other end of Germany again to actually get the job center stuff going (getting them to pay the first two month in the flat etc)
 
7:29 PM
@Ell yes
 
Xeo
Anyways, time for dinner.
 
Ell
anyone heard of monolith before?
"munging" two files together to remove copyright ownership or something
"For example, munging two copyrighted files will produce a completely new file that, in most cases, contains no information from either file. In other words, the resulting Mono file is not "owned" by the original copyright holders (if owned at all, it would be owned by the person who did the munging). Given that the Mono file can be combined with either of the original, copyrighted files to reconstruct the other copyrighted file, this lack of Mono ownership may be seem hard to believe."
 
@Ell no, and it's not one of the 6 "computer" pages on the disambiguation "Monolith"
 
Ell
it looks like encryption to me. I'm confused
 
@Ell I think this person has a faulty understanding of the copyright system
 
Ell
7:33 PM
me too
 
@Ell seems to be, yes
 
Ell
it seems all the programme does is XOR the two files
 
copyright holds over works derived from an original, so this "Monolith" is completely wrong in all his assumptions.
 
Ell
"Some people would argue that, since I used the "Toxic" MP3 to create the Mono file, the Mono file is a derivative work of Spears' song"
"But what constitutes a derivative work? Certainly, some part of the original work must be present in a recognizable form. The munging done by Monolith leaves no part of the original work in place, so Mono files therefore cannot be counted as derivative works"
 
"Certainly". Welp, guess there's nothing we can say here.
 
Ell
7:37 PM
ugh oh. My fan is making a weighted hum
is that usual? aka, sounds like one side of the fan is heaver so its making like a rectified sin wave as opposed to constant humming
n'awww look at sehe: i.minus.com/iBjggllWTYF0I.gif (3.5 mb)
3
 
@Ell Copyright Act are relevant, also. 17 U.S.C. § 102(a) "Copyright protection subsists, in accordance with this title, in original works of authorship fixed in any tangible medium of expression, now known or later developed, from which they can be perceived, reproduced, or otherwise communicated, either directly or with the aid of a machine or device."
 
Ell
I'm going to email him
 
@Ell But what use actually is the resulting file?
 
Ell
@DeadMG well you can de-munge it if you are given the element file
 
... ... and?
there's no point having a non-copyrighted file that has no use except to produce another file that is completely copyrighted
 
Xeo
7:46 PM
Yay, instant ramen with eggs.
 
@DeadMG he says given a copywritten file, he can munge it (legally) into a non-copywritten file, distribute that (legally), and then people can (illegally) demunge it in privacy back to the original copy-written file.
He says it's a legal way to distribute copywritten materials.
 
no more legal than The Pirate Bay
you're still intentionally permitting your end users to commit copyright infringement by serving them data which they can use to gain copyright material.
 
@DeadMG if he's right, then that is correct. However, he's not right. What he's doing is actually covered by US copyright law as illegal.
 
fuck US copyright law
 
@MooingDuck Maybe he's not American.
 
Ell
7:50 PM
I don't see how the pirate bay exists. How is it legal?
 
@Ell Does it have to be legal to exist? No.
 
Ell
oh right. derp.
 
@Ell D'awwwwwwwwwwwwwww
 
@EtiennedeMartel he quotes US laws on the site
@Ell it doesn't distribute copywritten information. It tells people where to find copywritten information, which isn't illegal in many places.
 
Ell
you mean because a torrent doesn't contain the data?
 
7:52 PM
precisely
 
Ell
hmm
I wonder why it has been blocked in the UK then
 
@Ell Because it is illegal in most places ;)
 
Ell
oh :P
 
If I may offer a crude analogy, the pirate bay doesn't sell you drugs, it tells you where to find the person who can sell them to you
 
Ell
just not sweden :L
 
7:53 PM
@Ell I think TPB tries to jump into many loopholes as possible. The fact they it's a Swedish site might help.
 
The "I only link to the copyrighted material" argument usually doesn't go well in court ;)
 
@MooingDuck I'd say he's wrong. Not only in the US, but essentially all countries that are signatories to the Berne convention, a copyright covers not only the original work, but any derived work. Munging in a way that can be converted back to the original would almost certainly qualify it as "Derived".
 
Actually, the laws he quotes don't say what he claims they do
@JerryCoffin he keeps saying over and over "its not recognizable", and none of the laws require it to be recognizable.
 
Yeah, then any kind of encryption would be enough to skirt all copyright laws.
 
"The exclusive right of the owner of copyright in a sound recording under clause (1) of section 106 is limited to the right to duplicate the sound recording in the form of phonorecords or copies that directly or indirectly recapture the actual sounds fixed in the recording." -From the Monolith website
 
7:56 PM
And his munged file certainly recaptures the sounds (otherwise he could not get anything out of it)
They need a theory of information class.
The assertion that the munged file contains no information from the originals, which is at the basis of the argument, can only be borne from ignorance.
Does an MP3 recoding contain any information from a FLAC original?
 
is steam down?
 
Ell
I'm having fish and chips and curry sauce soon :3 :P
 
@Mysticial Working here.
 
hmm...
now it seems to work...
 
@Ell It's not especially legal, but they use every trick in the book to avoid being caught and shut down.
 
user142019
8:07 PM
@DeadMG use Cygwin, obviously.
 
@Cicada @kbok @LucDanton Fascinant.
 
@Mysticial Given a chance, steam usually rises. Cretins say it's something about heat, but those in the know realize it contains phlogiston.
 
Cygwin is le terrible
 
user142019
You are le terrible
 
@JerryCoffin Depends on what kind of steam.
The ones from liquid nitrogen containers fall down.
 
user142019
8:09 PM
Steam doesn’t rise in a vacuum.
 
Then when they warm up, they rise again.
 
@Mysticial I guess that's all right -- at least as long as they don't skin their knees when they fall down. Sucks when that happens.
 
@JerryCoffin Speaking of Steam and phlogistons... wiki.teamfortress.com/wiki/Phlogistinator
 
@EtiennedeMartel Damn. Beat me to it.
I actually thought Mysticial was going to point it out.
 
lol, that didn't even cross my mind...
there's sooo many items in TF2...
 
8:14 PM
But that's like, the best pyro weapon.
 
I do have one of those. But it's buried deep in my backpack.
 
@Zoidberg'-- How do you get steam in a vacuum, smart ass? You take all the steam out?
 
I have yet to play pyro. I'm kinda going one at a time. Getting good with each class before I move on to the next.
 
@EtiennedeMartel Yup, 100% intentional on my part. Really! Well, okay, not really. :-)
 
lol, Jerry is secretly a TF player.
 
8:17 PM
@Mysticial how is your PhD doing?
 
@bamboon I still don't know the results of the qual.
 
Why is that picture of my rep loss starred?
 
It's leaning heavily towards fail. But meh... I stopped caring a while ago.
 
@Zoidberg'-- Of course not -- if you put in steam, it's not a vacuum any more.
 
user142019
So my statement is still valid.
 
user142019
8:18 PM
A vacuous truth is a truth that is devoid of content because it asserts something about all members of a class that is empty or because it says “If A then B” when in fact A is inherently false. For example, the statement “all cell phones in the room are turned off” may be true simply because there are no cell phones in the room. In this case, the statement “all cell phones in the room are turned on” would also be true, and vacuously so, as would the conjunction of the two: “all cell phones in the room are turned on and turned off”. More formally, a relatively well-defin...
 
@R.MartinhoFernandes link to that deleted answer?
 
@R.MartinhoFernandes was just curious
 
@R.MartinhoFernandes Well, maybe I would be if I knew what TF stood for. Oh, now I see it in the URL -- Team Fortress.
 
Reminds me of one of my friends, who claimed his pen was an effective elephant repellent because there were no elephants around it.
 
user142019
8:19 PM
Like all properties apply to all elements of the empty set.
 
@Mysticial you will be fine anyway
 
@R.MartinhoFernandes Since that has more than +3. Wait 60 days undelete the answer. Do a rep-recalc. And delete it again.
 
@R.MartinhoFernandes Welcome to Germany
 
If I had to guess a good place for a bug, that'd be one.
 
In C++ can you actually pass char matrix[2][4] to a function expecting char **matrix?
 
8:21 PM
@Zoidberg'-- It's not hard to craft a property that doesn't apply to any of them: exists(x).
 
1
Q: cannot convert `char (*)[((unsigned int)((int)Tlength))]' to `char**

Ahmet Melih BaşbuğI have a question in my codes. Can anyone help me? void print(char S[], char * * path, int i, int j) { if (i == 0 || j == 0) return; if (path[i][j] == 'c') { print(S, path, i - 1, j - 1); cout << S[i]; } else if (path[i][j] == 'u') print(S, path, i - 1, j); ...

 
@Mysticial What for?
 
My guess is that you can't.
 
user142019
@R.MartinhoFernandes what are you going to apply that property to?
 
@Chimera Not usually, no.
 
user142019
8:21 PM
To nothing?
 
user142019
You cannot apply a property to nothing.
 
@R.MartinhoFernandes Just to see if there's a bug in the rep system. :)
 
@JerryCoffin That's what I thought. So I look at the answers being given and I don't see that being mentioned.
 
user142019
3 mins ago, by Zoidberg'--
A vacuous truth is a truth that is devoid of content because it asserts something about all members of a class that is empty or because it says “If A then B” when in fact A is inherently false. For example, the statement “all cell phones in the room are turned off” may be true simply because there are no cell phones in the room. In this case, the statement “all cell phones in the room are turned on” would also be true, and vacuously so, as would the conjunction of the two: “all cell phones in the room are turned on and turned off”. More formally, a relatively well-defin...
 
8:23 PM
@Zoidberg'-- Read my sentence again. Then consider that article. Then read my sentence. Then consider that article. Repeat until you get it.
 
> Compounding it is how multi-dimensional arrays do not behave this way- only the first dimension can decay this way. The other dimensions cannot.
 
Argh... TF2outpost is overloaded right now... Must be all that Halloween celebration stuff.
 
@Chimera no
 
4
Q: C++11: std ref global variable and non-function-local thread_local initialization order?

Andrew Tomazos - FathomlingGlobal variables in C++11 with non-trivial constructors are constructed before the entry to main during a static initialization phase. Likewise non-function-local thread_local variables are constructed during a per-thread "thread_local initialization phase". Does the C++11 standard specify in w...

title wtf?
 
@bamboon Thanks.
 
8:26 PM
@bamboon whoa. took me several tries to parse
 
Insects live in such a fascinating world filled with alien landscapes and monsters.
 
@EtiennedeMartel "Père de famille" regarddesapprobateur.jpg
 
@Mysticial sorry about the gratuitous use of templates in my sample earlier. My tests usually start out simple, but then I my obsession for reducing duplication kicks in and I end up with a incomprehensible monstrosity (a highly granular one at that).
 
@rogcg Beautiful photograph. Do you know the source? What lens/camera was used? Macro lens?
 
8:35 PM
@StackedCrooked Or rather your attempt at avoiding code-duplication made the code longer. :D
 
@Chimera maybe you can see his profile and check which lens/camera he uses, or ask him
 
signup.goatse.cx/?lrRef=5gZWA (Perfectly SFW, not shocking content at all; I swear!)
 
goatse.cx
 
@Mysticial That sometimes happens :S
 
@rogcg thanks for the link...
 
8:36 PM
np
 
@R.MartinhoFernandes That's disgusting! Such awful color combinations on that page.
 
@R.MartinhoFernandes I... but... I don't trust you that much
 
@MooingDuck :(
 
@StackedCrooked The real issue isn't with duplication or templates. It's actually putting the burden on the compiler.
 
@LucDanton Ooooh, que de jugement.
 
8:39 PM
Yes, those functions are trivially inlinable, but it's still an extra layer that the compiler must do.
 
@Mysticial std::cout << "memcpy: " << benchmark(test_memcpy(), counter) << " ms" << std::endl; => The string "memcpy" and the name "test_memcpy" are duplicated. I should only pass the object and print it's name using demangling.
 
Which is extra room for weird performance effects.
 
@Mysticial That's what those work beasts are supposed to be doing. If they don't, whip 'em.
@MooingDuck Have I ever lied about SFWness of any link I posted?
 
@R.MartinhoFernandes For production code yes. But for micro-benchmarking, you wanna get rid of as many factors as possible.
 
@R.MartinhoFernandes Should I remove that ?lRef attribute from the URL?
 
8:41 PM
@EtiennedeMartel No idea. That's how I found it.
 
@EtiennedeMartel "Enraged monster hogs gore 4-year old and 6-year old children to death before the eyes of their father."
 
@R.MartinhoFernandes how should I know? I don't click anything suspicious
 
@EtiennedeMartel It works without it.
@LucDanton Yeah, happens with dogs too.
 
@R.MartinhoFernandes With the benefits of some thousands of years of domestication, I would think.
Hogs, dogs, doesn't matter. 'Feral' is the crux of the matter.
 
From what I read, they're not feral. If they were, they could be released to the wild.
 
Ell
8:44 PM
mmm sausage
 
Xeo
-5
Q: C++ STL datastructures compared to Java

trevor-eI'm currently learning C++ and trying to get used to the standard data structures that come with it, but they all seem very bare. For example, list doesn't have simple accessors like get(index) that I'm used to in Java. Methods like pop_back and pop_front don't return the object in the list eit...

Can we get this reopened?
 
Why?
 
Xeo
It may sound biased, but it's perfectly answerable and definitly not "not constructive".
 
@R.MartinhoFernandes I'm not super up to par with the terminology tbh. But I'd wait some generations before calling the offspring 'domesticated'.
On the other hand for all we know the children of the guy might all be 18+ and have moved out since that article was published. Who knows.
 
@EtiennedeMartel are you saying he was wrong about that?
 
8:48 PM
@Cheersandhth.-Alf Well, he wasn't right, which is pretty much being wrong, in maths at least.
He was in CS, so he's used to those kind of dichotomies.
 
Haha look who's hiding from Sandy
 
Nice
 
you fuckers! You didn't star my joke! :P
3
 
8:51 PM
there @TonyTheLion
 
thanks :)
 
You are welcome. That'll only be 20 rep now. :-)
It's a sale on stars.
 
@EtiennedeMartel Everytime I see the word dichotomy I think of this: youtube.com/watch?v=OBDcmVETEzE&t=0m23s
 
just wanted to drop by and say, figured it out -- and indeed it does not rely on the arr array
just needed loop restructure
 
@Chimera done :)
 
8:53 PM
@JohnSmith OMG good news! I can now continue on with my day without worry.
@TonyTheLion lol thanks
 
@Chimera considering that I code stuff you eventually use, you should :)
 
@JohnSmith Just messing around. Good job.
@JohnSmith Oh yeah, what are you coding that I use?
 
@JohnSmith since I spent like an hour trying to figure out how to code it, can I see what you ended up with? (And did you memoize it?)
 
WTF is memoize?
 
8:56 PM
@Chimera caching in an equation, like inside a Fibonacci.
 
@MooingDuck oh
 
@JohnSmith and did you see the fast version I eventually posted? (chat.stackoverflow.com/transcript/10?m=6002402#6002402)
 
I see what you mean. FWIW, I know several people that keep tame wild boars (if that sounds contradictory, blame English) and they're fine: they don't get violent unless provoked. Even wild wild boars (fuck you English) are not of violent nature; they only attack when cornered.
Of course, leaving them with unsupervised children in the same space can end badly, but that's no different from what can happen with domesticated dogs. Basically, I wouldn't judge the father solely for keeping the animals. He even says he only plays with the beast when he is alone.
 
@Chimera Welcome to 3 days ago :P
 
8:57 PM
@Chimera Oh, that guy.
 
@Borgleader :-)
 
@Borgleader What do you mean? That guy was mentioned here long before.
 
Does any body know of videos on modern C++ programming?
 
@R.MartinhoFernandes I'm okay with taming animals, yeah. The article also doesn't paint a bad picture of the guy for that matter.
 
8:58 PM
@R.MartinhoFernandes Well last time I saw it it was around 3 days ago.
 
@Borgleader Welcome to three months ago.
 
I wasn't here 3 months ago
 
Anyways, he does have a lot of rep in physics.se
 
@Borgleader That's why I'm welcoming you :P
 

« first day (744 days earlier)      last day (4210 days later) »