From bf66723c0ecbadc3b4b24da44fa02b7ea3cd73bb Mon Sep 17 00:00:00 2001 From: Michael Goulet Date: Mon, 28 Aug 2023 02:37:38 +0000 Subject: Test and note unsafe ctor to fn ptr coercion Also remove a note that I don't consider to be very useful in context. --- tests/ui/static/static-reference-to-fn-1.stderr | 1 - 1 file changed, 1 deletion(-) (limited to 'tests/ui/static') diff --git a/tests/ui/static/static-reference-to-fn-1.stderr b/tests/ui/static/static-reference-to-fn-1.stderr index b68352b5183..86c4eaa7eb4 100644 --- a/tests/ui/static/static-reference-to-fn-1.stderr +++ b/tests/ui/static/static-reference-to-fn-1.stderr @@ -7,7 +7,6 @@ LL | func: &foo, = note: expected reference `&fn() -> Option` found reference `&fn() -> Option {foo}` = note: fn items are distinct from fn pointers - = note: when the arguments and return types match, functions can be coerced to function pointers help: consider casting to a fn pointer | LL | func: &(foo as fn() -> Option), -- cgit 1.4.1-3-g733a5