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

refactor: Refactor of attribute lookahead processing #84

Merged
merged 144 commits into from
Sep 15, 2020

Conversation

asmelko
Copy link
Contributor

@asmelko asmelko commented Sep 4, 2020

Until the PR, attribute lookahead was triggered during evaluation of CA expressions. That caused a complexity on the parser as it needed to be prepared to start parsing (performing lookup) in the middle of any statement processing.

The PR introduces new method of performing attribute lookup. It separates lookup from statement processing by initiating the lookup before a statement is passed to a processor.

The refactor caused the simplification of parser_impl and collector classes. Also it moved the functionality of lookup from processing_manager to statement_provider while utilizing the processing_manager's loop.

The refactor may simplify the future work in parsing optimizations.

@asmelko asmelko linked an issue Sep 4, 2020 that may be closed by this pull request
void ordinary_assembly_context::add_symbol_reference(symbol sym)
{
auto name = sym.name;
symbol_refs_.try_emplace(name, std::move(sym));
Copy link
Contributor

Choose a reason for hiding this comment

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

I still think that the copy is not needed. But this code will make two copies...

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 6 Code Smells

97.3% 97.3% Coverage
0.0% 0.0% Duplication

@asmelko asmelko merged commit ce8e59d into development Sep 15, 2020
@asmelko asmelko deleted the attr-lookahead-refactor branch September 15, 2020 08:43
@github-actions
Copy link

🎉 This PR is included in version 0.12.0-beta.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@github-actions
Copy link

🎉 This PR is included in version 0.12.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

SWETAS04 pushed a commit to SWETAS04/che-che4z-lsp-for-hlasm that referenced this pull request Feb 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Refactor attribute lookahead
4 participants