Created
November 22, 2011 00:20
-
-
Save devboy/1384465 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function inferred(x) { | |
return x; | |
} | |
inferred("abc"); // will take the string and return it | |
inferred(1); // will throw a compiler error because x is typed to String now |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment