« first day (2037 days earlier)      last day (2911 days later) » 

12:06 AM
@Ven If the complexity is exponential, we get a black hole next saturday.
@wilx I just looked at the COBOL 2017 spec.
 
@Ven First they'd have to know the cost (and like the old saying about Lisp programmers, they know the value of everything, but the cost of nothing).
 
12:32 AM
Does a 10G usb adapter exist?
 
@Mikhail Maximum speed of USB is currently 5 Gbps.
Realistically, I'd guess most actual implementations would have trouble sustaining that for very long either. There are 10G network connections, but I doubt anybody's put one into a USB dongle (though it does sound pretty funny--like a turbine powered riding lawn mower).
 
@milleniumbug I don't wanna pull-start the motor though. Obviously needs an electric starter... :-)
 
1:15 AM
 
"I wrote a bubble sort". That's your mistake, right there. — Jerry Coffin 20 secs ago
5
 
Well might get a thunderbolt one, I frequently deal with terabyte videos in my work...
Here is a video if anybody is bored:
 
user406009
1:34 AM
@Mysticial nope. As long as it's within roughly an hour of 1365 W Grand Ave it should be fine.
 
user406009
I am open to anything.
 
user406009
Except alcohol
 
user406009
@JerryCoffin the true mistake was the decision to start programming.
 
or not to end programming
 
This is know as the "halting problem".
 
1:44 AM
@JerryCoffin @Morwenn @sehe continuing work on my pdqsort paper, I love this graph
 
1:55 AM
@Lalaland Fuck... The problem is that I don't eat out very often so I don't know of any good places to eat.
I usually eat at this cheapass pizza place. But...
 
You can go to Tank Noodle
 
@Mysticial I love that graph - it's actually 1 / the binary entropy function, which makes perfect sense if you think about quicksort
 
user406009
@Mysticial cheapest pizza is fine with me as well
 
user406009
Whatever you want to do.
 
2:21 AM
This "Elastic Heart" song and video are kinda cool.
 
3:10 AM
What a lovely scene lol
http://imgur.com/gallery/yGzK2
 
user406009
3:43 AM
@fredoverflow someone should comment that java as a whole is antiquated and that "all the cool kids use node.js"
 
@Lalaland Sounds good. The place I go to is Blaze Pizza. It's just west of the loop.
@Xeo @StackedCrooked You two watching Kabaneri this season?
It's this season's biggest offender for cliffhangers. It's like a mega toilet splashback. The kind that just completely soaks your ass and leaves you REALLY pissed off.
 
user406009
Ah yeah, I know the blaze chain. What time exactly? I can wear my stupid noogler hat to be super noticable by you
 
You got into Google?
Wait... here? In Chicago?
 
user406009
Yep.
 
user406009
As an intern though
 
Close enough.
 
user406009
So not really success. Yet at least.
 
@Lalaland I guess I around noonish?
 
user406009
Ok. I'll be there at 12'
 
user406009
Assuming I survive this red eye tonight.
 
3:48 AM
wut
 
user406009
I have a red eye flight in 2 hours.
 
user406009
Which I am not looking forward too.
 
user406009
I should be back to normal by Sunday though.
 
@Lalaland working there as an intern/ employee., you feel yourself like in the anthill. I wouldn't like to work there in the permanent role unless I get a private office space /
 
I was gonna say...
@ProblemSlover Nobody gets private offices anymore. Unless you're some high-level manager.
 
3:52 AM
@Mysticial /: so this is one of reasons I work for myself /
 
user406009
@ProblemSlover it didn't seem so bad the last time I worked in an open office environment.
 
user406009
The trick was a strong company culture against noise pollution.
 
For that matter, all 3 levels of managers that sit between me and the CEO sit within 30 feet of me.
They have their own offices, but the doors are usually open and the Windows have no shades.
@Lalaland Are you in Chicago for the whole summer?
 
user406009
Till August 12th or so.
 
user406009
So pretty much yes.
 
3:59 AM
What position will you be doing?
I keep hearing that the Chicago office is all marketing.
 
user406009
There are 100 engineers. 700 noon engineers ours.
 
user406009
There are 100 engineers. 700 non engineers ours.
 
user406009
I'll be on search infrastructure.
 
There's 800 people in the Chicago office?
 
user406009
I think so.
 
4:10 AM
Ooh, gratz on the internship lalaland
 
And good thing you picked this weekend and not the next one. I'm be at ACEN.
 
4:27 AM
Is it just me, or are sitcoms about knowledge-based fields not really about the field? Big Bang Theory and The IT Crowd don't delve very deep into their respective fields
 
If they did dig deep, nobody but rocket scientists would enjoy/understand it.
 
I only understand a fraction of the topics that pop up in Big Bang Theory.
 
Besides, sitcoms are about what happen to the characters, the fact that theyre full of it guys / physicists is just window dressing or wtv.
 
By "understand", I really mean, "heard of". And by "heard of", I really mean, "just the name from some random class or a wiki article".
 
4:29 AM
Its a starting point for shit to happen but the focus is on the characters and their relationships. TBBT and IT Crowd have a similar formula to say HIMYM
If you want to delve deep in a field, well watch a documentary or something
 
@Borgleader Documentaries can be interesting. If it's not in your area, you learn a lot about it. If it is in your area, you can nitpick at the details and mistakes they make.
 
@Mysticial Yeah, I like documentaries :)
 
I've found myself nitpicking at astrophysics documentaries a lot. Makes me feel like I know astrophysics when I really don't.
 
Documentaries can be nice, but I'd be hard-pressed to convince my family to watch them ^^; Thankfully I have my computer
 
My mom loves watching them. That was my main exposure to them before I moved out.
 
4:35 AM
Any good computer science documentaries? I'm surprised that the only one I watched on the topic was about the demoscene
 
There was one on Stuxnet.
Admittedly, I haven't seen too many CS documentaries. I think most of the ones I watch are Astrophysics, nature, and biology.
And war documentaries.
 
I guess those are the topics anyone can stand in front of a camera and be in awe of ^^; But that said, they can be informative sometimes. Especially the ones about particular medical conditions
 
@Aaron3468 Yeah, I recently watched one on drug-resistant bacteria.
 
How was that one?
 
Scary as fuck.
Enough to scare me from going to India any time soon. (no offense to anyone)
Stuff like NDM-1.
 
user406009
4:45 AM
@Aaron3468 does Office Space count? :P
 
@Lalaland Depends on how plausible the plot is. Reading it, I think we can all agree it's a documentary :D
 
user406009
Also, Silicon Valley is quite good.
 
user406009
So much better than The big bang theory imho.
 
That's a movie. But still good as a documentary.
 
Silicon Valley looks interesting
Radix sort looks so efficient
 
5:02 AM
It has a lot of strings attached though.
 
Would that be because it doesn't rely on comparison? Would it be safe to assume it becomes less efficient the greater the difference in magnitude of the least and highest values being sorted? So it would perform well with a rating system of 1 to 10, but poorly with the scales of significant historical artifacts and structures?
 
Radix sort works best if the distribution of the elements with respect to the radices is fairly even.
If things are clustered in a bad way, or if the range is massive then you'll run into problems.
IOW, no matter how to design the sort, you can always construct an input of elements that will break it.
Sort like how a hash map is O(1), but you can always construct an input that will break it by hashing all the elements into the same bucket.
Assuming that there's more entropy in the element than there are hash buckets.
 
Haha, yeah. The perfect algorithm depends on the assumptions you exploit (and their reliability). Are there some algorithms that would require more effort to validate that they are optimal/fairly applicable than it's worth to just run the algorithm?
Wait, that sounds a bit like the NP problem
 
During one of the interviews that I did, one of the questions involved constructing a perfect hash algorithm if you know the key/value mappings ahead of time.
I wasn't convinced that (from an information theory perspective) that it can always be done in O(1) space and time.
For that matter, even O(log(N)) space and time seems iffy. But I look forward to be proven wrong.
 
I think you're correct, given the information available. From what I can find, it looks that it often can reduce to O(1), but only when some assumptions hold true
45
Q: Can hash tables really be O(1)

drawnonwardIt seems to be common knowledge that hash tables can achieve O(1) but that has never made sense to me. Can someone please explain it? A. The value is an int smaller than the size of the hash table, so the value is its own hash, so there is no hash table but if there was it would be O(1) and st...

 
5:16 AM
The thing that won't get hired because you don't know how to implement some sort of data structure / algorithm is just ridiculous .
 
Come to think of it, if a perfect hash algorithm exists for all mappings that runs in O(1) space and time, hardware dividers wouldn't be so slow. lol
 
user406009
@Mysticial doesn't it take at least o(n) time to read the input and generate the output?
 
Btw, hardware dividers use lookup tables followed by a Newton's Method iteration. (or something like that)
@Lalaland Log(n) actually. If we consider N different keys mapped to N different values.
So no, you can't beat log(n).
 
@ProblemSlover I agree on that front; problem solving is more important than memorization. That said, if an interviewer asks you to implement it, the official word is that those questions are only testing that you can approach the problem. Nonetheless I hear that some places do discriminate unfairly
So I agree if, say, you're asked to implement a sorting algorithm but only write bogo-sort, bubble sort, or fail to write anything.
 
user406009
@Mysticial are you talking about the time to generate the perfect hash table, or given that table get a particular hash?
 
user406009
5:25 AM
One thing which is sorta cool to think about is that the minimum theoretic latency grows at the cube root of n due to the fact we live in a three dimensional world.
 
@Aaron3468 100+ being able to find approach to the specific problem. I would also ask how he / she would approach to the specific software design problem. not sure if such questions are asked for the junior role though.
 
@Lalaland The time to compute the hash.
 
user406009
So all those logn and O(1) times are "lies". It's almost always 0(cube root(n))
 
Suppose you have N key/value pairs (known ahead of time). And you want to build a perfect hash to put them into N buckets such that there will never be a collision.
I don't think it's possible (in the general case) that such a hash function will run in O(1) space and time.
Definitely not time since there will be at least log(N) bits to read.
 
user406009
@Mysticial if you can have more than n buckets, you can do O(1).
 
5:29 AM
@Lalaland Is that provable?
 
user406009
Using a normal hash map.
 
I'm talking about the guaranteed worst case.
You want to build a perfect hash function such that the resulting hash map will have no collisions.
 
user406009
Yeah, that's probably not possible
 
user406009
@Mysticial if I had to implement that, I would do it with a normal hash map
 
Which opens up a new problem.
Let's relax it a bit.
 
user406009
5:32 AM
No good worst case guarantees with that though.
 
Given N key/value pairs known ahead of time. Build a hash function/hash map implementation that is guaranteed to run in O(1) time and O(N) memory.
IOW, put a provable upper bounds on collisions. As well as a provable upper-bounds on the # of buckets.
O(1) is too strong since you need to read O(log(N)) bits.
So let's relax that to O(log(N)) time.
To make comparisons fair, that means that most log(N) algorithms become O(log(N)^2) time because you need to read a log(N)-bit index.
I guess if you want to take theory to the extreme. If you have N bytes of memory, it takes O(cbrt(N)) time for a random read because information can't travel faster than the speed of light. And the most information you can cram into unit distance from a point is N^3.
But... that's not all.
It you want to take it to another level, it's not possible to put N^3 amount of matter in a O(N) radius. Because if N is large enough, N would be smaller than the event horizon of system.
 
user406009
Reading the log(n) bits only counts of we are considering those.
 
To summarize, everything is really slow.
 
user406009
If we want to be really formal, we need to be explicit what we are measuring exactly.
 
I think that's where it comes in handy to ask yourself before implementation; 'how would <insert omniscient entity> do this?'
So that you remember that you want a satisfactory compromise between terrible and an algorithm that needs no calculations to be perfect
 
5:43 AM
Actually, the radius of the event horizon is linear to the mass. So in reality, if you have N bytes of memory, access times will need to be at least O(N), otherwise the whole system would collapse. That really sucks.
Assuming that general relatively wins over quantum mechanics. But I'm pretty sure that's a bad assumption.
 
Or you could just meander about the data bus, and return the value a random amount of execution cycles later when you hit it. Easy O(infinity) access time
This is pretty interesting and I wish developers used systems like it:
 
user406009
I really wished airlines didn't run out of overhead bag space.
 
user406009
Checking your carryon our annoying.
 
Yeah, do you think carry-on checks are O(n^2)?
 
user406009
And it isn't rocket science, simply get one overhead space per seat.
 
user406009
5:48 AM
/end rant
 
I was looking at the asymptotics and realized that if you have more than O(N) matter in a radius of N. When N is large enough, it will collapse into a black hole. So if you want to build a computer with a really big N, you need to spread out the memory to be less dense than O(N) bits per N^3 volume. Otherwise the system will be a black hole. But if you spread it out like that, the distances between everything will be larger than O(N). Hence larger than O(N) latency for O(N) memory.
 
@Mysticial So, like a computer network?
 
@Aaron3468 Yeah. On a galactic scale.
Assuming that each bit of data uses a fixed amount of mass.
If you can store bits without mass, then that restriction no longer holds.
 
user406009
@Mysticial you can store bits without mass.
 
That would be interesting. Pulling up a local galactic map would no doubt be a quick operation at any terminal, but I can't imagine how many background simulations you could run by that point.
There'd probably be an AI watching for signs of war, etc while you pull up cat photos.
 
user406009
5:51 AM
Actually wait, I might be wrong
 
@Lalaland I don't think quantum counts. While you can have infinite states, you can only read one of them at a time.
And end up destroying the rest.
 
user406009
Anyways, my two proposals would be infinitely high frequency radio waves
 
user406009
And pushing electrons into really high orbitals
 
@Lalaland I was thinking that too. But photons have limits as well.
 
user406009
The first one runs into plank length issues I think.
 
5:53 AM
@Lalaland The problem is that energy doesn't natively store and regulate itself for communication. Even broadcasting emf requires matter in the form of a transmitter, and electrons require a parent atom (usually). Therefore storing data requires some form of mass for regulation.
 
user406009
The second one you have electron escape issues.
 
Quantum entanglement (if it can be used to transport information FTL), will let you get the latency below O(N). But it doesn't help you shrink the size of your system.
 
user406009
@Aaron3468 look into electron orbitals. You can encode a lot of bits into one electron by moving it to a really high orbital
 
user406009
The question is if there is a max orbital.
 
user406009
Anyways, both ideas need energy, and energy is mass, so whatever.
 
5:56 AM
At some point, however, you need to communicate the information to a human, and take input. Conversion between human-readable and machine-readable format requires mass to operate unless you're doing something weird like using the human as the mass (heat interface?)
Otherwise you have a phenomena where something might be a computer, but nobody knows because nobody can interpret it ^^;
 
@Aaron3468 That doesn't quite apply. Suppose you're crunching an algorithm on your galactic computer that outputs either true or false.
 
Okay, and how do you observe the result?
 
user406009
@Aaron3468 we were trying to come up with schemes that use a constant amount of mass to store unlimited bits
 
Ah, okay, carry on. Much easier problem to solve than mass-less information
 
user406009
@Mysticial aren't there time travel issues with ftl?
 
5:59 AM
@Lalaland Yeah...
I'm not sure how quantum entanglement or tunneling plays into that.
That's where general relativity and quantum mechanics don't agree.
 
Isn't time travel a feature?
 
I also don't know how the Alcubierre drive system works when you look at it from macro scale.
Alcubierre drive is a hack that gets around the general relativity equations at a small scale.
But at a large scale, you're still moving faster than light.
I should probably do more reading to see what other strings are attached.
@Lalaland If you had access to negative mass matter, then the problem becomes trivial. As long as the net mass doesn't form a black hole, you're in good shape.
 
Ven
6:22 AM
Hi
 
Hi Ven
 
6:40 AM
@Mysticial yep
 
Xeo
@Mysticial Ye, but I'm behind a good bit, since I only watch it every 2 or 3 weeks with my buddy.
 
@Xeo Ep4 is a good stopping point. No cliffhanger there.
But fuck Ep3 and Ep5.
 
Xeo
haha
 
0
Q: `std::pair` `second` has incomplete type with `unordered_map` tree

doug65536I was reviewing some older code of mine and I saw the code using pointers to implement a tree of Variant objects. It is a tree because each Variant can contain an unordered_map of Variant*. I looked at the code and wondered why isn't it just using values, a std::vector<Variant>, and std::unorder...

 
Xeo
I just want to mention that 94.9 is a really great number.
@Mysticial But yeah, today is animu day
so we'll catch up on lots of shows
 
6:54 AM
Stop after ep4. Do not proceed to ep5 unless you like to rage.
 
Xeo
hmmm, okay
I'll consider it
Other than Kabanossi though, there's Bakuon, Jojo, Luluco, Big Order and Kiznaiver
 
ep5 came out fucking like today. So when I desperately looked for ep6, the ep5 release date was like the guy laughing at me for soiling my ass from toilet splash back.
 
Xeo
wow, you're really invested in those cliffhangers :D
 
Hmm, which anime?
 
@Aaron3468 Kabaneri
 
Xeo
6:57 AM
Kabanossi of the Iron Fortress
 
To make things worse, I'm going to be at fucking ACEN this time next week. So I'm not gonna me holed up in my room watching Anime like I do every Friday night. lol
 
@Xeo I'll take a peek at it. My favourite trainwreck this season is big order
 
I put Kabaneri as #1 this season so far. Marred only by the cliffhangers.
 
Xeo
Also, 3 day weekend inc, yay
 
I'm taking Friday off next week for ACEN. So yeah 3 day weekend for me.
 
7:01 AM
It's getting fairly good reviews... I wonder what other shows the studio makes 5 seconds later I see why
 
Hundred is an okay harem for the season. Netoge is utterly stupid, but I'm still watching for some reason.
 
Xeo
this weekend is 3 days (thanks national holidays!), so only 4 workdays next week, and the week after that only 3 workdays (Thursday's another national holiday, and then I'm off to my 5 weeks of vacation before moving and officially starting the "new" job)
 
Kuromukuro is pretty good as well.
You got a new job?
 
Yay, I can watch the previews without subtitles. Looks like a good show with character development, so I'll add Kabaneri of the Iron Fortress to my list
 
Xeo
Apr 7 at 18:57, by melak47
Mar 16 at 14:41, by Xeo
6 mins ago, by Xeo
yesterday, by Xeo
Oh looky, they finally did a press release on our work situation (TL;DR: I now work for InnoGames, in Hamburg)
 
7:04 AM
oooooooh
Our generation likes hopping jobs.
 
Xeo
It's not exactly hopping, since we didn't have much choice :P
 
"We"? The whole department got laid off?
 
Xeo
nobody got laid off
InnoGames just absorbed all of Funatics' employees, basically
 
Between jobs not being that great right now, and it being expected of us, it's a given. I think there are a lot of factors causing job hopping (not just entitlement like conservative media loves to report)
 
Xeo
most went to the Duesseldorf branch, me and two others went to Hamburg to the main branch
 
7:06 AM
@Xeo Oh, acquired?
 
Xeo
@Mysticial Not quite? Funatics is still its own thing.
But it's an empty shell now, basically.
 
Ok clearly, I don't know what the structure and relationship between the two companies before and after.
 
Xeo
@Mysticial Two different companies, but the bosses knew each other. InnoGames was looking for people for the Duesseldorf branch, since they wanted to open a second studio there, and Funatics was relatively close, with a great team, and currently at the end of the release cycle for the new game.
 
@Mysticial Similar to BioWare; the company still exists, but it's run by a parent and transferring resources between the two is easier. I guess in this case, it was easiest to let go of the old studio but keep the brand
 
Ah, so transfer of employees.
 
Xeo
7:09 AM
Considering the future of everyone involved, having the team switch over to InnoGames was a pretty good decision
since we weren't doing super well. Could still go on, but running from one publisher contract to the next was getting old
@Mysticial ye
 
Do you have to relocate?
 
Xeo
I've been in Hamburg for two weeks at the beginning of April to get started and get to know the people, and since then I've been working remote from Duesseldorf for my project there.
@Mysticial I could've chosen to go to Duesseldorf aswell instead of Hamburg, but the project was much more interesting and fitting for my skills.
But yeah, Hamburg means relocating
 
ah
 
Xeo
Though I'll keep my old flat and visit every 2-3 weekends
I'm keeping the option open to go back to Duesseldorf after a year or two
Since I don't really wanna permanently move there
 
Keeping your old flat? Do you own it? Or are you paying rent for not staying there?
 
Xeo
7:13 AM
I'll just continue paying rent
 
That's something I can't possibly do here with the rent upwards of 2,000 USD/month.
 
Xeo
heh. My current flat is pretty cheap, rent-wise
Rent in Hamburg can easily be double what I'm currently paying
 
You can't tree std containers? why are forward declarations okay for vector and not for unordered_map. just plain not allowed to?
 
Rent in downtown Chicago is so ridiculously high that buying something with mortgage is actually cheaper in terms of monthly payment.
 
Xeo
What I'm paying here, including heating, water, and other utility costs is what I'd pay in Hamburg for just the "cold" rent.
 
7:15 AM
I can't imagine why it would make any difference
 
I imagine you'll be paid well enough to cover it?
 
@Xeo How much is it (if you don't mind)?
 
Or at least that you're good with money
 
Xeo
440 warm here, prolly around 500 cold there :(
 
Fuck, that's cheap. Even if it's in Euros.
 
Xeo
7:17 AM
Well, consider that we also don't make as much as you muricans do
relative to living costs it's roughly equivalent, I think?
 
If I really wanted to, I can go sub-1000 USD if I move out of the city. But I'm totally not gonna waste two hours a day commuting.
 
Xeo
Anyways, since my raise comes out to ~700eur that I'll be able to use, money will probably be a bit tight the coming months, so I won't be able to indulge in hobby stuff too much
 
My university rents out campus housing for twice what it's worth five blocks away with an independent landlord. I ended up paying for what I thought would be worth $450/month (the listed price), but turned out to be worth ~$225/month. I might as well get a refund and live with mom for what I'm getting T.T
 
Xeo
@Mysticial I'm currently having a 1 hour commute to and from work :(
which was another reason I went to Hamburg, in the hope of shorter commute, depending on where I get my flat.
 
@Xeo ahhh
 
Xeo
7:19 AM
My commute to Funatics was <15min... by foot.
which was really nice :(
 
Oh wow!
 
nice!
Mine is shorter than that even at this new job. But I'm obviously paying for it by living in downtown.
 
In my philosophy, if you're saving money at the end of the month it doesn't matter how much you spend.
 
you could be saving more money...
Or you can buy property on loan and hope the value goes up, in which case you made money...
 
@Mikhail Holding a position on margin. Absolutely nothing can possibly go wrong with that right? :P
 
7:25 AM
Yeah, just sell when the year is a multiple of 8
 
Yeah, I've invested some money in a mutual, but it's been pretty poor timing, what with living in a province that relies heavily on oil. I save pretty aggressively anyways
 
then inflation hits
 
lol, does that actually work for year < 2000?
 
I wonder if you can buy puts on property. lol
If you're gonna hold a risky long position on margin, it might not be a bad idea to hedge it out.
 
I guess real estate options is a thing
Is it just me, or do things like this make me feel like professionals are slaves to the compiler and not the other way around?
Not that it's a bad thing, but I notice a lot of conventions are compensations for weird language behaviours
 
Xeo
7:33 AM
FWIW, the auto x{...} => initializer_list thing was fixed in C++14 IIRC
 
You should buy a compiler option. It gives you the right, but not the obligation to tell your compiler to fuck off when it tries to enslave you.
6
 
Xeo
also, slaves to the standard, really.
 
nwp
@Aaron3468 backwards compatibility has costs, this is one of them
clang-modernize is a way to outsource the task to a tool, so it is not all bad
 
@nwp Like windows 10?
 
nwp
all windows suffers from that
 
7:35 AM
True. I swear cmd prompt is a slightly modified dos emulator
 
nwp
possibly windows 10 more so if that is seriously the last version
 
I need help in solving a recursive problem. May I ask here ?
 
I have posted but got no response.
They shifted me to math.stackexchange
 
so trees absolutely require pointers in C++? disappointing
 
7:37 AM
@Divanshu Patience is a virtue. If it's where to look for resources like algorithms, we can help you. If it's debugging, chat isn't the best place.
 
nwp
@doug65536 no. std::array + std::sort can make a thing that is basically a flat tree
 
Is it this one, divanshu?
-1
Q: How to convert recursive function into its mathematical form?

DivanshuI want to compute g(m,n) for some values of m and n without executing the below code. I have been trying for hours to find a way to convert recursive function into a mathematical function. There are some questions here related to same problem but most of them are about proving correctness of recu...

 
@nwp it is not fixed size
my variant type, which can hold a map of variants, is essentially a tree. you can't use an incomplete type with it apparently, but it seems to allow it for vector, although it isn't required to, is it?
 
nwp
use a vector then?
 
...
it is a variant. if it is an object, it is the map, if it is an array, it is the vector
needs both
 
Xeo
7:41 AM
@doug65536 According to the standard, all containers require complete types to work with
 
@Xeo yeah, but you can get away with it more with vector, misleading one to believe that it is okay
 
Xeo
@doug65536 check boost::recursive_variant
 
nwp
@Xeo they changed that in c++17 for vector, list and forward_list I think, need to look that up again
 
I have it fully working, but it sucks to have Variant* and new for the map and vector entries
 
@Aaron3468 Yes this one.
 
nwp
7:45 AM
@doug65536 can you make a MCVE?
 
1
Q: `std::pair` `second` has incomplete type with `unordered_map` tree

doug65536I was reviewing some older code of mine and I saw the code using pointers to implement a tree of Variant objects. It is a tree because each Variant can contain an unordered_map of Variant*. I looked at the code and wondered why isn't it just using values, a std::vector<Variant>, and std::unorder...

can't do better than pointers for vector or the map, if you use completely legal code?
 
Ven
@Xeo @Mysticial did either of you watch re:zero? Is it good?
 
Xeo
Mysticial did
I haven't (yet)
I'll prolly binge it when it's completed
 
@Ven re:zero?
 
@doug65536 boost containers has drop in replacements which do support incomplete types
 
7:50 AM
Ga-Rei? Fate? Or something else?
 
... I'm done for...
 
@Divanshu achille-hui tells you that the algorithm can be interpreted as f(m, n) = n + reverse(m) and g(m, n) = m << n so f('Hello', 'you') = 'youolleH', and g('hello', 6) = 'hello______'
 
@sehe sounds cool. I hate black boxes though. probably have blood come out of my eyes if I try to look at their implementation
 
Nah. They'll be lots better than your typicial std lib implementation. So, you'd be good
 
@Divanshu Just imagine the numbers as strings of digits ("12345")
 
Xeo
7:53 AM
@Mysticial Re:Zero kara Hajimeru? Or was it @Stacked that watched that?
 
@sehe I'll definitely look, thanks
 
I think I'm the only one here that's been watching the show.
 
@Xeo Oh. Yeah, it's on my to-do list.
Haven't gotten to it yet.
 
A trolley is careening towards an author of the "Overcoming Bias" blog. Do you go home and drink a beer or do you stand there and watch?
5
 
D:< I've had Big Order, Bungou Stray Dogs, and Mayoiga on my plate
 
Xeo
7:54 AM
Same, since I'm only watching animu with my buddy, who wasn't interested in it
 
@StackedCrooked Which subs are you watching?
 
The ones you hate :P (Horrible)
 
@doug65536 Bonus: get many c++11 features backported (and actually working stateful allocators etc)
 
@Aaron3468 Thanks. I will work in that direction.
 
It's....
.... It's too late.
I'm done for. =/
 
7:55 AM
almost 10 o'clock
 
Xeo
btw @Mysticial, are you watching Horrible for Kabaneri? Or is there another sub group that has it out on Fridays?
 
I need to re-install PC
 
@Xeo Doki.
 
Ven
@StackedCrooked oh, you're here still! Well, would you recommend it?
 
nwp
@doug65536 there may be a way to declare Union data; as just memory and use placement new to initialize it. a bit ugly but might work.
 
7:56 AM
currently using it in a stand alone mode
 
Xeo
Doki instead of Horrible rips eh... not sure if that's a wise choice :P
 
But I've been watching a lot of HorribleSubs lately since that's the only viable option.
 
@sehe I got an F in one of my classes. =/
 
Most of the fan-groups have either disappeared or slowed to a stop.
 
Xeo
Horrible is just ripping the official simulpubs anyways, so
 
7:56 AM
@Telkitty You:"My life's a mess" God:"Have you tried reinstalling?"
 
@nwp hmm, I wouldn't mind that too much...
 
Ven
@Telkitty no mice/keyboard/screen?
 
I'm on academic probation. 1 F means that I will be dismissed.
 
@Ven sure
 
Xeo
@Mysticial Ye, since official stuff has gotten "good enough"
 
Ven
7:57 AM
@StackedCrooked "a bit" or "it's good, go watch it"? (Idk how many episodes are out, it might be too early to tell)
 
@Aaron3468 I usually report to the lounge before trying to do things >_<
 
I know a little that this code is susceptible to buffer overflow. What else is wrong form a security point of view?
 
@nwp well I am doing that actually, already. Union is a union. right?
 
Xeo
1 message moved to bin
Aaaah, been a while since I did that
 
@Ven no interaction with other computers (i.e. server)
 
Xeo
7:58 AM
@Giovanrich Ask it on Code Review or something, maybe.
 
the sick, perverted effects of moderation
 
I mean a lone person can still have pet cats or dogs, a stand alone PC can have mouse/keyboard/monitor
 
@nwp oh did you mean aligned_storage and placement new the Union into that?
 
@Xeo Aah, thanks, had forgoten that
 
@Ven There's 6 eps. 7th coming out tomorrow. I love it, even though the last two eps were a little slower than the first ones.
 
Ven
7:59 AM
@LucDanton i'm sick and perverted, and I don't even have mod :)
 
Well, forums are better suited to thoughtful review and discussion. Chat is much better for relaxing, solving quick problems, and getting pointed in the right direction
 
Ven
@StackedCrooked okay, nice. I've been readig the manga for a while, and I just last night realized there was an anime when you talked about it
 
nwp
@doug65536 yeah, it's just annoying to declare the array because trying char data[sizeof(union)]; still causes the incomplete type issue
 
@Ven probably due to second-hand moderation effects
 

« first day (2037 days earlier)      last day (2911 days later) »