In general, needless_option_take should report whenever
take() is called on a temporary value, not just when the
temporary value is created by as_ref()
This lint checks if Option::take() is used on a temporary value (a value
that is not of type &mut Option and that is not a Place expression) to
suggest omitting take()