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

Ven
12:07 PM
template<> inline std::string toString(std::string) {}
// vs
template<> std::string toString<std::string>(std::string) {}
 
can any one give me some of the advanced c++ questions asked in an interview, i searched google getting the repeated thing. and also had read some of the interview question in SO , I need more......
 
@Ven the latter
 
Ven
@BartekBanachewicz does it actually matter, though?
 
not much i think
 
Ven
the former has no ODR violation thanks to inline.
 
12:08 PM
@Explorer_N I personally like "What's the difference between int a = 5;, int a (5); and int a; a = 5;. Then change int to T.
In C++11/14 you can also add a { 5 } to the mix, as well as a = { 5 }
 
yes to avoid those confusion Scott said its always good to go with the braced initializer
 
Ven
remember exactly the conversion rules, where they apply, and where they don't (i.e. template default values). Remember that GCC has a bug for this specific case. Then you're all set!
BasedScott
 
@Explorer_N but you can still be asked for other initializers on the interview
 
correct me if i am wrong -- a=5 (assignment), a(5) -- initializtion, int a;-- not default initialized; a=5-- assign ,, (change it to T)- no idea what does it meant
 
int a = 5; is not assignment
(don't you start loving C++ at this point)
 
12:15 PM
copy assignment?
 
no.
it's not an assignment
 
expression?
 
@Explorer_N I meant that first analyze it for int, and then for a user type.
@Explorer_N No. Back to your copy of standard.
section 8.5
 
@bertek .will do
 
@Explorer_N here,
 
Ven
12:19 PM
T a = T(); (or T a = 5;) is a bit confusing, because it requires a copy ctor, though it won't be called
@Explorer_N A a1, a2; a1 = a2 /* copy assignment */
 
@Ven Welcome to C++17, where copy elision is mandatory.
 
Ven
yeah, that's gonna be very nice
 
> C++
> very nice
 
That particular aspect is going to be very nice.
 
Ven
read: "much better than what we currently have"
I'd be happy when I'll be able to delete all of ours Foo::operator=(const Foo&){throw err;}
 
12:21 PM
@Griwes That's like saying a broken fiat multipla with a leaking engine is gonna get a new cup holder.
ITS A CAR ANALOGY
 
at least C++ records aren't as bad as Haskell records right
 
Ven
lol
 
:D
 
almost nothing is as bad as Haskell records
2
maybe it's because of the contrast with the rest of the language
 
Ven
12:22 PM
Rule #1: it's easy not to suck at something when you're plainly and simply not doing it :).
Rule #2: Please stop with the car analogies, bartek
 
but cars
 
Ven
you look more and more like Bart
 
@bartek, is that it( brace-or-equal-initializer:
= initializer-clause
braced-init-list)
 
it's some initializer alright
to be honest I don't really care what it is
 
12:28 PM
yeah, who cares about the little details which we would rather not remember.
But it was wonderful!
 
@Griwes approved already?
 
@Bartek, give me next Shot:)
 
I am pretty sure it is.
Marshall Clow and some other people seemed to be sure that it is voted in - I trust them :P
 
@Explorer_N template<typename T> struct S { static int x = 0; S(){ x++; }}; int main() { S<int>(); S<char>(); std::cout << S::x; } What will get printed?
 
nwp
@Griwes I think in standardese "voted out" means "is added to the standard". Which one do you mean, I'm confused.
 
12:33 PM
2, was it right?
 
nwp
@BartekBanachewicz my guess is a compilation error because S::x is missing a template argument
 
@Explorer_N nope.
@nwp yeah
 
nwp
should be S<int>::x or something
 
but the nicest thing there is the missing definition imho
 
yes, nwp right
yes there is wrong with a definition too
 
nwp
12:39 PM
I don't see a missing definition.
4
(well duh, it's missing)
 
it's invisible
 
@Bartek,next shot, i think we get along in PM.
 
yawn dunno
you could search for the posts litb made here
 
@bartek, litb in SO?
 
yeah
I'm too bored to think up C++ puzzles
 
12:46 PM
bored..?i think you get enough of it weren't you:)
 
Ven
bartek loves C++
 
nwp
slightly more than haskell records
 
I was planning on buying a fan
 
I am loving too, i was very serious with it than ain't ever before in other things
lol
 
maybe I could write something in typescript
like update Harvest-ts to new TS
also lol Cicada got banned?
 
Ven
12:52 PM
2 weeks ago I think
 
for what?
 
Ven
linking to islam.se before a mod
 
islam.se?
 
Ven
mash'allah
 
12:58 PM
alright.
 
@Ven lol really
 
Ven
yes
 
what was that about? beheading? rape?
 
lol
 
nwp
@Ven must have been a very racist mod
 
1:01 PM
religion is not a race
 
Ven
dunno
 
religion is a man-made social phenomena used to control dumb masses
 
may be it creates race
 
nwp
uhm... religionist? I don't know, something-ist
 
race is a set of genomes
oh cicada apparently linked to this
2
Q: Is fingering wife's vagina legal in Islam?

Abdul Raheem GhaniIs it allowed in Islam to enter fingers in wife's vagina? Please help.

 
1:04 PM
but anyway i don't think its good to be talkin about religion here?
 
Ven
where did you find that?
 
I didn't know it's forbidden to link other SE sites here
@Ven discord
 
Ven
hah
 
oh Gee
i am out
 
nwp
it is a bit NSFW
 
1:05 PM
@Explorer_N why? I can ridicule religion everywhere
 
nwp
is there a working spoiler tag thing for chat?
 
@nwp the whole islam.se is
I have no idea why the hell does that subsite even exist
frankly it's a huge turn-off for me from SE
we have sites like maths, physics, hell, skeptics
and then BAM "does this thing I have imagined in my head forbid me to do some sexual acts"
 
nwp
it seems like a good idea to put some objectivity into the whole Islam thing
 
"no dude I am totes imagining the same thing and the voices in my head said it's fine 10/10"
@nwp IOW nuke it from orbit
 
nwp
@BartekBanachewicz objectivity to prevent exactly this -.-
 
1:07 PM
to prevent what?
There's no objectivity in religion.
If you try to introduce reason it stops being a religion
That's like the very point of it.
Fooling yourself to make you feel better about your miserable life
 
nwp
feeling better about your miserable life has value
 
sure it does
but you can get to positive consequences in wrong ways
like, it's fine if you just talk yourself into believing you're gonna get handed 100 virgins when you die
what's not fine is telling that to children
and p much every widespread religion has this viral component present
It feeds in the souls of the living,
And gets inside their minds.
It transforms their brains and their longings,
No consciousness it will find.

It feeds on their fears and emotions,
As it has for two thousand years.
It's infected the Hindus, infected the Buddhists,
And kept them all in tears.
(the song is great BTW)
 
nwp
and sometimes you can get dumb brutes otherwise unstable people to behave better when you tell them "god says you should" rather than if you tell them "society as a whole made some rules that basically say you should"
but I agree that nowadays the damage outweighs the benefits
 
Like programming in raw C.
 
@nwp don't forget spreading homophobia
 
1:23 PM
@nwp voted INto the standard / voted OUT of the standard
 
Ven
wanna elope :[
 
@Ven That's great! Cheap way to get to one of the safest places of Africa :D
 
Ven
C'est une gare, ça sert à voyager
 
nwp
@Griwes does that mean you used IN as a normal person would understand it or as the standards committee people would understand it?
 
@nwp Everybody sensible says "voted in" for "the wording changes from the proposal have been integrated into the draft".
 
Ben
1:33 PM
I don't know what to say.
 
Ven
"hi" would be a good start
 
Ben
hi
 
Ven
hi :)
 
@BartekBanachewicz Know of any IT companies in Łódź that could want to hire somebody as an "Operating System Developer"? Got a generic recruitment email for that and I'm wondering who might be these guys' client. (Any other Poles - we need a mention for that, dammit - do suggest what that might possibly be if you have any clue.)
 
More importantly who'd like to live in Łódź
 
1:35 PM
The offer itself isn't really an interesting thing considering my plans, but now I need to know what that company is. :D
 
I know the city is apparently changing and stuff but
 
Ven
what's wrong with it?
 
it's sad
 
I'm primarily curious who the heck is that, since the market for actual professional "Operating System Developers" is not very big.
 
Ben
@Griwes what about SoC development, or something similar?
grammar
 
1:38 PM
@Griwes it is in embedded
 
Well, you could probably count somebody writing Linux drivers as "opsys dev", but that's an overstatement :P
> Kluczowa wiedza i doświadczenie na tym stanowisku:
- Wiedza z zakresu Operating System development.
- Doświadczenie z Embedded
- Znajomość Assembly
- Bardzo dobra znajomość języka Angielskiego
 
yeah, embedded
 
(I love how the languages are mixed. Just send me a fucking email entirely in English, you morons.)
 
Ben
should I learn Polish?
 
it's prolly making toasters for PIC
 
1:40 PM
Fuck knows.
 
Ben
SO is boring, and I don't have anything else to do besides sleeping.
hmm
 
@Ben Masturbate.
 
Ben
@Mystical have you used your hardware for doing precise physics simulations?
@wilx Its overrated.
 
Ven
how2security of related models in a DAO. someone could send a related USER somewhere and we need to check for permissions...
 
@Ben :)
@Ven Don't you do this at service level?
Well, I do not know. Disregard what I have said.
 
Ben
1:59 PM
Is everyone familiar with the NCSA Blue waters supercomputer, and some of the things it computed?
@wilx I tried to initiate a conversation and it has failed.
 
user1804599
@Ven dynamic scope
 
nwp
@Ben make a game, show @rightfold how it's done
 
@Ben Sorry, that line was continuation of my reply to Ven. :)
 
Ben
@wilx oh, that wasn't related to Ven's comment. :)
@nwp I've made draughts.
@nwp what sort of game?
RTS, MLP, etc ?
 
nwp
@Ben a rougelike dungeoncrawler 3D action mmorpg
with pets
 
Ben
2:13 PM
@nwp pokemon?
 
nwp
close enough
 
any name collision/clash experts around?
http://stackoverflow.com/questions/37393414/name-collision-between-c-library-namespace-and-c-linux-function
 
It hard to imagine what would happen with his hands if it was real
https://www.instagram.com/p/-e3chUvflq/
 
@nwp meta is a header only library so the wrapper is going to have to include the original meta resulting in the same errors as in the workaround B
a wrapper around ncurses is going to face similar issues since the library defines some global constants in its header file
 
don't include the header file
 
Ven
2:22 PM
@rightfold it's a vaaast topic
 
make a separate .cpp file and write all the forwarders there
 
nwp
@gnzlbg Why is that? Just copy all the functions, rename them, implement them by forwarding them to the real thing. I don't see why you have to include either header when you have wrappers.
 
@milleniumbug yep for ncurses I could try to write a wrapper that in the header doesn't include the <ncurses.h> header file
@nwp meta is a metaprogramming library
it is header only, only templates...
 
nwp
so?
 
the wrapper is going to end up being a metaprogramming library as well, that is going to forward meta's code
 
2:23 PM
I mean the ncurses library
 
both things need by definition to be in a header
@milleniumbug that might work
wrapping ncurses might succeed as long as I can initialize constants inside the TU
 
nwp
in a header yes, in a header of the same translation unit no
 
@nwp it has to be a header of every translation unit that uses it
all its code must be in a header file
 
You deal with such headers just like with any other badly behaved headers, like <windows.h>
 
user1804599
2:25 PM
@Ven nice :)
 
@milleniumbug my issue with ncurses global constants is that while I can write a wrapper that doesnt include it in the header, i am going to have to define global constants in the header, that then i am going to initialize from the ncurses values inside the TU
for this to work the values of ncurses must be initialized before the ones of my wrapper
and AFAIK the order of initialization for static globals is undefined
 
user1804599
type Input =
    { w: Boolean
    , a: Boolean
    , s: Boolean
    , d: Boolean
    }
 
nwp
@gnzlbg no it doesn't. That is the point of the wrapper. You include the wrapper header without the real thing. Inside the wrapper.cpp you include the real thing and forward stuff. You can thus replace the real thing with the wrapper header and thus avoid name collisions.
 
@nwp meta has no .cpp
its like Boost.MPL
 
@gnzlbg I don't think this matters since it's a C library
You can't have non-trivial initializers in C
 
2:27 PM
meta is a C++ header only template metaprogramming library
@milleniumbug I see, yep
wrapping ncurses is probably the best bet
 
otherwise you can initialize manually
If it's global, I make initialization manual
Static initialization order fiasco is just too annoying
 
@Xeo No. I was gonna go back on Sunday for the half-day, but I stayed up all night playing Akiba's Trip. And I needed the rest of Sunday to correct my sleep schedule for work on Monday.
No I'm not going to AX. I went to ACEN because I live in Chicago.
 
@Mysticial Apparently y'all broke the elevator
 
nwp
I am hungry and there is free cake. Damn social awkwardness.
 
156 upboats!?!?
 
nwp
massive upvotes upboats and put on hold
typical SO
 
Ven
@Borgleader It's a very, very, very good read.
And obviously someone (lol madara) locked it.
 
user1804599
movePlayer dx dy s =
    let x = s.player.position.x + dx
        y = s.player.position.y + dy
     in if isObstacle (worldTile x y s.world).tile
            then s
            else s { player = s.player { position = {x, y} } }
 
user1804599
:3
 
Ven
2:47 PM
y u no lennyses
 
nwp
> This post has been locked while disputes about its content are being resolved. For more info visit meta.
why link to meta main site and not the actual post discussing the issue? -.-
 
That's vexing, yes
Also bad UI
 
user3790646
Good morning (:
 
user1804599
ok so I had this idea
 
user1804599
the loot you get in rooms depends on how far that room is from the starting point
 
user1804599
2:52 PM
so later in the game you get different stuff
 
nwp
@rightfold make it "how far on the path the player took" so that it is less geography sensitive
 
user1804599
no
 
user1804599
because you can go back and you can go in circles
 
nwp
yeah, you can, but every time you enter a new area it gets progressively harder no matter which order or how far from spawn
don't want noobs to go straight and die horribly and advanced players go in a spiral for optimal progression
with tons of running back and forth if the map doesn't actually allow you to go in spirals directly
anyone know what the numbers are? The 6 big ones are probably posts, what is the 2 and the 1644?
(inb4 secret key to delete the account)
 
hover over them
 
nwp
3:04 PM
oh...
 
@Ven Ok that was a very cool read (minor downside they basically did his homework for him)
I wish I had that as a homework assignment
 
nwp
@Borgleader what is with FurReflect++? Is that just an abandoned idea?
 
@nwp why are you asking me that?
 
Ven
@Borgleader right? it's amazing
 
nwp
@Borgleader I happened to click on your portrait and it listed you as the room owner, so I thought you'd probably know.
 
3:12 PM
@nwp Oh, it's @ThePhD's thing.
Haven't heard of it in over a year.
 
user1804599
 
user1804599
imma be rich
 
@sehe C'est de même qu'on roule ici.
 
user1804599
 
user1804599
 
user1804599
3:26 PM
thanks obama
 
At least obama's one applies to more than just a handful of people...
 
user1804599
thanks kennedy
 
user1804599
@sehe would you mind translating this to English?
 
user1804599
because I totally CBA
 
@betarunex Only a few people actually landed on the moon--but the effort to do that affected the entire country, and indeed the entire world. We probably wouldn't be using this Internet thingy right now if it weren't for the moon program.
 
Ven
3:35 PM
@rightfold they don't even mention racket. SHAME
 
Just did two pentakills
 
user1804599
 
Best game of all time
 
user1804599
@BartekBanachewicz all of C++ is
 
Ven
ah, they mention racket in the guide. good!
 
user1804599
3:46 PM
you can walk around now :)
 
user1804599
next step is rendering the inventory, XP, and HP
 
Ven
4:00 PM
@rightfold back from work already?
 
user1804599
week off
 
Ven
oh, have fun
 
user1804599
> This demonstration is extremely, extremely dangerous. -- If you touch ANYTHING (wires, transformer, wood... anything!) while its plugged in you will be ELECTROCUTED and DIE -- PEOPLE HAVE DIED from microwave transformers -- all it takes is one mistake -- YOU DONT GET A SECOND CHANCE.....
 
user1804599
dat warning
 
Ven
Jesus got a second chance. Why can't I?
 
nwp
4:08 PM
@Ven not even god loves you
 
Ven
mmh, anyone know of a good C++ JSON schema validation lib?
@nwp yeah, but at least I didn't die for crap reasons
 
@Ven So far, you haven't died at all. When you do, chances are it won't be for any particularly great reason though.
 
nwp
@Ven getting electrocuted when playing with microwave transformers is certainly better than whatever jesus did
 
wat
http://www.theverge.com/2016/5/22/11723418/airbus-apworks-light-rider-3d-printed-motorcycle
 
Ven
@nwp yeah
 
4:20 PM
@nwp It's currently shelved while I work full time on getting Sol2 to its theoretical maximum performance.
 
nwp
4:40 PM
@ThePhD oh, is it better than luawrapper?
 
user1804599
oobleck is super rad
 
Yes.
And luawrapper is not being actively developed.
 
nwp
I think I'll try it out
 
It's being JUST BARELY held together by the maintainer, Mr. Hubert.
I already submitted a PR for them to fix an ICE in VS 2015
... Which they have not yet accepted.
 
user1804599
5:00 PM
> Dijkstra's self-confidence went together with a remarkably modest lifestyle, to the point of being spartan. His and his wife's house in Nuenen is simple, small and unassuming. He did not own a TV, a VCR or a mobile telephone, and did not go to the movies. In contrast, he played the piano well and, while in Austin, liked to go to concerts. An enthusiastic listener of classical music, Dijkstra's favorite composer was Mozart.
 
user1804599
@sehe is literally Dijkstra
 
user1804599
> Woman Trying to Prove ‘Vegans Can Do Anything’ Dies of Altitude Sickness on Mount Everest - not the onion
 
@rightfold Well, non-vegans also die of that there. But yeah, it is sort of funny.
 
user1804599
Non-vegans can also do anything.
 
user1804599
5:14 PM
> A Chinese woman sentenced to life imprisonment for corruption in the Xinjiang Autonomous Region was able to evade a prison sentence for a decade by adopting a novel, if slightly extreme, tactic - getting pregnant 13 times before finally being sent to jail by a court.
 
I need to convert the data from SVG path object to a polygon ;_;
 
@rightfold that makes two of us
 
user1804599
:(
 
@rightfold Eww. :D
 
5:47 PM
Anyone here knows probability theory?
 
nwp
probably not
 
probably
 
maybe
 
My question is pretty basic. I have three random variables A B and C - I know COV(A,B) and COV(B,C) (and the correlation too), I need to say something about COV(A,C) without actually calculating it.
 
almost surely
what's COV?
 
5:51 PM
covariance
 
user2872568
6:16 PM
Hey! Is anyone here knows vulkan a little? I need to ask something but SO chat room for computer graphics is empty(((
 
nwp
 
user2872568
It's reaaaaalllllyy little.
 
user2872568
)
 
user2872568
But Okay, I will in 5 minutes if noone will answer for help
 
Next up, DirectX needs to re-brand itself as Klingon.
 
user2872568
6:20 PM
Sarcasm detected
 
@BartekBanachewicz teamspeak?
 
Hope you don't do C++ game dev for money
 
Jan 30 '15 at 2:30, by Borgleader
"Hi I have a question about my retirement fund"
"Sir this is a convenience store..."
"I know but it's the only thing open at this hour"
 
user2872568
@ProblemSlover okay.. Hope you don't do C++ for money
 
user2872568
What's purpose of this hopes?
 
6:26 PM
He hopes you do it out of passion.
Because if you don't, C++ will slowly kill you from inside.
 
user2872568
Ah okay, nah, just tryin to create really fast and small engine based on vulkan in my free time.
 
user2872568
0
Q: VK_KHR_WIN32_SURFACE_EXTENSION_NAME is not defined

WarezovvvI learning Vulkan by Vulkan specifications and Sasha's examples. Now I have a problem, VK_KHR_WIN32_SURFACE_EXTENSION_NAME is not defined, but everything works fine, when I click with left ctrl pressed on this define, it's shows as #define VK_KHR_WIN32_SURFACE_EXTENSION_NAME "VK_KHR_win32_surface...

 
@BenjaminGruenbaum The short answer is that you know nothing about it. For a trivial example, consider flipping a fair coin 100 times. B is the number if times you got heads out of that 100. A is the number of times you got heads in the first 50 flips, and C is the number of heads from the second 50 flips. A and C are each correlated to B, but there's no correlation between A and C at all.
 
don't dump questions here
 
user2872568
Okay sorry
 
6:30 PM
In page 361 of Shaffer people.cs.vt.edu/shaffer/Book the code has an EMPTYKEY which doesn't seem to be defined anywhere? Is it a constant like NULL? Do I define it as null?
In the constructor
	TTNode() {
		center = left = right = NULL;
		lkey = rkey = EMPTYKEY;
	}
 
user3790646
Hey everybody. :)
 
@sehe ideas a spreading, here’s a Rust parking_lot
2
 
user3790646
@Warezovvv You should check google before asking a question, see my answer
 
@LucDanton Oh is that Rust version of Webkits new locks?
 
that is a lot of comments but where are the tests?
 
user2872568
6:38 PM
@AndreyErick thanks Andrey, that's worked, where did u get about preproc derictives? In specification I got nothing about VK_KHR_WIN32_SURFACE_EXTENSION_NAME.
 
user3790646
Searching for that enum on google. stackoverflow.com/questions/36188202/…
 
user2872568
Okay, thanks again. I just mean that it's strange that Vulkan spec is not full, isn't it?
 
user3790646
@Warezovvv From what I know it's still a new graphics API, that's normal, I think
 
Ell
@BartekBanachewicz I'd donate it to some free project probably :P
 
@jefff is a fitness enthusiast, apparently
@LucDanton Coolitude
9 hours ago, by sehe
> I received $57.36 - surprisingly as LC doesn't take provision http://support.livecoding.tv/hc/en-us/articles/213510808
If it were interest-related it would have gone the other way, just saying :)
reference?
They blamed Paypal - probably rightfully
Doesn't quite remove the fact that they took ~8 months to make the transfer :)
 
user3790646
6:49 PM
@sehe Please, sehe, I've been struggling with a problem, could you help me out?
 
Ell
not a reference but wow
 
user3790646
 
shall I buy wireless pc mouse/ kyboard?
 
user3790646
@sehe The for loop in main.cpp only runs once, after that it's like it's blocked. I've tried putting a continue in the end and then it crashes. It's probably related to threading
 
Great
@AndreyErick erm. What's the reason you can't post on SO? I didn't see a question the other day
 
6:51 PM
looks like majority manufactures focused on producing wireless stuff
 
user3790646
I deleted it ;-;
 
Makes a lot of sense.
o.O ?!
 
user3790646
Okay, I'll post it in SO
 
@Ell I hadn't expected people would throw money at streamers. I didn't even know they could until I got $10
 
sup lounge
 
6:53 PM
@sehe You got money from LC? neat
 
> You didn't NEARLY do Dwarf Fortress justice in this short video. But I don't blame you, it would require a full feature movie to do so. It's the best game ever created in the history of mankind.
> This game looks absolutely terrible, I don't understand anything at all what it's about, and I already see fanboys in the comments saying things along the lines of "if you don't like it you're a terrible gamer and should kill yourself."
like the contrasting comments :)
 
@Borgleader Technically, no. I got it from my viewers
 
@sehe That's what I meant
"You got money through streaming on Livecoding"
 
@fredoverflow looks like the game has been done out of "passion"
 
6:54 PM
Much like Twitch streamers
 
Frustrated User Experience ..this is hilarious and pretty darn accurate
 
@ProblemSlover Is that a bad thing?
 
user3790646
There it is, @sehe .
 
@fredoverflow well it depends on
 
passion?
 
Ell
6:59 PM
@sehe it's a nice surprise I guess :)
 

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