That said, as someone who believes that objects represent things, and code them that way, I find myself starting threads, doing further resource acquisition, self registration, and all kinds of other things that _CAN_ fail in the constructors/destructors. To blithely ignore those problems, or follow every construction with a initialize/finalize type call IMHO misses the point of using C++ over C. Basically, what is being advocated is empty constructor bodies because 99% of basic initialization can be done in the initializers list (and should be if Meyers is correct).
I advocate that too, with the proviso that the member initializer also does nothing significant except trivial initialization. I've seen it going bad where a constructor did blocking I/O in a basic UI window class.
If you look at libraries like Qt, the construct/set options/use pattern is not as unnatural as its dumb application may seem. The split is usually like this: the constructor creates an empty or minimally usable object; setters allow it to be customized in a descriptive manner (as opposed to an arbitrarily ordered list of arguments in a constructor); then there is an action method telling what you want to do with the object. It's also still expected from the destructor to finalize any state associated with the object without any explicit finalization method needed, so not all of RAII's benefits are lost.
RAII isn't just about memory management either. The applications I work on are heavily threaded. Using RAII type classes for lock/unlock not only solves the problems with unlocking things during an exception stack unwind, but it strongly encourages clear lock scoping. Its pretty amazing how many lock bugs can be removed through the use of just a few simple rules mostly enforced by the compiler.
Any class designed to be used as a helper in automatic scope should be RAII indeed. But it's not a sufficient justification for using the pattern for arbitrarily passed values, where C++ just fails to provide adequate solutions out of the box.
I think in the end people who decide exceptions are bad and 100% rule them out of a C++ project for religious reasons (rather then lack of run-time support) do themselves a disservice.
No, it's precisely the bad run-time implementation and its integration with other language features. I have no problems using exceptions in Java, Python, or other runtime environments where they work.
If the destructor code doesn't add a proper try/catch around that code, it's a problem of the destructor passing the smart pointer, not of the constructor of the class pointed to. Note that an exception could also be thrown by the operator new called from the new expression inside the smart pointer code, thus the constructor not throwing is no guarantee to getting no exception in this case. Of course exceptions are only safe if the calling code is written to correctly handle them. That's not specific to constructors.
Thanks for spelling out why C++ is a horrible language for getting, you know, real shit done rather than grappling with the language.
Fortunately, there are ways to make it usable by ignoring problematic parts of the language and standard libraries, and many real-world projects have them applied to their coding guidelines.
I do wish that exceptions were allowed, but I understand the rationale for avoiding them (it's spelled out in the style guide), and can't disagree with the decision.
From someone who disables exceptions via g++ compiler flags for a few of my projects, and uses them extensively in others... The problem is that the language definition basically requires them.
Not in practice. If you write your constructors to only do minimal initialization (yes, RAII is overrated) and don't overload operators beyond few well-regulated cases, you don't have any need for exceptions.
The ugly edge cases and extra code everyone always forgets (nothrow syntax for new) due to laziness can generate the same kind of one in a billion errors that people try to avoid by not having exceptions in their C++ programs.
std::bad_alloc basically does not happen for run-of-the-mill allocations in most deployment environments today, so you can ignore it: an out-of-memory kill will get your program more often anyway, and you can't have a software safeguard for that. Checking for allocation failure may be useful for a few scenarios where huge buffers are allocated, but those can be done with customized code, or better, rewritten to never rely on allocating buffers with sizes approaching that of physically available memory.
Samsung, for one, innovates: they leave wide-open memory access holes, enabling third-party applications to do anything with the user's phone, potentially going beyond what the user intended them to do.
Crunching the math you have several whole screens of menu info...
And this is where the actual usability problem is. If your application has hundreds of menu items, its UI could probably help being redesigned for better balance of general actions vs. drill-down views.
Microsoft needs to destroy Android or they will lose their monopoly pricing power,
They don't have anything like "monopoly pricing power" in the markets where Android is relevant, i.e. on mobile devices not intended for serious work.
If the users see desktop first there's no reason for Metro apps to be developed, and with no applications, no reason to by WinPho.
It may come as a shock to you, but there are already users of Metro UI on tablets and phones where it works rather well, regardless of how Windows 8 feels to all kinds of change-averse people. You may hate Microsoft as you like, just don't try to pass this for market analysis. Or why the heck not, this is Slashdot.
There are plenty of shortcuts in previous windows as well. Of course that wasn't really what he was talking about. It's switching between touch/mouse and keyboard that's time consuming and frustrating.
If you use shortcuts, there is no switching. There wasn't before, there isn't now. With touch, it's arguably more convenient and intuitive to do certain things on the screen than it is with the mouse. I don't get what people are complaining about, except that it's CHAAANGE!
Let me get this straight: if someone can't figure out how to use their computer, they should use the computer they haven't learned to use to look up how to use it on the internet.
I wonder how did it all work before. Windows 95-era UIs all seem so "intuitive" now, don't they?
Hell, this site is supposed to be full of people who have once figured out how to use vi. Or Emacs, for that matter. When did they all turn to seniles who can't remember shit once they went through the doorway?
I feel for you bro. I, too, wanted to seriously give Windows 8 a try, but I've found that it seriously disrupts my Norton Commander workflows. Our support group meets every Thursday on 7 pm. That's right after Asperger's, so you can conveniently attend both.
Why, oh WHY does Microsoft not understand that I DON'T WANT TO TAKE MY HAND(S) OFF THE KEYBOARD!?!?!
Sorry to interrupt your ignorant rant, but there are keyboard shortcuts in Windows 8 for all important UI features, as there were in previous versions of Windows. Of course it requires that you'd take five minutes of your time to learn them, who does that when you can just spew rage on internet.
So, basically, there was competent competition, and Dell's me-toosim wasn't cutting it.
If by "competent" you mean "Big Data pricing pure OEM competition out of the market", yes. Although I don't believe Dell has been producing really competitive tablets, the Android hardware market starts looking really lopsided.
Google Sync will continue to be fully supported for Google Apps for Business, Government and Education. Users of those products are unaffected by this announcement.
Nokia would have had better luck sticking with meego/maemo, and the small, but stable, and rabidly loyal fanbois that were willing to shell out over $600 for a new unbranded phone, just for meego/maemo.
I don't see how this helps average Windows users in any way. Most people who have a choice will be staying with Windows 7, and even those who are stuck with Windows 8 for whatever reason can still run VLC just fine on the Desktop. (Like all other x86 software it won't run on WinRT, but WinRT is dead on arrival.) Metro needs to be killed quickly, and it's baffling as to why an open source project would try to prop it up.
You are delusional. VLC is popular because it's a free player available on Windows that Just Plays Anything. On open source platforms, there are many others. Without it, Metro users will just use something else. Yes, there will be Metro users regardless of you and your ridiculous intent to kill it.
If VLC wants to fund a Kickstarter, putting more resources into Blu-Ray menu support would be a much better choice.
You mean like paying royalties to whoever owns the patents?
Oh wait, what the fuck was that program called? It's not like there's only 17 programs ever created on earth.
Currently, I go start - graphics - whatever imaging program I need. Or start - cellphone - whatever that cell program is that I need.
It's called categorization... something that's UNBELIEVABLY easy to both set up and use on the old system, and lets me find ANYTHING WHATSOEVER, even if I have no idea what its name is since I only use it a handful of times a year.
Oh yeah, I was good at it too, managing the train wreck which was the Windows start menu. Until Windows 7 came along, at which point I stopped giving a fuck, pinned things I really care about to places where I can easily find them, and used search for the rest. For that "handful of times a year" moment, I can brute-force the whole menu with some memory cues: "I'm pretty sure Acme Inc. didn't make that application. Who thought naming top-level items after the vendors was a good idea, anyway?". It looks like with Windows 8, you get more space to pin things onto, a whole panoramic home view. If that's not enough, well, consider the possibility that you might just have too much shit to worry about.
So when you completely change the UI, it takes the typical user much more than "two hours" to get used to doing things differently. It can take weeks, months even, to get used to doing things a different way.
I suspected this is the problem with Metro UI, GNOME 3, your favorite website's new look of the month, and in fact any new UI under the sun. If it's such a big problem, why switch? If your workplace upgrades the UI for you, well, tough nuts, you are paid to be professional and adapting to changes in the work environment is part of it, so don't go all Waddams on them.
I bet there are still people out there using Norton Commander.
Seriously, it became ok to remove a feature that seemed to be essential to the system because we can download a third party module that will fix it? Honestly, If there is such a demand for a feature that people have to download an extension to get the feature back, is that maybe something that shouldn't have been removed in the first place? and it's ok that it starts up in "tablet" mode a.k.a "Metro" on a laptop or PC because all you have to do to start getting work done is press Win+D?
All you really have to do to start getting your regular work done is to, don't miss any step: 1) click the tile you have put up on the start screen. Of course this requires a minimal amount of customization, who does that when you can look at the new system for two minutes in a mall and go spew rage on internet forums.
Ironically, any third-party add-on applications are easily removable on Windows Phone.
That said, as someone who believes that objects represent things, and code them that way, I find myself starting threads, doing further resource acquisition, self registration, and all kinds of other things that _CAN_ fail in the constructors/destructors. To blithely ignore those problems, or follow every construction with a initialize/finalize type call IMHO misses the point of using C++ over C. Basically, what is being advocated is empty constructor bodies because 99% of basic initialization can be done in the initializers list (and should be if Meyers is correct).
I advocate that too, with the proviso that the member initializer also does nothing significant except trivial initialization. I've seen it going bad where a constructor did blocking I/O in a basic UI window class.
If you look at libraries like Qt, the construct/set options/use pattern is not as unnatural as its dumb application may seem. The split is usually like this: the constructor creates an empty or minimally usable object; setters allow it to be customized in a descriptive manner (as opposed to an arbitrarily ordered list of arguments in a constructor); then there is an action method telling what you want to do with the object. It's also still expected from the destructor to finalize any state associated with the object without any explicit finalization method needed, so not all of RAII's benefits are lost.
RAII isn't just about memory management either. The applications I work on are heavily threaded. Using RAII type classes for lock/unlock not only solves the problems with unlocking things during an exception stack unwind, but it strongly encourages clear lock scoping. Its pretty amazing how many lock bugs can be removed through the use of just a few simple rules mostly enforced by the compiler.
Any class designed to be used as a helper in automatic scope should be RAII indeed. But it's not a sufficient justification for using the pattern for arbitrarily passed values, where C++ just fails to provide adequate solutions out of the box.
I think in the end people who decide exceptions are bad and 100% rule them out of a C++ project for religious reasons (rather then lack of run-time support) do themselves a disservice.
No, it's precisely the bad run-time implementation and its integration with other language features. I have no problems using exceptions in Java, Python, or other runtime environments where they work.
If the destructor code doesn't add a proper try/catch around that code, it's a problem of the destructor passing the smart pointer, not of the constructor of the class pointed to. Note that an exception could also be thrown by the operator new called from the new expression inside the smart pointer code, thus the constructor not throwing is no guarantee to getting no exception in this case. Of course exceptions are only safe if the calling code is written to correctly handle them. That's not specific to constructors.
Thanks for spelling out why C++ is a horrible language for getting, you know, real shit done rather than grappling with the language.
Fortunately, there are ways to make it usable by ignoring problematic parts of the language and standard libraries, and many real-world projects have them applied to their coding guidelines.
I do wish that exceptions were allowed, but I understand the rationale for avoiding them (it's spelled out in the style guide), and can't disagree with the decision.
From someone who disables exceptions via g++ compiler flags for a few of my projects, and uses them extensively in others... The problem is that the language definition basically requires them.
Not in practice. If you write your constructors to only do minimal initialization (yes, RAII is overrated) and don't overload operators beyond few well-regulated cases, you don't have any need for exceptions.
The ugly edge cases and extra code everyone always forgets (nothrow syntax for new) due to laziness can generate the same kind of one in a billion errors that people try to avoid by not having exceptions in their C++ programs.
std::bad_alloc basically does not happen for run-of-the-mill allocations in most deployment environments today, so you can ignore it: an out-of-memory kill will get your program more often anyway, and you can't have a software safeguard for that.
Checking for allocation failure may be useful for a few scenarios where huge buffers are allocated, but those can be done with customized code, or better, rewritten to never rely on allocating buffers with sizes approaching that of physically available memory.
Samsung, for one, innovates: they leave wide-open memory access holes, enabling third-party applications to do anything with the user's phone, potentially going beyond what the user intended them to do.
Crunching the math you have several whole screens of menu info...
And this is where the actual usability problem is. If your application has hundreds of menu items, its UI could probably help being redesigned for better balance of general actions vs. drill-down views.
Microsoft needs to destroy Android or they will lose their monopoly pricing power,
They don't have anything like "monopoly pricing power" in the markets where Android is relevant, i.e. on mobile devices not intended for serious work.
If the users see desktop first there's no reason for Metro apps to be developed, and with no applications, no reason to by WinPho.
It may come as a shock to you, but there are already users of Metro UI on tablets and phones where it works rather well, regardless of how Windows 8 feels to all kinds of change-averse people. You may hate Microsoft as you like, just don't try to pass this for market analysis. Or why the heck not, this is Slashdot.
There are plenty of shortcuts in previous windows as well. Of course that wasn't really what he was talking about. It's switching between touch/mouse and keyboard that's time consuming and frustrating.
If you use shortcuts, there is no switching. There wasn't before, there isn't now.
With touch, it's arguably more convenient and intuitive to do certain things on the screen than it is with the mouse.
I don't get what people are complaining about, except that it's CHAAANGE!
Let me get this straight: if someone can't figure out how to use their computer, they should use the computer they haven't learned to use to look up how to use it on the internet.
I wonder how did it all work before. Windows 95-era UIs all seem so "intuitive" now, don't they?
Hell, this site is supposed to be full of people who have once figured out how to use vi. Or Emacs, for that matter. When did they all turn to seniles who can't remember shit once they went through the doorway?
I feel for you bro. I, too, wanted to seriously give Windows 8 a try, but I've found that it seriously disrupts my Norton Commander workflows.
Our support group meets every Thursday on 7 pm. That's right after Asperger's, so you can conveniently attend both.
Why, oh WHY does Microsoft not understand that I DON'T WANT TO TAKE MY HAND(S) OFF THE KEYBOARD!?!?!
Sorry to interrupt your ignorant rant, but there are keyboard shortcuts in Windows 8 for all important UI features, as there were in previous versions of Windows. Of course it requires that you'd take five minutes of your time to learn them, who does that when you can just spew rage on internet.
It'd be like trying to get into the business of selling printers without having an ink-making division.
No, it'd be like trying to get into the business of building airplanes without having an airline.
Wait... I wonder why it's not allowed any more.
2013 is going to be the year of Chrome on the Desktop!
Sorry, couldn't help...
Actually, now there's an easy answer: "Sure you can BYOD, as long as the D runs Windows 8, Windows RT, or Windows Phone."
So, basically, there was competent competition, and Dell's me-toosim wasn't cutting it.
If by "competent" you mean "Big Data pricing pure OEM competition out of the market", yes. Although I don't believe Dell has been producing really competitive tablets, the Android hardware market starts looking really lopsided.
They're switching third-party clients from the exchange MAPI protocols to open protocols.
FTFY
The Gmail app uses an API controlled by Google.
Prod me when the Gmail app for Android uses the open protocol you mention. I may want to try those rose-tinted glasses then.
They got whatever licences GrandCentral had, but haven't bothered trying to extend them or renew them.
Well, this is exactly the problem GP was referring to: Google buys a service, then neglects to support its users as well as the previous owners did.
At least Google doesn't demand you pay for the services they discontinue.
From TFAnnouncement:
Sounds like paid-only availability to me.
That, and the N9 still sold better with no advertising than the lumina 900 which was actively being pushed.
This is a myth.
Nokia would have had better luck sticking with meego/maemo, and the small, but stable, and rabidly loyal fanbois that were willing to shell out over $600 for a new unbranded phone, just for meego/maemo.
Yeah... We'll see how it works with Jolla.
I don't see how this helps average Windows users in any way. Most people who have a choice will be staying with Windows 7, and even those who are stuck with Windows 8 for whatever reason can still run VLC just fine on the Desktop. (Like all other x86 software it won't run on WinRT, but WinRT is dead on arrival.) Metro needs to be killed quickly, and it's baffling as to why an open source project would try to prop it up.
You are delusional. VLC is popular because it's a free player available on Windows that Just Plays Anything. On open source platforms, there are many others. Without it, Metro users will just use something else. Yes, there will be Metro users regardless of you and your ridiculous intent to kill it.
If VLC wants to fund a Kickstarter, putting more resources into Blu-Ray menu support would be a much better choice.
You mean like paying royalties to whoever owns the patents?
Oh zowie, I can type the name of the program.
Oh wait, what the fuck was that program called? It's not like there's only 17 programs ever created on earth.
Currently, I go start - graphics - whatever imaging program I need. Or start - cellphone - whatever that cell program is that I need.
It's called categorization... something that's UNBELIEVABLY easy to both set up and use on the old system, and lets me find ANYTHING WHATSOEVER, even if I have no idea what its name is since I only use it a handful of times a year.
Oh yeah, I was good at it too, managing the train wreck which was the Windows start menu. Until Windows 7 came along, at which point I stopped giving a fuck, pinned things I really care about to places where I can easily find them, and used search for the rest. For that "handful of times a year" moment, I can brute-force the whole menu with some memory cues: "I'm pretty sure Acme Inc. didn't make that application. Who thought naming top-level items after the vendors was a good idea, anyway?". It looks like with Windows 8, you get more space to pin things onto, a whole panoramic home view. If that's not enough, well, consider the possibility that you might just have too much shit to worry about.
So when you completely change the UI, it takes the typical user much more than "two hours" to get used to doing things differently. It can take weeks, months even, to get used to doing things a different way.
I suspected this is the problem with Metro UI, GNOME 3, your favorite website's new look of the month, and in fact any new UI under the sun. If it's such a big problem, why switch? If your workplace upgrades the UI for you, well, tough nuts, you are paid to be professional and adapting to changes in the work environment is part of it, so don't go all Waddams on them.
I bet there are still people out there using Norton Commander.
Seriously, it became ok to remove a feature that seemed to be essential to the system because we can download a third party module that will fix it? Honestly, If there is such a demand for a feature that people have to download an extension to get the feature back, is that maybe something that shouldn't have been removed in the first place? and it's ok that it starts up in "tablet" mode a.k.a "Metro" on a laptop or PC because all you have to do to start getting work done is press Win+D?
All you really have to do to start getting your regular work done is to, don't miss any step: 1) click the tile you have put up on the start screen.
Of course this requires a minimal amount of customization, who does that when you can look at the new system for two minutes in a mall and go spew rage on internet forums.