I was recently told by someone that due to the fact that Stack Overflow uses the CC BY-SA 3.0 license any code examples cannot be used in a commercially available closed source application. This individual works for a relatively large international corporation and regularly speaks with lawyers of his company to determine what libraries and sources can be used in their development products.
EDIT DISCLAIMER: This question, the answers and the comment discussions contain a lot of highly speculative opinions and perspectives. We do not currently have any official response from Stack Overflow. However I have contacted their support directly and was told that this question is being looked into. I believe the discussion here is worthwhile but until an official response is made please take anything said here (including my words) with a great amount of skepticism. The point of this question is to clear up confusion not to contribute further confusion.
I read through some of the old Meta posts and I can see how that interpretation could be made. Jeff Atwood's own answer to the question What is up with the source code license on Stack Overflow? states:
The cc-wiki license seems pretty clear to me on this point: free to remix and reuse, as long as you attribute and use a similar license.
Suddenly the interpretation by legal makes sense. If I remix/reuse a piece of code from SO that means I can't use a commercial license on my product.
He goes on to say this:
That said, a snippet of code falls under excerpt category and thus should be free to use under fair use.
However as another user points out in the comments, in the US, the legal doctrine of Fair Use does not apply to embedding excerpts of copyrighted works into source code.
I am an active contributor on SO and hence it concerns me that a legal department would be reluctant to allow their developers to use Stack Overflow as a resource due to these concerns. I have always assumed that the majority of the code I provide in an answer ends up in a commercial closed source product. After reviewing this information I can see why those concerns exist and I believe that warrants some explicit clarification by someone authorized to speak on behalf of Stack Overflow regarding this issue.
EDIT:
My lack of knowledge with regard to legal matters seems to have led to some confusion. I concur with Erik Funkenbusch's comment:
I think what is being asked for here is not for SE to legally interpret the license, but rather for SE to state what their intention was in choosing that license, and to say "Yes, we intend that code from SO Answers cannot be legally used in commercial applications (or applications who's licenses is incompatible with CC-BY-SA)" or "No, we do intend that everyone can use this code for their applications". Now, it can be argued that choosing the license says what they intend, but I think what Spencer wants is verification that what seems like an oversight was actually intentional
Jeff Atwood's follow up statement regarding code snippets seems to imply that the intention of SO is to allow users to copy, paste and tailor code from the site to their needs. At least, that's how I interpreted it when I read his answer. However it is not expressly stated and even if that is the intention it is questionable whether or not that intention is achieved given the current terms of the site.
An explicit clarification of the intention would help developers better understand their obligations when using Stack Overflow as a resource.
EDIT 2:
I wanted to clarify why I believe the intention would be useful. Speculation regarding SO's intended use of source code in answers seems to fall two ways.
One way is how I've described per Atwood's answer to the question I've linked above. Simply put, the interpretation is that Stack Overflow intends that visitors of the site copy, paste and edit source code found in answers per their needs. If that is the intention there is a problem because the current terms of the site do not support that intent.
The second interpretation is that Stack Overflow intends for users to contact the authors to request permission to use their code. However it's questionable whether that intention is being met. Take for example the following answer: How can I get query string values in JavaScript? An example of an answer which contains piece of code that someone may want to copy and paste (and possibly edit) into their project. At the time of this edit the question has 1.3 million views and the answer has been upvoted 3,481 times. Now, it would be naive to think that nobody has copied or pasted this code but there are only two comments regarding the source and absolutely nothing about the license. If the intention of Stack Overflow is that visitors contact authors and request authorization to use this code in a commercial product it is suspect those intentions are being met.
As I see it, both interpretations of Stack Overflow's intentions come with problems that should be addressed. Of course these are just two highly speculative interpretations of an unlimited number of possibilities.
REMEMBER: Again, lots of speculation here. Stack Overflow has been contacted and is looking into it.