deprecated
package metaobjectTest | |
@doc{* | |
Annotation 'deprecated' should be attached to a method. | |
Whenever there is a possible message passing that can call | |
the method, an error message is issued at compile-time | |
*} | |
object Deprecated | |
@deprecated("Method 'outdatedMethod:' was replaced by 'newMethod:'") | |
func outdatedMethod: String s { } | |
func newMethod: String s { "Use this" println } | |
func run { | |
// error if uncommented | |
// self outdatedMethod: "error if uncommented"; | |
} | |
end | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment