« first day (285 days earlier)      last day (4680 days later) » 

sbi
2:00 PM
@MartinhoFernandes Actually, the one I found the picture of was US$95. You get quite a keyboard for that money.
This is mine, BTW.
 
@sbi Holy cows. (maybe that's where that leather came from)
 
sbi
@MartinhoFernandes I was wrong. It was 99.95: giftsforprofessionals.com/item/black-leather-keyboard-pad
I'm sure mine was cheaper, though. I suppose it was <€30, but that was ~2001 or 2002 (before the €), so I forgot.
 
C derivate?
What does it take from C?
 
Seems like a terrible article.
> ParaSail also does the debugging automatically, which makes code safer.
 
sbi
2:10 PM
That's a really neat idea when it's too crowded here to lead a serious discussion: Post a bunch of interesting links and everybody will be off reading.
 
WTF is this?
 
do we really need more programming languages?
 
sbi
Would rather use C++ AMP and PPL RT @jason_pontin: New computer language makes multi-core, parallel programming easier: http://bit.ly/n5hnnA
 
@sbi It just seems everyone creates this niche languages. I remember in the 90's when ColdFusion was huge and they were looking for people with 5-10 years of experience, when it was just created in 1995.
 
sbi
@0A0D :)
@MartinhoFernandes I see that the newbie hints had disappeared again. Thanks for fixing this!
 
2:13 PM
Well, I've got the power now :)
I really want a language that "does the debugging automatically".
We really need one of those.
Then we can finally say that programming is just "typing stuff with a keyboard".
 
wouldn't need programmers anymore...
just monkeys
 
sbi
@MartinhoFernandes What do you mean? You're well over 16k. You must have been past 10k two weeks ago.
 
You don't fix syntax errors by debugging.
@sbi You must be an owner to pin messages.
@sbi Did you pin that just to cheat and star your own message?
 
@MartinhoFernandes it's not really a pin, is it?
 
sbi
@MartinhoFernandes Ah, sure. Brainfart of mine. You wouldn't need to pin it yourself, though. Someone else could, after you wrote it.
 
2:15 PM
just a high starred msg
 
@0A0D No, it's a pin. It stays on top for 14 days, regardless of stars.
 
sbi
@0A0D It is.
 
@0A0D Haven't they already figured out connecting a computer directly to a monkey's brain?
 
@MartinhoFernandes oh, be nice if there was a pin icon
 
So they don't need keyboards.
 
2:16 PM
@Potatoswatter did that in the 60's i think
 
Connecting is the easy part.
Getting something meaningful out of that is the hard part.
 
several years ago they gave a monkey a cybernetic arm
 
You just open the skull, stick a cable (any cable) in there, and voilá! Your monkey's brain is connected to the computer.
 
sbi
@Potatoswatter They did connect computers directly to monkeys' brains, but that always fried the brains. Now we have to live with the resulting politicians.
3
@0A0D It looks different in FF, actually.
 
Yes… fried monkey brains are a delicacy, but USB wasn't designed for cooking. You'll need a high-end motherboard.
 
2:19 PM
@sbi I am using FF 5.
 
The star of pins is just a border.
 
@MartinhoFernandes hmm don't see that here, oh well
 
If you star a pin, it's yellow with a black border.
 
sbi
@0A0D Me, too. Looks different from here.
 
@sbi I starred it myself, which brought it from 6 to 7. Before it was a "hollow star" with a black border
 
sbi
2:22 PM
@0A0D Now it's a yellow one with a black border?
 
@sbi Black, brownish yes
 
sbi
@0A0D Well, the border is the clue.
 
@sbi i see
 
I just had the classic C++ is old and not used much argument with someone
funny how uneducated people are about C++
 
Well, C++ is old.
 
sbi
2:24 PM
@TonyTheTiger Why do you do this to yourself?
 
@TonyTheTiger was it a C# developer?
 
@0A0D yep
@sbi cause it was fun :P
 
Hey! No stereotyping. I write C#.
 
I write C# too
but I don't have weird ideas about C++
 
@MartinhoFernandes Me too, I write Java, C++, and C# but prefer C++
 
2:25 PM
(And I don't like the expression <language> developer)
 
user402642
I'm using QtCreator IDE to manage a medium size project (~20,000 lines of code). I'm having doubts with the way QtCreator builds/rebuilds files using qmake/make. Is it beneficial to do hand-compilations of modules to compare performance differences? (ie: with -O3 optimizations in gcc, etc)
 
sbi
@MartinhoFernandes So do I.
 
@MartinhoFernandes You're not exactly a counter-argument to that stereotype :P
 
sbi
But, @Dead, when it comes to stereotypes, you beat us all hands down.
 
2:26 PM
@CarlodelMundo You need to use qmake to be able to use the Q_OBJECT macro and use signals/slots, object properties and the Qt extensions
 
@DeadMG What, I have retarded opinions about C++?
 
@CarlodelMundo I have not used QtCreator in a while - are there built-in optimization flags in the IDE?
 
now this person was claiming that 'helper classes' in .NET have too much overhead to use! Huh??? WTF???
 
@CarlodelMundo QtCreator just runs make. But you may want to tweak the .pro files
 
@sbi oooooh :)
 
2:26 PM
lol
 
@TonyTheTiger What's a "helper class"?
 
user402642
Thanks guys. Tweaking the .pro file, with gcc level optimizations? And I don't believe there are built-in optimization flags in the IDE.
 
@MartinhoFernandes some class with static methods in I assume that does random type things
I guess
 
Oh, those are the ones without overhead.
No virtual dispatch, so the JIT is free to inline and do all kinds of shenanigans with them.
 
@CarlodelMundo If you want to customize, you may need to switch to another build system e.g. Cmake. qmake does not allow much customization, it's only really useful for kickstarting,
 
2:28 PM
@MartinhoFernandes I thought that overhead was out of place in that context
just shows the average .NET dev hasn't really a clue
and no I'm not stereotyping
 
AFAIK QtCreator has CMake support.
 
@TonyTheTiger Oh, I can totally agree with that statement.
 
sbi
@TonyTheTiger Yes, you are stereotyping, but you're right anyway. :)
 
user402642
@kbo
 
@MartinhoFernandes Thank you for agreeing :)
 
user402642
2:30 PM
@kbok Thanks. I'll give it a try
 
@sbi :)
 
@CarlodelMundo Good luck :)
 
@TonyTheTiger I think people who say it adds extra overhead really have not evaluated the code to determine if it does.
 
@0A0D yea, or don't really understand what's really going on
 
I like this question "..... Is there a memory leak in my code? Or are there leaks in Apple's SDK? How can I fix this, if necessary? Thanks!"
 
2:41 PM
As a windows user - I'd say the latter
 
@ManofOneWay OP didn't even post any code to substantiate it...
 
@ManofOneWay Without code, it could be either.
 
@MartinhoFernandes I would guess Apple tests their code before releasing it :)
 
And that means it's flawless?
If you go to the questions page now, you may run into strtok.
You have been warned.
 
@MartinhoFernandes :)
I just did an edit on that question
 
2:52 PM
0
Q: C++ support in kernel module in 64-bit system

YHHI know C++ is not recommended in kernel module, however, we have a module written in a mix of C and C++ files, the module works well in 32-bit system (kernel 2.6), now we are trying to port the module to 64-bit system, is C++ not supported at all in 64-bit system? Thanks, YH

What's wrong with writing kernel modules in C++?
As long as you don't let exception escape, everything should be fine, right?
 
is it redundant to declare mutable std::string temp?
 
@0A0D Depends.
 
If you don't plan on modifying it in const functions, it is.
 
@MartinhoFernandes If you do it, Linus will come and personally bash you in the face for desecrating the holy kernel
 
@MartinhoFernandes In C++, std::string is already mutable - in C# String is immutable. So just seems redundant since it is already mutable.
 
2:55 PM
@0A0D That's not what mutable does.
 
you'd think the compiler would warn you
 
mutable makes it ok to modify it in const member functions.
 
@0A0D mutable != not const
(Woa, double negative)
 
I know but what is the point of doing this

`int get_access_count() const { return _access_count; }`
`...`
`mutable int _access_count;`
 
If there's nothing else, that's stupid.
 
2:57 PM
It means _access_count could be modified inside get_access_count()
 
It hides compiler errors.
 
Or in any const method for that matter.
 
@EtiennedeMartel ah
 
mutable means that a field shall remain modifiable even in a const method.
 
sbi
@MartinhoFernandes You mean except for the kernel hacker gang's chief hating C++?
 
2:59 PM
@EtiennedeMartel so back to my original question, if it isn't going to be modified in a const method, then it is useless and redundant qualifier?
 
@0A0D Yep
In fact, if you remove it and it still compiles, then it's superfluous.
 
If you remove it and it doesn't compile... it can be a previously-hidden bug, or it can be fine.
 
sbi
@0A0D It's even wrong.
@EtiennedeMartel That doesn't sound like well-designed software. "Let's remove this const over here and see what happens..."
 
@MartinhoFernandes lol, we have a C++ racist on the kernel thread.
 
@sbi When in doubt, delete the weird part.
 
3:04 PM
@EtiennedeMartel that generally doesn't work in C++
speaking from experience
 
there is no C++ interface layer to the Kernel anyways so it is inherently disallowed.. There is no support for C++ drivers in the kernel either
 
you have to understand what's going on
 
sbi
@EtiennedeMartel When in doubt, leave your monitor and take a walk to think. Why is that mutable there? What did I think when I put it there? Did I think right? Have any of the circumstances changed since I thought that? Is that mutable still be needed? If so, why does it seem to be superfluous? If not, I can delete it.
Yeah, way more complicated than your rule of thumb. But it works better, too.
 
@sbi I agree, but that is only valid if you wrote that code. If you're maintaining something written by someone else, however...
 
3:07 PM
@0A0D The is no support for C++, but modules are self-contained. If you export a C api, there's no reason why this shouldn't work.
 
@0A0D Disallowed? You can call C++ code from C and vice versa. You just have to export C APIs.
 
sbi
@EtiennedeMartel Then you just substitute "I" for "he" and ask the guy about his thoughts.
Contrary to popular believe, programming is a very social and communicative task. You need to talk to others a lot.
 
there aren't any C++ drivers for Linux.. that should tell you something :)
 
@sbi What if the guy is no longer available for whatever reason?
 
sbi
Stupid Letdown!
 
3:10 PM
@0A0D There are. It's just that no C++ drivers exists in the kernel tree, because it's not supported.
 
sbi
@EtiennedeMartel You just collapse in a corner weeping and expect your cow-workers to clean up your mess.
 
@kbok that's my point
 
The kernel developers are highly against using C++ in the kernel, and suggest everyone to port their modules to C. But that doesn't mean it's not feasible.
 
you can go write your own device driver in C++, but don't expect to see it in the kernel
 
sbi
@kbok Well, that's a bit of a funny reasoning they describe there:
> Is it a good idea to write a new driver in C++? The short answer is no, because there isn't any support for C++ drivers in the kernel.
> Why not add a C++ interface layer to the kernel to support C++ drivers? The short answer is why bother, since there aren't any C++ drivers for Linux.
Yeah, that certainly makes sense.
 
3:11 PM
Gotta love circular arguments.
 
It does make sense. It's just not a good argument.
 
@sbi Infinite recursion.
 
"Why isn't there any C++ in the kernel?" "Because there isn't any C++ in the kernel"
 
Sounds like Fight Club
 
sbi
I think the real reason for Linux not using C++ is simply "because the tyrant at the top hates it".
5
 
3:12 PM
I totally agree.
 
C++ has a very bad PR problem.
 
hmmm
 
> However, if you are bold enough to consider writing a driver in C++ and a support layer, be aware that this is unlikely to be well received in the community. Most of the kernel developers are unconvinced of the merits of C++ in general, and consider C++ to generate bloated code. Also, it would result in a confusing mix of C and C++ code in the kernel.
 
how on earth could you implement const as a library feature
 
It's very common that people take a C library and make a C++ binding. It was a very important point of design of the language, to make it compatible with C.
But hey, haters gonna hate.
 
sbi
3:16 PM
@DeadMG How on earth can you assume me wanting to do that?
 
I don't know if you want to do that
I however definitely do
 
 
@DeadMG You make it a type constructor that creates a new type without the non-const functions and an implicit conversion from the regular type.
 
well, we probably have another 50 more years of Torvalds. Finland has good healthcare and he is 41.
3
 
And then work out some details.
@0A0D It's not just Linus, though.
 
3:19 PM
@MartinhoFernandes well, his thoughts are pervasive so it infects the Linux kernel hivemind :)
 
sbi
@kbok To be fair, the whole chapter in that text is titled "Programming Religion", so what should we expect?
 
so are lovers gonna love?
 
@TonyTheTiger Skaters gonna skate.
 
sbi
@TonyTheTiger Lovers are gonna fuck.
 
@sbi hahahahhahahahahah
wankers gonna wank
fappers gonna fap
lol
 
3:21 PM
here we go again...
 
What just happened?
 
@sbi Don't get Tina mad :)
 
@0A0D Yep, there's no end to this.
 
sbi
@TonyTheTiger C|N>K
 
@sbi I have a parse failure
 
sbi
3:22 PM
@0A0D Why? Who's lover is she?
 
@sbi You don't remember the meta discussion?
 
@0A0D how'd you know about Tina?
 
@TonyTheTiger It was on Meta
 
@TonyTheTiger There's a paper trail.
 
3:23 PM
Atwood banned "her", blah blah
 
sbi
@TonyTheTiger Yes, I do, but I doubt there was anything about her being in love.
 
@0A0D COMBO BREAKER !
 
@sbi I knew that as C&C.
Coffee and cats.
 
sbi
3:24 PM
@MartinhoFernandes Command And Conquer?
@MartinhoFernandes Ah! Hadn't heard about that yet.
@kbok ??
@0A0D I know that very well. However, I have no idea why she would be mad about me for that message.
 
@sbi There was a combo of 10 answering posts, and 0A0D just broke it.
 
@kbok I should get a Killer Instinct badge for that
 
sbi
@kbok What you young folks are watching for... <shakes_head/>
The best thing about the internet: you can get answers to your questions. The worst thing: you can get them ninety times.
 
Jerry Garcia, what's going on?
 
3:32 PM
Anyone read the argument about C++ keywords in the link @0A0D posted about the kernel?
 
@MartinhoFernandes I did
 
Doesn't hold water, right?
 
30 weeks. That's trolling.
 
$ find /usr/src/linux-2.4.19-pre3-rmap12h -name "*.[chS]" |\
        xargs grep "regex-for-c++-keywords-surrounded-by-word-boundary-anchors"
 
@MartinhoFernandes given that the keywords introduced by C++ are known in advance, I'd say no, it doesn't hold water
 
3:35 PM
I'll have to run this when I get home just to see how many there are.
 
@MartinhoFernandes Yep. They are assuming you have to look for C++ keywords yourself, and that it takes 5 seconds per line of code.
 
hey if I add somebody on a circle on google+ does it tell him/her to which cycle I added him/her?
/me thinking about adding Linus to the bitches circle
:)
 
of course, if you want to play it safe, you should take trigraphs and such into account as well. And macros could mess it up as well
 
> The fear is that C++ will continue to expand its claim on the namespace. This would generate an ongoing maintenance burden on the kernel developers.
 
@Nils nope, not afaik
 
3:36 PM
They can't be serious.
 
@jalf There are no keywords that collide with trigraphs.
Macros might be a problem.
 
haha
 
Now i want to compile the kernel in C++ just to piss them off.
 
@kbok of course they're serious. Just not very well-informed, open-minded or unbiased
 
And anyways I'm not claiming it can be automated.
It's just not a 30-week-long job.
 
3:38 PM
a bigger problem would be all the additional casts required around malloc calls
 
Exactly. If you want to justify it with the incompatibilities between C and C++, you don't need ridiculous arguments.
 
If you want to participate on Linux related discussion you need ridiculous arguments.
;)
 
"Do not release open-source software on windows, they encourage people not to switch to linux."
 
Someone said that?
Stallman?
 
I swear, I answer a question better than Jon Skeet and he still gets more points on his answer than mine, even after he acknowledged he was wrong
 
3:41 PM
@MartinhoFernandes I don't know if stallman said that, but it's a very common argument.
 
Als
Darn...15 messages marked as spam...This is getting annoying.
 
I saw none. What happened.
 
1
A: Why Base Class Library in .NET?

Etienne de MartelYou got it a bit wrong: The C# code forms the source code That source code is compiled to CIL by a C# compiler and packaged in an assembly At runtime, your assembly (and any assembly it refers to) is loaded by the CLR The CLR has a JIT compiler that generates machine code from that CIL The resu...

Almost the same thing happened to me
At least mine got accepted.
 
@EtiennedeMartel reference: stackoverflow.com/questions/6860081/…
 
@0A0D There, I upvoted your answer.
 
3:46 PM
@EtiennedeMartel thanks buddy
 
@0A0D United against Jon Skeet.
 
What is wrong with his answer?
 
@MartinhoFernandes See his comment
@MartinhoFernandes "@0A0D: Good point - it should be "No overload for method Contains takes 2 arguments". I guess we'll see what Maya says :) "
 
Oh, I didn't knew string.Contains was new in .NET 2.0.
 
I didn't knew there was something before .NET 3.5.
 
3:49 PM
@EtiennedeMartel lots of cast
 
@MartinhoFernandes Yes. But that's my gripe with people upvoting his answers :) It's Jon Skeet, so it must be good even after I pointed out the mistake. Oh well
 
@0A0D Most people upvote Jon Skeet's answers without thinking.
 
He's very nice and helpful, just don't try to go toe-to-toe with his answers, they'll always get upvoted more than yours
 
Not always
 
@MartinhoFernandes Well, .NET before 2.0 was a joke
 
@EtiennedeMartel Ok, too generalized, but I think you get my point...
 
He seems like a fine guy. It's the religion around him that bothers me
Jesus was probably a cool guy too
probably
 
Yes. It's not his fault if people worship him.
 
@jalf From the interactions I had with him (in an open-source project) I find him rather humble.
 
@MartinhoFernandes yeah, I see no reason to doubt that
 
3:54 PM
Oh man, someone suggest regular expressions in that question!
 
Could someone please translate? I don't speak Englishese : "I read it before ! I mean making a myThread() that simulate a process which give similar result to a real thread "
 
@0A0D I need context.
 
@MartinhoFernandes No, you make it a type_reference
 
I think he means simulating a process with a thread.
 
3:57 PM
I think he means simulating a thread with a process.
Not joking.
 
@MartinhoFernandes That makes no sense
 
Why not?
 
A process can be a single thread or multi-threaded
so just calling fork by itself creates another thread of execution by the inherit concept of a process
 
The main difference between a thread and a process is the shared address space.
You can emulate that using shared memory.
 
4:02 PM
I guess the idea of "emulating a thread using fork()" is what is throwing me off
 
but can you fork an emulator using a thread?
 
4:20 PM
yes
 
It's much harder to emulate fork() with... pick anything. It's hard.
 
a virtual machine?
 
fork() creates a copy of your process.
A copy with the current state.
Including call stack and that jazz.
 
open file descriptors are valid in the child process too
 
Everything.
 
4:24 PM
fork() is good for a server tho'
 
And it's fast.
Because it's copy-on-write.
 
pretty sure that if you had a VM, you can emulate anything
 
But that could be waived in a simulation.
 
@DeadMG what do you mean?
 
@DeadMG Doesn't make it a lot easier.
In fact, Cygwin doesn't do the copy-on-write part.
 
4:26 PM
probably because windows can't do it
 
@hexa yes it can
 
yes, it can
 
The first thing that happens when a parent process forks a child process is that the parent initializes a space in the Cygwin process table for the child. It then creates a suspended child process using the Win32 CreateProcess call. Next, the parent process calls setjmp to save its own context and sets a pointer to this in a Cygwin shared memory area (shared among all Cygwin tasks).
 
all you'd have to do is not map the pages and then catch the access violation
 
It then fills in the child's .data and .bss sections by copying from its own address space into the suspended child's address space. After the child's address space is initialized, the child is run while the parent waits on a mutex. The child discovers it has been forked and longjumps using the saved jump buffer.
The child then sets the mutex the parent is waiting on and blocks on another mutex. This is the signal for the parent to copy its stack and heap into the child, after which it releases the mutex the child is waiting on and returns from the fork call. Finally, the child wakes from blocking on the last mutex, recreates any memory-mapped areas passed to it via the shared area, and returns from fork itself.
 
4:27 PM
@MartinhoFernandes Cygwin has a full featured copy-on-write in Windows
 
This is how Cygwin implements it.
 
good to know, i almost never code for windows so I don't know much of the specifics
 
BTW, how do you pronounce your name Martinho? Is it like "Mar-teen-oh" ?
 
just call him little martin
 
sbi
@jalf The whole thing is so stupid an argument, it makes my toenails curl. If all else fail, just run the damn thing through the compiler and see where it barks at you.
 
4:30 PM
@0A0D Not according to them.
> Cygwin fork() essentially works like a non-copy on write version of fork() (like old Unix versions used to do). Because of this it can be a little slow. In most cases, you are better off using the spawn family of calls if possible.
 
@sbi yup
@DeadMG that handles copying the memory space. Fork() copies file descriptors and handles and everything too.
 
Everything.
fork() is just magic.
 
@MartinhoFernandes pretty much
 
4:56 PM
lol
so what's new?
 
dunno, I wasn't paying attention
 
sbi
23
Q: How can I teach a bright person, with no programming experience, how to program?

Richard FantozziI have been asked to take a person in our IT department who has no programming experience but is a smart and capable person and help him move into programming at lets say an entry level developer supporting existing .Net applications. I definitely believe this person can do it but I am looking fo...

 
hahah
 
sbi
This is my answer. I'm a bit late to the game, though, so I won't stand much of a chance to get upvoted enough to be noted.
 
Is @DeadMG's CPupPup language done?
 
4:59 PM
@Xaade still working on it
I'm adding moar cool features
 

« first day (285 days earlier)      last day (4680 days later) »