MCPcopy Create free account
hub / github.com/MaterializeInc/materialize / take_dangerous

Method take_dangerous

src/expr/src/relation.rs:1564–1570  ·  view source on GitHub ↗

Take ownership of `self`, leaving an empty `MirRelationExpr::Constant` with an **incorrect** type. This should only be used if `self` is about to be dropped or otherwise overwritten.

(&mut self)

Source from the content-addressed store, hash-verified

1562 ///
1563 /// This should only be used if `self` is about to be dropped or otherwise overwritten.
1564 pub fn take_dangerous(&mut self) -> MirRelationExpr {
1565 let empty = MirRelationExpr::Constant {
1566 rows: Ok(vec![]),
1567 typ: ReprRelationType::new(Vec::new()),
1568 };
1569 std::mem::replace(self, empty)
1570 }
1571
1572 /// Replaces `self` with some logic applied to `self`.
1573 pub fn replace_using<F>(&mut self, logic: F)

Callers 15

fix_typesFunction · 0.80
destroy_carefullyMethod · 0.80
make_nonrecursiveMethod · 0.80
applied_toMethod · 0.80
rebuild_mfpMethod · 0.80
actionMethod · 0.80
actionMethod · 0.80
actionMethod · 0.80
inline_viewsFunction · 0.80

Calls 1

replaceFunction · 0.50

Tested by

no test coverage detected