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

Improve invocation #1

Open
gilescope opened this issue Jul 12, 2019 · 4 comments
Open

Improve invocation #1

gilescope opened this issue Jul 12, 2019 · 4 comments

Comments

@gilescope
Copy link

Any objections to a PR that walkdir to find .rs files in a crate's subdirs and then reduces them?

Looking to use this as a way to reduce an ICE found in rustc to a minimal reproduction.

@gilescope
Copy link
Author

I think I've misunderstood. I see there's a parse_and_inline_modules. If I point it to main.rs or lib.rs it should drag everything else in. Will try that.

@gilescope
Copy link
Author

That works, though a little fiddly the copy pasting of rustc command line and adding in the $1 arg.
It would be even better if we could package it as cargo-reduce and then one could type cargo reduce "regex expression" and it would run cargo check repeatedly in place.

That would make it childs play to run. One could still provide an arg for a shell script to run if people wanted to run more than cargo check/regex.

@gilescope gilescope reopened this Jul 16, 2019
@gilescope
Copy link
Author

(Easy setup is important as when the test1.sh isn't quite pointing to the right file it deletes everything).

@jethrogb jethrogb changed the title Like. Focuses on a single file. Want to apply to a crate. Improve invocation Dec 20, 2019
@jethrogb
Copy link
Owner

I think you always need some kind of shell script as you need to somehow determine whether a particular compiler run is "interesting" or not. Inserting a shell script means the user can write arbitrary an arbitrary script to determine interestingness.

I'm open to ideas on this.

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

No branches or pull requests

2 participants