intellectual-property licensing
How far does Programming Language license go?
<p>I know that source code can have a license. For example, if my code is released under GPL(e.g. v2), there are some restrictions that say what anyone who wants to use my code <em>must</em> do.</p>

<p>I've found a tutorial for SDL(<a href="http://lazyfoo.net/tutorials/SDL/index.php" rel="nofollow noreferrer">lazyfoo</a>). There's <a href="http://lazyfoo.net/faq.php" rel="nofollow noreferrer">FAQ</a>.</p>

<p>One of the points mentions "translating the code to the other programming languages". The author strictly prohibits this. Is this backed up by law? Can an author of the code forbid me from rewriting his code into other lanuage, and if yes, what are limitations of <em>what</em> can I (re)write?</p>

<p>A prohibition on "translating the code to the other programming languages" is a prohibition on creating a particular type of derivative work. The right to create <em>any</em> derivative work is an exclusive right of the copyright owner. <a href="https://www.law.cornell.edu/uscode/text/17/106" rel="nofollow noreferrer">17 USC 106(2)</a> They can licence or give that right to you in part, and with limitations.</p>

<p>You are limited from taking what would amount to a "substantial similarity" compared to the copyrightable elements of the original. For computer programs, US courts use the <a href="https://en.wikipedia.org/wiki/Abstraction-Filtration-Comparison_test" rel="nofollow noreferrer">abstraction-filtration-comparison test</a>.</p>

<p>The author doesn't forbid you to translate the code to a different programming language, the author just doesn't allow it. And since there is nothing else that allows you to create derivatives of a copyrighted work, you don't have the right to translate it. </p>

<p>You are looking at this from the wrong point of view. The author of a copyrighted work cannot tell you what to do whatsoever. However, copyright law gives you very little rights, and if the copyright owner doesn't give you more rights, then you don't have those rights. So if you <em>do</em> translate to a different programming language, then it will turn out that you don't have the right to do so through copyright law, nor through a license from the copyright holder, therefore no rights, therefore you can be successfully sued for copyright infringement. </p>
