Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Borrowck tests and build #2889

Merged
merged 6 commits into from
May 6, 2024
Merged

Borrowck tests and build #2889

merged 6 commits into from
May 6, 2024

Conversation

jdupak
Copy link
Contributor

@jdupak jdupak commented Feb 28, 2024

All commits tested even with gcc48.

Depends on #2885
Related to #2716

@CohenArthur
@braw-lee

@braw-lee
Copy link
Contributor

there were merge conflicts in "Link Polonius and run it" commit, so I resolved conflicts and rebased from master and created a pull request in your gccrs repository.
I am not sure if it was the right thing to do here, lemme know.

@jdupak
Copy link
Contributor Author

jdupak commented Feb 29, 2024 via email

@braw-lee
Copy link
Contributor

Thanks for the enthusiasm, but that might have been a little premature. There is a series of 3 PRs that are open, and that need to stay on top of each other. Do reading just the last one on master might cause problems when the first two are merged. I have ignored the conflict for now, because the it will take some time to get to this PR. The correct way to do this is to rebase the first on master and the others on top of it. I wanted to delay that to avoid rebasing it many times as master changes. But I guess I could do it now to solve that problem.

On Thu, 29 Feb 2024, at 07:02, braw-lee wrote: there were merge conflicts in "Link Polonius and run it" commit, so I resolved conflicts and rebased from master and created a pull request in your gccrs repository. I am not sure if it was the right thing to do here, lemme know. — Reply to this email directly, view it on GitHub <#2889 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFNB76AFANL7NP3CRQ3R6C3YV3B6LAVCNFSM6AAAAABD6SFU66VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNZQGQ3DKNBVGU. You are receiving this because you authored the thread.Message ID: @.***>

oops, sorry for jumping the gun,
merge conflict appears around the 16th commit so delaying the rebase seems appropriate

@jdupak
Copy link
Contributor Author

jdupak commented Feb 29, 2024

Rebase of all PRs done, now there is no merge conflict.

@jdupak
Copy link
Contributor Author

jdupak commented Mar 7, 2024 via email

@jdupak jdupak mentioned this pull request Mar 22, 2024
@jdupak jdupak force-pushed the borrowck-stage3 branch 2 times, most recently from fab7a49 to 4465ea7 Compare April 24, 2024 12:36
gcc/rust/ChangeLog:

	* checks/errors/borrowck/polonius/rust-polonius.h (struct FullPoint):
	Polonius facts dump.
	(struct Facts): Polonius facts dump.
	* checks/errors/borrowck/rust-bir-dump.cc (Dump::go):
	Polonius facts dump.
	(Dump::visit): Polonius facts dump.
	(Dump::visit_place): Polonius facts dump.
	(Dump::visit_move_place): Polonius facts dump.
	(Dump::visit_scope): Polonius facts dump.
	* checks/errors/borrowck/rust-borrow-checker.cc (BorrowChecker::go): Polonius facts dump.

Signed-off-by: Jakub Dupak <dev@jakubdupak.com>
This is minimalistic version to build Polonius with Cargo.

gcc/rust/ChangeLog:

	* Make-lang.in: Build Polonius.

Signed-off-by: Jakub Dupak <dev@jakubdupak.com>
gcc/rust/ChangeLog:

	* Make-lang.in: Link Polonius.
	* checks/errors/borrowck/rust-borrow-checker.cc: Run Polonius.

Signed-off-by: Jakub Dupak <dev@jakubdupak.com>
gcc/rust/ChangeLog:

	* checks/errors/borrowck/ffi-polonius/src/gccrs_ffi_generated.rs: Error reporting.
	* checks/errors/borrowck/ffi-polonius/src/lib.rs: Error reporting.
	* checks/errors/borrowck/polonius/rust-polonius-ffi.h (struct FactsView):
	Error reporting.
	(struct Output): Error reporting.
	* checks/errors/borrowck/polonius/rust-polonius.h (struct Facts): Error reporting.
	* checks/errors/borrowck/rust-borrow-checker.cc: Error reporting.

Signed-off-by: Jakub Dupak <dev@jakubdupak.com>
gcc/testsuite/ChangeLog:

	* rust/borrowck/borrowck.exp: New test.
	* rust/borrowck/position_dependant_outlives.rs: New test.
	* rust/borrowck/reference.rs: New test.
	* rust/borrowck/return_ref_to_local.rs: New test.
	* rust/borrowck/subset.rs: New test.
	* rust/borrowck/test_move.rs: New test.
	* rust/borrowck/test_move_behind_reference.rs: New test.
	* rust/borrowck/test_move_conditional.rs: New test.
	* rust/borrowck/tmp.rs: New test.
	* rust/borrowck/use_while_mut.rs: New test.
	* rust/borrowck/use_while_mut_fr.rs: New test.
	* rust/borrowck/well_formed_function_inputs.rs: New test.
gcc/rust/ChangeLog:

	* checks/errors/borrowck/rust-bir-builder-expr-stmt.cc
	(ExprStmtBuilder::visit): Use std::ignore.
@jdupak
Copy link
Contributor Author

jdupak commented Apr 24, 2024

@CohenArthur rebased, fixed std::ignore, also the commit with new tests got previously lost before, please check that one extra.

Copy link
Member

@CohenArthur CohenArthur left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tests look good! great work once again :)

@CohenArthur CohenArthur added this pull request to the merge queue Apr 24, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Apr 24, 2024
@CohenArthur CohenArthur added this pull request to the merge queue Apr 25, 2024
@CohenArthur CohenArthur removed this pull request from the merge queue due to a manual request Apr 25, 2024
@P-E-P P-E-P added this pull request to the merge queue May 6, 2024
Merged via the queue into Rust-GCC:master with commit 45d5c01 May 6, 2024
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants