Skip to content

Commit

Permalink
BIR: Cleanup
Browse files Browse the repository at this point in the history
gcc/rust/ChangeLog:

	* checks/errors/borrowck/rust-bir-place.h: Cleanup.
	* checks/errors/borrowck/rust-borrow-checker.h: Cleanup.

Signed-off-by: Jakub Dupak <[email protected]>
  • Loading branch information
jdupak authored and philberty committed Dec 19, 2023
1 parent eb7dffa commit 03a38a4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion gcc/rust/checks/errors/borrowck/rust-bir-place.h
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ class PlaceDB
auto lookup = lookup_variable (id);
if (lookup != INVALID_PLACE)
return lookup;
places.push_back (
add_place (
{Place::VARIABLE, id, {}, is_type_copy (tyty), false, NO_LIFETIME, tyty});
return places.size () - 1;
};
Expand Down
3 changes: 2 additions & 1 deletion gcc/rust/checks/errors/borrowck/rust-borrow-checker.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ class BorrowChecker

public:
explicit BorrowChecker (bool enable_dump_bir)
: enable_dump_bir (enable_dump_bir){};
: enable_dump_bir (enable_dump_bir)
{}

/** Perform borrow-checking using polonius on an entire crate */
void go (HIR::Crate &crate);
Expand Down

0 comments on commit 03a38a4

Please sign in to comment.