« first day (739 days earlier)      last day (4221 days later) » 

8:08 AM
accumulate<range_c<int, 0, n>, T, lambda<_1, _2>> where lambda<T, whatever>::type is typename T::ChildT should do the trick, using Boost.MPL.
Or just lambda where typename lambda::template apply<T, whatever>::type is the same I suppose.
Actually I think I got the order of parameters wrong.
@NeelBasu There you go.
 
@Luc regarding last night's discussion, would the definition of "multibyte character" on §1.3.13 ("sequence of one or more bytes representing a member of the extended character set of either the source or the execution environment") answer this? chat.stackoverflow.com/transcript/10?m=5919395#5919395
 
8:23 AM
Last night is still this night. Ish.
 
It's 9:23.
Ok, I guess "no".
> The values of the members of the execution character sets and the sets of additional members are locale-specific.
Or "yes".
I'm just going to say that I'm horribly confused.
 
The robot is confused???
how is that even possible?
I thought you were never confused!
 
If chat search worked I could show you lots of times that happened before just in this room.
 
lol
I was trying to wind you up
and I obviously succeeded
 
I am not a windup robot.
 
8:27 AM
:P
I have a problem being motivated
it really sucks ass
 
Which reminds me of...
 
this shit doesn't even remotely interest me
 
I want to do something interesting
 
Nice book.
 
8:30 AM
Oh, the r in e.g. mbrtoc16 means restartable. I was wondering earlier.
 
This time they made no non-reentrable versions.
 
Well they're a twofer: pass NULL instead of a pointer to mbstate_t.
 
I don't see where that is allowed.
 
@R.MartinhoFernandes 'The Windup Girl' - heh, maybe a bit wasted - no Cicada yet today, unless busy trolling W8:)
 
> If ps is a null pointer, each function uses its own internal mbstate_tobject instead, which is initialized at program startup to the initial conversion state; the functions are not required to avoid data races with other calls to the same function in this case.
For <uchar.h> at least.
 
8:33 AM
@MartinJames ? How's Cicada relevant? Just because she's a girl?
 
@R.MartinhoFernandes Cicada = epic troll
morning all
 
Yeah apparently <wchar.h> doesn't have that.
 
though she does seem to have eased of recently
 
@R.MartinhoFernandes 'Windup' or 'wind-up' - to troll, (maybe just UK idiom?).
 
8:35 AM
oh yeah, non english
 
By the way how does one initiate an mbstate_t object? The badly-named mbsinit is to check whether such an object is in an initial state.
 
The title refers to this usage of term en.wikipedia.org/wiki/Wind-up_toy, so I didn't make the connection.
@MartinJames Hmm. Now I see that the tile may be a pun. Thanks :)
@LucDanton Default construct?
 
@R.MartinhoFernandes In C?
 
Haha, no. Zero-init is = { 0 };. A stray mention of mbstate_t suggests that this is indeed appropriate, although I'll keep looking for the exact requirements/description of mbstate_t.
 
8:40 AM
@R.MartinhoFernandes Usage: "OK, I'm off to windup those morons in the PHP room".
 
And now the morons are woundup?
 
Well std::mbsinit(&mbs) does return 1 for a value-initialized object, with GCC.
 
@R.MartinhoFernandes Sadly, no. I don't have enough PHP, (praise be the Lord), to wind them up myself. I'll leave it to the experts. You have the idiom right, though:)
 
@jalfd Some compilers on DOS/Windows did cut <strstream> to <strstrea>, due to the 8 chars limit to file names. That helps me remembering.
FFS.
 
> A zero-valued mbstate_tobject is (at least) one way to describe an initial conversion state.
 
8:44 AM
@Luc I'm not entirely sure this is the right question, but I posted anyway:
0
Q: What encoding does c32rtomb convert to?

R. Martinho FernandesThe functions c32rtomb and mbrtoc32 are described in the C Unicode TR (draft) as performing conversions between UTF-321 and "multibyte characters". (...) If s is not a null pointer, the c32rtomb function determines the number of bytes needed to represent the multibyte character that cor...

@LucDanton Ah, cool. My current code assumes all encodings can use a trivial type for state and value-initialize it.
 
It's in 7.29 <wchar.h> alright, but 7.29.6, not 7.29.1 Introduction which describes that mbstate_t is defined. Because that would make too much sense.
@R.MartinhoFernandes You already have a tag for it, but I think that mentioning uchar.h in particular might help for potential searches.
 
FWIW cppreference.com does say "In any case, the multibyte encoding used by this function is specified by the currently active C locale. "
 
Which is one of the native encoding, in C-speak.
Another way to formulate your question is "is it conforming that the result be encoded with UTF-8 even if this does not correspond to the current locale", I think.
 
Btw, what's the C99 draft you have/the latest (need to download again since the one on the other disk is gone)?
 
n1570, which I think is either FDIS or pre FDIS or the C equivalent to that.
 
8:55 AM
Oh, that's C11.
 
Yes, it's the final draft.
 
I guess it will do.
 
Oh sorry. I don't think I have C99.
 
Oh, wait, I know where I can get his information.
 
Ya I don't have it.
 
8:57 AM
@R.MartinhoFernandes: The latest C99 draft is N1256. It has <wchar.h>, but there's no `<uchar.h>'. — Keith Thompson Sep 27 '11 at 0:29
:)
 
Totally obsolete cruft.
 
Erm, why?
The C++ standard refers to C99, not C11.
(And it refers to the Unicode TR for <uchar.h>)
 
The languages are still in lock-step though.
> The final draft, N1570,[4] was published in April 2011. The new standard passed its final draft review on October 10, 2011 and was officially ratified by ISO and published as ISO/IEC 9899:2011 on December 8, 2011, with no comments requiring resolution from participating national bodies.
 
You know what's annoying? These things were described in a ISO TR in 2004, and eight years past, no compiler has them yet (ok, maybe libc++, I haven't tried).
 
The SC doesn't deal in time travel I think.
I'm more outraged by the lack of support for _Generic.
 
9:01 AM
Really?
Why would you need that? Are you doing C?
 
I don't and I don't. But it's an outrage!
 
Ok.
I have a feeling I'll have to put a bounty on that question, and that it will go to waste.
> Were natural languages designed by bigots to make others into bigots? Only time travel will tell :-) :-)
 
Yeah, how come I don't use bounties myself. Those things help a lot don't they?
 
They've worked well for me the two or three times I've used them.
Dammit, it was the wrong question: stackoverflow.com/a/13046108/46642
 
9:22 AM
The fuck is the point of an iPad mini???
 
It's an iPad, but smaller.
@TonyTheLion Is that a thing?
"Must show demonstrated experience implementing cargo cult antipatterns" Someone played a funny joke on their HR department it seems.
 
it's a smaller, more discreet consumption device - wait, that's the Tampax press release, hold on....
 
@R.MartinhoFernandes it is a thing, unfortunately
@TheForestAndtheTrees it's a waste, that's what
 
@TonyTheLion Well, I'm not qualified to answer. I don't see the point of a tablet for the general public anyway.
 
@R.MartinhoFernandes Well they have their uses. Example: My mum was never able to use a computer, she just got confused, now she has an iPad and it enabled her to surf the web and use email. Perfect and valid use of a tablet.
 
9:30 AM
@R.MartinhoFernandes Poor souls. I'm sure they fell for that like leading a blind man into a wall.
 
@sehe image found
 
@TonyTheLion Fixed
 
Work blocks that site, clearly it doesn't want me discovering the matrix
 
1101100100001111010101000100000001000010100000000000100001011111
64 bits ^
it's long...
 
9:40 AM
dat pun
 
what you up to today?
 
in theory, very simple a quick bit of work
in reality, vast amounts of procrastination
I see there was a load of commotion about IDEs last night
 
9:56 AM
donno
wasn't paying attention
don't care either
 
@thecoshman You are overstating it a bit.
 
It's amusing how much people care how others write code :D
@R.MartinhoFernandes am I? the transcript is rather long, and seems to get rather heated
especially considering how trivial a subject it was
 
It was definitely not heated.
 
if you say so, it just read like that to me
any hoops
 
a Java developer that thinks OOP isn't overrated.
 
9:59 AM
are you going to start up kyrostat stuff again? Just wondering
 
how unsurprising
who me?
 
I was meaning the robot, but you too I guess
 
@TonyTheLion It's actually underrated: it's crappier than how crappy people rate it.
 
@R.MartinhoFernandes ah lol. In that way.
 
@TonyTheLion The suckiness of OOP is not overrated.
 
10:00 AM
OOP is not a terrible idea, it's just not the only trick in the box
 
@R.MartinhoFernandes meh
 
@thecoshman I may work in text rendering.
 
I would hate to see a man who whips out OOP for some sort of backup script
@R.MartinhoFernandes would you carry on with unicode stuff you where looking at?
 
Jan 31 at 4:16, by Ethan Steinberg
OOP is overrated anyways.
this is where I got it from ^
 
@thecoshman I would need to shop around for decent existing libraries and see from there.
 
10:12 AM
The problem is thinking that the term OOP is interchangeable with the words "best idea ever"
 
Like anything else, it's just another tool at your disposal
Even the existence of goto has some inherit value, if for no other reason than to know that I shouldn't use it
 
lol
in asm goto is useful
beyond that, it's not
it's just a really low level concept somehow brought into higher level languages
 
user1182183
@Neil I always used goto to make many random values and make sure none is the same, however if only 2 values then if the second value is the same I always do -1 if value => 2 or else +1
 
Xeo
@TonyTheLion In asm, there is no goto, only jmp ;)
 
10:14 AM
@Xeo whatever, pedant. You know what I meant
 
Xeo
@GamErix Wait, why do you need goto for that?
 
Xeo
@TonyTheLion 'scuse me, we're in the C++ room!
 
The sky
@Xeo oh yea
forgot :P
 
user1182183
int a = random();
:labelB
int b = random();
int c = random();
if a == b goto labelB;
etc...
 
10:15 AM
@GamErix I'm sure you have your reasons, though I'm sure you don't actively look for reasons to insert gotos into programs, I hope
 
I don't see any goto in that.
 
@Xeo a jmp by any other name would be just as jmpy
 
Tell me I'm not going blind!
 
goto home;
is my favorite command
 
@R.MartinhoFernandes "I'm not going blind!"
 
user1182183
10:16 AM
ofcourse you can use while...
 
jnz eax
 
user1182183
in my case
 
Xeo
@GamErix So why didn't you?
 
user1182183
@Xeo finally I did :P
 
@Xeo He's living on the edge
 
user1182183
10:17 AM
@Neil yep
 
I'm sure he rips the tags off of pillows too, just for the thrill of it
 
user1182183
@Neil HOW U KNOW THAT?!
 
@GamErix :)
 
user1182183
:p
 
user1182183
kinda fun when trying to drink something and all the basses around me are at maxx
 
10:18 AM
"Must show demonstrated experience implementing cargo cult antipatterns" Someone played a funny joke on their HR department it seems.
ROFL
Oct 4 '11 at 19:23, by R. Martinho Fernandes
Overrating is overrated.
Apr 6 '11 at 15:09, by Chris Becke
generic programming is overrated
 
Oh gawd, Chris Becke.
That guy was... annoying.
2
 
Jun 7 '11 at 16:55, by Cat Plus Plus
room topic changed to Lounge<C++>: Because sanity is overrated.
 
@sehe Fortunately he left while I was still lurking, I think.
 
@R.MartinhoFernandes I don't think I ever met him.
I wasn't even lurking at that time.
 
10:24 AM
@ScottW Lounge<C++> Considered Harmful
 
My tan is fading. Need vacation.
 
just break the door open on your microwave
I guess you could rest a 5gHz WiFi repeater on your desk as an alternative
 
I need better photons than that.
 
@thecoshman you haven't looked at powershell, have you? ;)
 
No - before anyone says, not going near any X-ray machines or gamma sources anytime soon, (hopefully, anyway:).
 
10:27 AM
I guess a cyclotron isn't that difficult a project if you've got the machining tools
 
..or any sort of particle accelerators.
 
isn't a cyclotron basically a scaled-up flyback driver?
 
@Luc Would you say that this program ideone.com/69xZrZ can be used to make the right question be simply "can the assertion in this program fail?"
 
two coils on a core; wheeee
 
@rvalue Needs boost
 
10:29 AM
boost::cyclotron<>?
 
Hi guys
 
Whadup, kbok?
 
@jalf oh I know you can do very powerful shit with it, but you still don't need to write an OOP to run a few backup commands... unless you have a seriously crazy back up system :P
 
@rvalue Boost - flyback driver, (commonly, in the past).
 
Not much
I see there's Win8 demos all around the world
I entered caveman mode until the one in Paris on friday :p
 
10:31 AM
@ScottW My moon flight system automatically destroys the Earth in case a backup is made.
Wait, that was supposed to be a secret.
 
@thecoshman My backup/restore system has classes for backup to different stream types, including backup/transfer to another, identical app on another, reachable, machine.
 
@ScottW You're dead.
 
@MartinJames nice, haven't run across that usage before
 
@MartinJames (╯°□°)╯︵ ┻━┻
 
@MartinJames Sounds like what you've invented there is some form of clustered file system
 
10:34 AM
@rvalue In Portuguese we have this expression about "having one's feet firmly set on earth" meaning that one is grounded in reality. I was going to make a joke out of that. Is there something similar in English?
 
@R.MartinhoFernandes we have the same in English
 
@R.MartinhoFernandes Indeed, having one's feet on the ground.
 
Well, consider the joke made then.
 
@ScottW My valuable data is actually flying to different parts of the universe on old fashioned vinyl phonographs.
This way, any extra-terrestrial intelligence will obviously notice the relevance and make sure (a) I get salvaged from the crumbling remains of the rock-that-once-was-Earth (b) I get my data back, in whatever usable media the other "species" is able to utilize.
 
TIL explaining the joke before telling the joke doesn't work.
 
10:35 AM
@sehe I used gold.
 
@rvalue The user of other app has to accept the transfer - it is offered on a popup. It's useful to be able to clone a customer-in-trouble DB onto my box.
 
@sehe You're dead.
You meatbags seem to have trouble understanding that part.
 
@MartinJames That would be handy
 
@R.MartinhoFernandes how do you back up your self?
 
@thecoshman my point is that it seems like it is very much designed around the idea of OOP (for some crazy reason)
 
10:36 AM
@thecoshman mitosis (en.wikipedia.org/wiki/Mitosis)
 
Apr 12 at 10:33, by sehe
@thecoshman some people even call stack overflow a cloud app: hey, am I not the only one using SO as a backup server by storing 4K blocks of base64 encoded blobs inside post inside <!-- comments -->. Cloud storage FTW!
 
Tbh, I think it's better than around text streams.
 
@R.MartinhoFernandes Yes.
 
@rvalue gitosis with MIT?
 
@jalf ah, I was vaugley aware that they allowed such stuff
 
10:37 AM
@rvalue aha
 
@rvalue The target app makes a backup of its own DB first. Mainly 'cos the transfer is not particualrly clever and is likely to majorly screw up if the connection to the source app is lost mid-way. This borks the target box 'cos it only has half a DB and won't start. Needs manual cleanup & local restore of the backed up files:(
 
@sehe The thing is, if you do that, you probably are indeed the only one.
@thecoshman Is that meant as an honest serious question, or a joke about the tin can nature of my online persona?
(IOW, do I need to answer that or laugh?)
 
@R.MartinhoFernandes both
 
@MartinJames Looked into any filesystem support for snapshotting it, or is it the transfer that interrupts it?
 
oh Java, how your failed memory management model makes me laugh
 
10:41 AM
@thecoshman Hey, it works just fine.
... so long as you think throwing an OutOfMemoryException is a better decision than running the garbage collector.
 
@rvalue .dsetroy() .clear() .empty() .try_to_release_some_memory_because_Java_has_no_idea_how_to_use_a_stack()
 
@thecoshman s/management//
 
@rvalue It's just not very clever at all, but it works, (mostly). The integrity of the database is maintained during the a transfer by documentation: 'UNPLUG THE CANBUS NETWORK AND DO NOT ENTER ANY DISPENSES WHILE THE TRANSFER IS IN PROGRESS' :)
 
@Cicada the language is a Joke, enough said
 
@thecoshman Yeah, I feel your pain. We have a deeply recursive algorithm that chews tons of heap space in short-lifecycle objects that aren't used outside of the current iteration
 
10:44 AM
@Cicada and greetings
what really baffles me, is how some of the code here is able to overflow the stack... Java hardly touches the stack, how can it overflow? The heap sure, it shits all over the heap, but the stack?
 
@thecoshman We had to split it pretty nastily to get it to free one iteration before starting the next
 
'mornin. It seems to be OOP and java bashing day.
 
@thecoshman Backup is really simple for me, because I don't keep much digital baggage on my hard drives. No photographs, no important documents, no nothing. I have most things strewn all over the interwebs: code on GitHub/BitBucket/whatever, about 6 megs of text files and pictures on DropBox, save games on Steam. I think the only thing I backup to physical media are my SSH keys.
 
@MartinJames aka, a day
 
@thecoshman :)
 
10:46 AM
@thecoshman Hibernate chews tons of stack space through proxy objects & invocations
 
@rvalue Be glad those objects don't have finalizers.
(They don't have finalizers, right?)
 
@R.MartinhoFernandes That's what C++ is for ;-)
@thecoshman -XX:MaxPermSize=256m
 
@thecoshman Still used for locals
 
The Java solution is almost always "throw more memory at it"
 
@rvalue Nah, what I meant was that objects with finalizers require two collection cycles to be collected.
Creating lots of them very fast is a recipe for OOM.
 
10:48 AM
@R.MartinhoFernandes Mark-and-sweep GC?
 
@Cicada yeah, but they hardly use up that much space, it's only references on the stack, and primitives, but they are teeny tiny
 
A java object on the stack, (or anywhere) is one pointer, IIRC?
 
@thecoshman deep recursion can overflow pretty fast
 
@MartinJames Yeah, all Java "objects" are pointers
 
@MartinJames Yeah, pretty much. Other than primitive types.
 
10:49 AM
@rvalue wooh! you can't just go changing things like that. Don't you know how shit enterprise work is?
 
@thecoshman Tiny × infinite recursion = stack overflow
 
@thecoshman That's what our installer puts in the service arguments ;)
 
@MartinJames indeed, the actual object is on the heap
 
@rvalue Basically, they're two objects: the object itself, and a finalizer registration or something. And for obvious reasons one of them keeps a reference to the other.
 
@Cicada yeah I guess, but recursion sounds like to complex an idea for this place to have used
 
10:50 AM
@thecoshman yeah - it's like Delphi, (except Delphi has no GC).
 
@thecoshman A standard stack size is 1MB you know. That's not much
 
@R.MartinhoFernandes Pretty much the same as boost/std::shared_ptr
 
@Cicada really? that's teeny tiny
 
And the finalizer registrations can only be collected after the collection cycle that collects the object, because they have to be run first.
 
(but GC'd)
@R.MartinhoFernandes hehe... hehehheehhee
 
user142019
10:51 AM
@FredOverflow Wat. That fool actually includes <vector>. Why doesn’t he use it?
 
Java.
 
@thecoshman Yeah it's around that. 512k - 2MB. In .NET the default is 1 MB.
 
So you can actually create throwaway objects faster than the GC can collect them.
 
@Cicada I notice you have been distinctly less sarcastic recently. Is your sarcasm some sort of reflex reaction to not like shitty education?
 
It's as ridiculous as it sounds.
 
10:52 AM
@thecoshman You're probably just getting used to it and you are decoding it transparently
 
@Cicada I think your crusty shell is breaking away :P
 
@thecoshman I honestly doubt it. I can't help being sarcastic! I don't like shitty education either.
 
@R.MartinhoFernandes 1MB - 250K objects. That's a lot of throwaway objects:(
 
@thecoshman I like how the word "enterprise" has been co-opted to mean "we have no clear spec and the rules are internally contradictory"
 
@thecoshman I'm just being cautious with the regulars, I don't want to hurt anyone lol
 
10:53 AM
@MartinJames What are those numbers about?
@thecoshman The cat's getting bitterer, and the bug's getting... somethinger.
 
@R.MartinhoFernandes sweeter :P
 
@R.MartinhoFernandes Default stack sizes; 250k isn't that many, IMO
 
@R.MartinhoFernandes I was just gesstimating how many java objects you could stuff onto a 1MB stack, (on 32-bit).
 
wait... I didn't say the one where she is getting a BO problem did I?
 
@thecoshman Temporarily re-gruntled.
 
10:54 AM
@MartinJames You're estimate is way off.
 
@R.MartinhoFernandes Yeah the Cat looks a whole lot bitter for some reason :(
 
Java objects are surprisingly fat.
Oh, wait, you mean only the pointers?
 
@MartinJames Probably two or three.
 
@Cicada I don't follow... regulars know how to take you (no pun intended) and noobs can like itor lump it
 
@R.MartinhoFernandes I was neglecting any other stack usage, fair enough.
 
10:55 AM
Yeah, I got that.
 
@MartinJames runtime stack also needs return frame address, and in Java-land the exception handler crud
 
A empty Java object (just new Object()) is 16 bytes or more IIRC.
 
@thecoshman When I really want to have an interesting discussion (which, believe it or not, happens sometimes here), I just drop the sarcasm talk because it's pointless
@R.MartinhoFernandes 16 bytes doesn't seem much
 
@rvalue Yeah - got that. Still...
 
@R.MartinhoFernandes Java objects are 16-byte aligned
 
10:56 AM
@Cicada OMG, someone that agrees with me on that. I love you.
@Cicada 16 bytes for nothing.
On 64-bit it's possibly larger.
 
@R.MartinhoFernandes No I mean, I would swear it's more than that
 
user142019
Wat. 16 bytes? All it needs is an isa pointer/vtable pointer.
 
@rvalue ..even if you make an array of them?
 
@R.MartinhoFernandes 16 bytes for a distinct object address
 
@WTP'-- No, it's not all it needs.
 
10:57 AM
@MartinJames I believe so
 
@R.MartinhoFernandes I wouldn't say he 'looks' more bitter, but he is certainly acting it. The puppy and him seem to playing of each other
 
user142019
@R.MartinhoFernandes What does it need besides that? Reference count?
 
@WTP'-- Mutex for sychronized methods
 
@WTP'-- All that gunge should be in the heap data.
 
user142019
10:58 AM
Java y u no stack objects.
 
If you are new here, please take a quick look through the hints thank you
8
 
user142019
@rvalue oh lol.
 
user142019
Java is weird.
 
This starwhore
More sarcasm in the pin pls
 
@Cicada jelly?
 
10:59 AM
@WTP'-- 'cos they can be a pain. Also, some developers seem to be running out of java stack even with object pointers <g>
 
user142019
@MartinJames lolwat.
 
Stop it with this <g> thing
 
user142019
@MartinJames How big is a pointer in Java? 10 kB?
 

« first day (739 days earlier)      last day (4221 days later) »