« first day (2328 days earlier)      last day (2614 days later) » 
00:00 - 19:0019:00 - 00:00

Ell
12:18 AM
man it sucks that c++ can't infer == still
or at least allow it tobe defaulted
 
Yeah, and also the != operator
 
apex predator: no vermin is too small for the stomach
 
bring back the thylacine
 
how to train the world to love kangaroo meat?
there are more kangaroos than sheep in Australia
 
Ell
12:34 AM
I've seen the word vociferous three times today
> (especially of a person or speech) vehement or clamorous.
and now I've learned a new word
> making a loud and confused noise.
 
Good morning.
 
Ell
morning :)
 
@LucDanton Bien sûr, j'adore l'humour du Couac
 
@MarkGarcia Ouch
@R.MartinhoFernandes Should we wait for your friend or not?
 
12:50 AM
@Luc Merci infiniment <3
 
1:04 AM
oh ben c’est pas moi qui fait ça hein
 
1:55 AM
@Ell People are getting more vociferous when their values are being threatened :)
 
@Ell guess what
it's borrowed from french
like all fancy english words
you peasant
(look, another french word!)
 
@sehe When people's values are threatened, many transition from merely vociferous to ferocious.
 
Only for >32bit values
 
Is access to wifi a 32bit value?
 
@AldwinCheung Which stole it from Latin, you habitatoris regionis.
 
2:02 AM
@AldwinCheung yeah, you swine! o wait
 
@Ell By the way vehement and clamorous and person are also french
how do you feel about brexit now
europe wants their vocabulary back
 
less french = better
 
@AldwinCheung but they are not
They are latin. Indeed.
 
@AldwinCheung like "folk" and "wagon" and "swine"
 
@sehe nope
do you see many latin people walking around?
I thought so too.
 
2:06 AM
Every bit as much as they are French.
 
excuse me did you just assume my native language
 
@sehe you're just jealous because dutch is mostly mispronounced german
 
well I mean you're not terribly off there
 
hi
 
dutch is basically german pronounced by someone with a tracheotomy
 
2:08 AM
hehe
 
2:19 AM
I should have thought about using percentage in all layouts
 
@Telkitty Volumetric or mass?
 
layout - because different screen sizes
hard coding making screen looking weird in some screen sizes
 
Ell
@AldwinCheung I find French people are just rude as opposed to loud and confused
 
2:35 AM
 
Ell
@Telkitty what is it?
 
roof dancer
The common brushtail possum (Trichosurus vulpecula, from the Greek for "furry tailed" and the Latin for "little fox", previously in the genus Phalangista) is a nocturnal, semi-arboreal marsupial of the family Phalangeridae, it is native to Australia, and the second largest of the possums. Like most possums, the common brushtail possum is nocturnal. It is mainly a folivore, but has been known to eat small mammals such as rats. In most Australian habitats, leaves of eucalyptus are a significant part of the diet but rarely the sole item eaten. The tail is prehensile and naked on its lower underside...
 
Ell
Are you holding it?
 
@Telkitty why does Australia get such a cute possum
when America gets this
it's made out of teeth and nightmares :(
 
2:55 AM
@jaggedSpire it's never late to give up your US citizenship in favour of having better future elsewhere :P
 
@ProblemSlover alas, I'm afraid I'll have to decline
 
@jaggedSpire Used to have a possum or two in the roof, dancing every night when I was about to go to sleep. Chased the possum out from the roof, so it moved into the garage & made its nest there.
 
Just survived a BIOS update. Those are always nerve-racking.
Especially going forward 2 years.
 
@Telkitty :\
 
@jaggedSpire That's a photograph of Kellyanne before breakfast?
 
2:58 AM
@sehe ...yes.
 
Nicely authentic
 
It's really startling when she darts out of the bushes in front of you
 
I just got bit by ... string literals in C++. Not written like this, but it boils down to this failing testcase:
 
especially when she hisses at you because you're too close
 
> BOOST_CHECK_EQUAL(38, "_\0_\0n\0a\0m\0e\0i\0d\0_\0v\0e\0r\0s\0i\0o\0n\01\0.\00\0"s.length());
Before the edit was the fixed case :)
 
3:01 AM
the two possums are still in the neighbourhood - they are almost as big as a medium sized dog
 
That's one for the Twitter confessions fad.
 
@Mysticial I wish mobo manufacturers have smartphone like factory reset behavior.
 
@MarkGarcia Of all the BIOS updates I've done, I've only screwed up once. And that was a bug in the BIOS, not exactly a fault of my own.
That was for a server board. So not a lot of customers to yell at the manufacturer for me.
Needed to do this update for the 16GB DIMM support.
I didn't think it would ever come to this. I fully expected this box to run 8 x 8GB for it's entire life.
Looks like my overclock is still stable.
 
@sehe my my
 
tbh I thought \0 was in the family of \b, \f, \r etc.
Turns out it's /just/ one of the octals, so \00 is equivalent to \0...
 
3:14 AM
it's pretty evil
did your syntax highlighter display them as a single escaped unit?
it looks like coliru's does, but I can't imagine that attention to detail applying to every syntax highlighter for c++
 
Nope
Boring syntax highlighting
 
that would certainly add to the confusion
instead of posting it as a confession you could post it as a quiz to see how many people interpret it as you did :V
ooor you could do both
though telling people that something about the literal bit you is probably a good way to make them be even more cautious than if you posted it as a quiz
 
4:17 AM
@Mysticial this amine soundtrack gives me orgasm lol
https://www.youtube.com/watch?v=VftUbwu73D4
 
> This video contains content from Sony Music Entertainment (Japan) Inc.. It is not available in your country.
Though I can probably find it elsewhere if I tried hard enough.
 
@Mysticial UK VPn dude
@Mysticial Well. ok. I just used to run vpn 24/7,
 
@StackedCrooked Yeah it does.
 
Poor Woman../
https://www.youtube.com/watch?v=XUQBqhOJjeA
 
@MarkGarcia lol I put on a coat while watching it
@ProblemSlover lol
 
5:03 AM
@Luc Help me bikeshed a name for a shim above <algorithm> that wraps existing algos to add support for ranges and returns optional<Iterator> instead of past-the-end iterators.
<algoluc>
 
5:21 AM
@AldwinCheung but in C++17 you can if(auto it = find(…); it != end)
 
still semi-garbage
if (auto it = std::find_if(v.begin(), v.end(), pred); it != v.end()) {
    it-> /* blablabla */
}

if (auto it = luc::find_if(v, pred)) {
    it-> /* blablabla */
}
 
second one would be (*it)->
 
Indeed, maybe better to return a optional<T&> then?
 
then you give up container operations
 
everything sucks
 
5:24 AM
or even further algorithm use
 
Yeah that's bad.
 
if we want to shave that yak to the bone there’s also for(auto elem: find(…)) but then you can’t else an alternative
 
Maybe structured bindings would help.
Ah nah.
 
@LucDanton Well, you already kinda gave that up when using the range version anyway
 
@AldwinCheung lol that’s a lot of suckage
'<algorithm> doesn’t compose, I’d better write my own version that doesn’t either'
 
5:30 AM
Also completely semi-unrelated but has there been proposals for different kind of search policies? Linear, binary, exponential, whatever
 
not any more than you can customise your searches, no
 
@LucDanton yeah, in true c++ fashion. "std::max is broken, let's introduce std::clamp which has exactly the same flaws we've known for 20 years".
I didn't think about composability at all (does it show?) it's just still overly verbose to find a goddamn thing in a container when that's the only thing you care about
 
@LucDanton doesn't make sense to me. Further algorithm use on something that returns a singular value? o.o
Are you talking about the use case where you actually use the iterator returned from std::find_if on another algorithm?
I don't think I've ever seen that one before 🤔
 
@Rapptz Yes that's what he means AFAICT
 
who does that
 
5:38 AM
e.g. iterated find_if is filtering
 
🤔
 
partitioning via std::equal_range is another classical one
 
I once used find_if then copy for string stuff.
 
I'm sure it's a valid use case
 
@Rapptz ya know, like feeding the result of an iterable-producing function to another one ._.
 
5:42 AM
Yeah I can see it
Just never personally used it.
 
erase–remove
 
I'm talking about just std::find_if
 
@LucDanton But then you wouldn't use luc::find_if(range) for that
 
sure, find whichever, erase between that and someplace else, and remove that
@AldwinCheung …why not?
 
Because in that case you'd use the iterator-based version I guess
 
5:46 AM
I’d quote myself regarding suckage but I don’t want to make it sound like it’s a big deal
 
But shouldn't it return an iterator/position?
 
@AldwinCheung well I honestly can’t think of any name right now (for anything), but perhaps that should be a clue as to the name: it’s purely a convenience layer then right?
 
idk I think C++ is the weird one here lol
like in Python it returns an item or None and in Rust Iterator::find does the same
 
I think it’s one of those cases where Python encourages you to use a for loop for that
 
5:54 AM
?
 
both have actual filtering, too
@Rapptz like how map/filter etc. are shunned either in favour of comprehensions or loops
by part of the community I should say
 
comprehensions are faster (it has its own dedicated opcode)
 
like I’ve said
 
6:08 AM
Morning.
 
Mornin'
 
user1804599
6:50 AM
Root cause of outage: S3 is actually hosted on Google Cloud Storage, and today Google Cloud Storage migrated to AWS
5
 
8:43 AM
@rightfold Weird..
 
8:56 AM
oh welp
two German drivers who killed a guy in illegal road racing got life
 
time to stick to speed limits
 
idk, it wasn't homocide
 
user1804599
They should undeprecate register.
 
user1804599
I realized it's actually very nice.
 
9:01 AM
@Mikhail the court ruled that it actually was
 
Which is a mistake
 
what I find interesting is that both of them got sentenced, while clearly just one of them caused the death
 
user1804599
The other one could have caused it as well.
 
user1804599
It was equally dangerous.
 
texmaker brings in a gigabyte of packages :'(
gummi does too no way out gotta install a gigabyte of packages
what did they put in those packages crysis?
 
9:07 AM
FYI, LibreOffice contains the complete source code of Thunderbird
So, maybe
 
@Mikhail lol, really?
 
no, he said that to bamboozle us
 
@JerryCoffin you damn hippy!
 
user1804599
> not using google docs
 
@Mikhail I thought I couldn't think less of LibreOffice
 
9:14 AM
@Mikhail citation needed
 
Ven
@rightfold Perl 6 regex allowing leading | and || is one of the biggest feature.
 
user1804599
I love %%.
 
@Mikhail cheers for the reminder, getting rid of that freed up 300 MB and pointed out unused packages
which in turn freed up 980 MB so more or less a good counterweight to the 1.2GB latex behemoth
I've no clue why it has to take 1.2GB
a thing that outputs text documents is not something I'd expect to require memory in the order of gigabytes lol
now that I take a closer look there's a lot of software ubuntu came with that I never use I should get rid of it
not just libreoffice
 
> a thing that outputs text documents
so naive
AFAIR it's turing complete
 
maybe it has a bunch of fonts embedded, or all the unicode tables a few hundred times
 
9:22 AM
@milleniumbug so is C++
and you don't see its compilers take gigabytes of memory
 
actually...
 
@milleniumbug brainfuck is also turing complete
 
you know what? nevermind
still needs to handle all the math users, the formulas, the typography enthusiasts (typography is SERIOUS BUSINESS)
 
Turing complete is not a measure of complexity, just a measure of how complex the usage can be
 
> all the math users, the formulas, the typography enthusiasts (typography is SERIOUS BUSINESS)
 
9:25 AM
turing completeness is irrelevant in practice uses
 
that asks for plugins and non-mandatory packages
 
@BogdanMarginean It is plugin based though
 
this thing installed a lot of ruby things on my machine
 
well, "packages".
 
let's test my linux-fu and get a bit more info about these packages
 
Ven
9:28 AM
Hello.
 
9:44 AM
What's the policy on SO for cross posting question over sites?
 
don't unless you customize the question for each site
for example in engineering focus on the load calculations and how to know when enough bracing is enough but in woodworking focus on how to attach the bracing
 
I asked on serverfault, but it's just a shitty site with no users... so thinking I'll dump it on SO too
 
Expect people to moan about it once they find the crosspost so you may want to highlight any differences between the questions.
 
10:00 AM
I basically regret asking on the right place where no one will see it :(
 
nwp
10:36 AM
@thecoshman Cross-posting does not automatically make a post invalid. You may get different answers with different focus. However, you are not supposed to large scale copy/paste stuff from, say, SO to portugese.SO.
 
10:48 AM
@Puppy back when you had health issues, was it IBS or something else?
 
11:25 AM
egh people coming back to my 3yo answers and saying how "wrong" they are
context, anyone
 
Ven
sin text
wow, I can see the activity decrease in the lounge comparing my stats with 6 months ago
 
 
2 hours later…
1:01 PM
DIY the new trend ...
be construction, dudes, stop building DIY weapons
DIY missile is still hilarious
DIY 3D printed tank, me wanna build 1
 
@Ven Did people emigrate to the other thing...Discord chat?
 
@wilx yes
 
@wilx There's a good few of us there yes
and there's a proper channel for QnAs now
 
1:52 PM
@wilx Traitors is the right word.
 
@R.MartinhoFernandes Heh. Yeah.
 
meh
it's cozy in there
 
@R.MartinhoFernandes you are allowed to join us you know
 
allowed ... right
 
Joining the traitors sounds like treason to me.
 
2:05 PM
I am sticking around here, sitting on the edge of everything is just fine with me
Oh gosh, I couldn't be bothered to tidy up the code while fixing it
 
@Telkitty You jolly well should!
 
it doesn't matter how pretty the code looks, if it doesn't run ... well ...
 
2:37 PM
@R.MartinhoFernandes I think it's a textbook definition, yes.
 
Ell
hi
 
@milleniumbug it has the best people, let me tell you, some great people, the best people, ask anyone
 
Ell
@R.MartinhoFernandes heh
what are the people that visit here and discord?
 
nwp
@Ell part time traitors
 
Ell
what if they also visit other online communities? :P
 
Ven
2:47 PM
@thecoshman @fredoverflow Kotlin 1.1 released
 
Kotlin still alive :O
 
3:04 PM
@Ell Treacherous spies.
 
sbi
3:18 PM
Hi.
 
Nothing really fun at the Kona meeting it seems :/
 
nwp
@sbi I think that is not the right link.
 
sbi
@nwp Works for me. What's wrong with it?
 
nwp
@sbi it shows a square function and no bit pattern copying
 
sbi
3:25 PM
@nwp I see this:
#include <cstdint>
#include <cstring>
#include <iostream>

//illegal due to strict aliasing violation
uint64_t typePun1(double d) {
	return *reinterpret_cast<uint64_t*>(&d);
}

//legal in C11
//illegal in C++
uint64_t typePun2(double d) {
  union pun {
    double d;
    uint64_t u;
  };
  pun p;
  p.d = d;
  return p.u;
}

//only legal way?
uint64_t typePun3(double d) {
  uint64_t retval;
  std::memcpy(&retval, &d, sizeof(retval));
  return retval;
}

int main() {
  std::cout<<typePun1(5.0)<<"\n";
under the link.
 
nwp
// Type your code here, or load an example.
int square(int num) {
    return num * num;
}
is what it shows for me
 
sbi
Sigh. It seems there's some magic in godboldt links.
I got linked to it from here.
Does this work for you, @nwp?
 
nwp
@sbi yes
 
the supposed advantage is that with memcpy your target will have implementation defined value, as opposed to being UB altogether
that's what I've read on SO, but I am not a language lawyer
 
sbi
Why would misinterpreting a bit pattern from a different location be superior than misinterpreting it at the original location?
 
3:31 PM
the latter is UB
 
sbi
I read that. I wonder about the difference it would make.
 
Ven
@nwp lol, not writing this square(num){num*=num}.
What a newbie.
 
sbi
@Ven Thank you very much for this important and well-formulated contribution to the discussion.
So nobody understands this?
 
apparently all language lawyers are currently unavailable
 
nwp
@sbi I believe the reason is strict aliasing, which exists so that d may be kept in a register and that there is no way that it may be overwritten due to some pointer of another type having the same address. The copy avoids that problem.
 
3:45 PM
I think because memcpy interprets it through void* which is allowed to alias with anything
 
sbi
@nwp I see. Yeah, aliasing came up in this discussion. This, however, is only a problem if you keep references round. If all you do is create a copy of the bit pattern, this shouldn't be a problem, right?
@ratchetfreak Could you elaborate on this? I still don't get it.
 
nwp
@sbi With sufficient limitations such as not keeping references around (how long? to what?) you could make a case that the reinterpret_cast would not break and that no optimizations are hindered, but apparently that was too complicated and they just declared aliasing pointers UB. On the bright side the performance does not seem to suffer under that overly strict rule.
 
sbi
@nwp So there's a difference between having a chunk of memory referenced to by two char* or by a char* and a signed char*??
 
nwp
@sbi I believe char*and void * are exceptions to the rule. With int * and unsigned * that would be the case.
 
sbi
Um. That was too condensed for me. Which rule? What "that"? Which case?
 
nwp
3:59 PM
@sbi The strict aliasing rule. That having a chunk of memory referenced by 2 int * is different than having it referenced by an int * and an unsigned *.
Though I'm on thin ice here, might want to ping griwes or something.
 
sbi
@nwp Ah, OK. So there is a rule for this, and it's referred to as "strict aliasing rule"?
goes off googleing
 
nwp
@sbi [stackoverflow.com/questions/98650](this one) should be the canonical one
I give up -.-
 
sbi
@nwp Yeah, I am already at it.
@nwp [this one](stackoverflow.com/questions/98650)
 
@nwp signed/unsigned of what is otherwise the same type is also an exception
 
@sbi With the former, each object is interpreted in a single way; with the later it the same object is interpreted in two different ways. Since char* is magical and is allowed to "some bits that might mean something else", arguably only in the latter is there some misinterpretation.
 
sbi
4:08 PM
@R.MartinhoFernandes I thought someone said void* where the "magic type" allowing this? Now the linked answers and your message say char*.
 
@sbi my mistake
it's char*
 
@sbi void* just means the "something else" part. It can't mean the bits since you can't read them from void*.
 
sbi
@ratchetfreak Ah, that was you. Thanks for speaking up, that relieves me of searching how this got into my head.
@R.MartinhoFernandes So if I do (unsigned int)*(char*)(&some_int) then this is OK, but if I do (unsigned int)*(&some_int) it isn't?
 
@sbi Both are ok because unsigned/signed is allowed to differ as well.
@sbi I assumed you mean to have the stars inside the parentheses.
 
sbi
@R.MartinhoFernandes Um. OK. So (long)*(char*)(&some_int) vs (long)*(&some_int) (assuming sizeof(long)==sizeof(int))?
 
4:15 PM
Both of those are not ok, because you (can) access the same object as two different types (that aren't exceptions), int and long.
 
sbi
@R.MartinhoFernandes Wait. If I do (long*)(char*)(&some_int) the compiler has to keep track of the result referring to some_int??
 
Ven
Scala doesn't warn you when you have duplicate match patterns. -_-
 
@sbi Not sure what you mean.
 
or it can assume that any other memory access may invalidate the memory
 
Ven
@sbi oh, I see now you talked to me. I blocked you ~2 years ago, so yeah, I didn't see your stuff. My reply must've looked weird.
 
sbi
4:18 PM
@R.MartinhoFernandes Consider long* pl = (long*)(char*)(&some_int); IIUC, the compiler is supposed to keep track of pl referring to some_int because there's a char* stuck in the middle?
 
No. Dereferencing pl is UB so it doesn't have to do anything.
 
sbi
@R.MartinhoFernandes Oh, right. So I need to memcpy() the bits from some_int into a long first, then this is fine?
And I need to do this through char* because... why?
 
@sbi Because char* is what means "pointer to some arbitrary bit pattern" (other than its regular meaning of pointer to a char)
 
sbi
@R.MartinhoFernandes So if I copy it using int*, where's the problem? It's a copy, it isn't aliasing the original.
 
@sbi Oh, but if you use memcpy you don't actually have to cast anything because memcpy does that already.
> Both objects are reinterpreted as arrays of unsigned char.
 
sbi
4:24 PM
I have that page open. :-/
Who cares whether I type char* (or unsigned char* – how does this come into this mess, actually?) or whether some programmer typed it into memcpy()'s implementation.
 
@sbi It doesn't matter. The point is that you can't read a int through a long*.
You can read unsigned T through a signed T* and vice-versa; you can read anything through a char*, signed char*, or unsigned char*, and anything can be read from a char*, signed char*, or unsigned char*.
 
 
Anything else is UB.
 
sbi
@R.MartinhoFernandes OK, I think now I get it. I can read an int through a char* (add un/signed at leisure to either), but not through anything else. I would have to make a copy of the bits first. This is what the "strict aliasing rule" says.
 
(Oh, I forgot inheritance; that too)
 
4:31 PM
did github change colors around their UI or am I seeing things
 
sbi
@R.MartinhoFernandes However, the original discussion was that std::memcpy() allows type punning, while std::copy() does not. This is all about copying the bits to some other piece of memory anyway, so the problem does not apply. So I still fail to see why (implicitly) casting to void*, then to unsigned char* (when you use std::memcpy()), is better than using std::copy() with a bunch of char* as iterators.
@BogdanMarginean So if github didn't change anything then you're not seeing things anymore?
 
Ven
the top bar, ~a month ago
 
@BogdanMarginean the black top bar was white before
 
links are way more blue
this is so odd icons are also way more blue
one sec I'll paste screen
even the cursor shadow on the menu seems more blue than it was
O_o
 
Ven
oh yeah, they did change that
 
4:36 PM
this is so weird I went for a walk when I was back boom
different colors
:D
the colors within code blocks are also different
 
nwp
Quick, can you find all 10 differences in github in under 2 minutes?
 
not interested, I'll find them at my own pace
 
5:05 PM
@sbi I'd favour memcpy because it makes it clearer that it's not a normal copy.
 
Fuck, my video card got delayed to Monday. I guess I should've expected that given that it's shipping from California.
 
@R.MartinhoFernandes No friend, then?
 
user1804599
5:22 PM
Ugh, people in the train dealing pot and discussing how good the hooker was
 
@Shoe He said he's too busy :(
 
@R.MartinhoFernandes Well, I guess we can try to introduce rules for new players to join
It's no issue really
 
nwp
5:37 PM
lua using : for member access instead of . confuses me so much
especially since they use . instead of ::
 
6:30 PM
morning
 
Ven
Hi
 
@nwp Well, that's not true at all.
 
nwp
@Puppy At least lua uses Class.staticfunction and object:memberfunction instead of C++'s Class::staticfunction and object.memberfunction.
 
there's nothing illegal about Class:staticfunction
nor about object.memberfunction
 
nwp
My point was that I'm a dummy and keep writing object.memberfunction which fails in lua.
 
6:36 PM
you're trying to project classes and members on to a language that effectively does not have them.
 
nwp
I don't even know anymore why I wanted to share that.
 
I recommend using a language that is not shit
 
Xeo
Lua's shit now? Didn't you love Lua?
 
I haven't sung Lua's praises in many a year
truth is, Lua's just Javascript but very slightly less stupid
but it still doesn't have, like, actual features that are good
and the whole dynamic typing thing is just an immediate dealbreaker anyway
also the C API is a sin beyond redemption so even though you have to bind a bunch of shit for yourself because it ships with fucking nothing, binding it is a terrible experience akin to stabbing your eyes out with a fork
there's just nothing to like about Lua
 
00:00 - 19:0019:00 - 00:00

« first day (2328 days earlier)      last day (2614 days later) »