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

Speed up has_print_function. #99

Merged
merged 1 commit into from
Jun 3, 2017
Merged

Speed up has_print_function. #99

merged 1 commit into from
Jun 3, 2017

Conversation

duncf
Copy link
Contributor

@duncf duncf commented Jun 3, 2017

This speeds up parsing significantly for large files.

This speeds up parsing significantly for large files.
@Psycojoker
Copy link
Member

Oh, sound like a good thing :)

I've never took the time to optimize baron so you'll probably find other things like that lying around :/

Thanks!

@Psycojoker Psycojoker merged commit d11599b into PyCQA:master Jun 3, 2017
@Psycojoker
Copy link
Member

Oh, and after a quick test that reduce parse time (on baron's own code) by 38%, pretty nice 👍

@duncf
Copy link
Contributor Author

duncf commented Jun 4, 2017

I profiled parsing a pretty large file with RedBaron, and this was ~75%. I didn't see any other low hanging fruit, but I didn't look into it that closely. Thanks for accepting the pull request!

@Psycojoker
Copy link
Member

That sound like a really big file. Are you in a position where you can give me some details on what you've been doing? I'm always eager to learn how people are using red/baron :)

@duncf
Copy link
Contributor Author

duncf commented Jun 11, 2017

I'm mostly just playing with RedBaron right now -- small refactorings, etc. Nothing too exciting, sorry. :-)

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.

2 participants