error: defaults for const parameters are only allowed in `struct`, `enum`, `type`, or `trait` definitions --> $DIR/issue-105257.rs:5:12 | LL | fn fnc(&self) {} | ^^^^^^^^^^^^^^^^^^^ error: defaults for const parameters are only allowed in `struct`, `enum`, `type`, or `trait` definitions --> $DIR/issue-105257.rs:6:12 | LL | fn foo() }>(&self) {} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ error: aborting due to 2 previous errors