Skip to content

CST: Handle normal + compound assignment #224

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

Merged
merged 1 commit into from
Apr 29, 2025

Conversation

JohnnyMorganz
Copy link
Collaborator

This PR extends the support of the CST to handle assignment (var = expr) and compound assignment (e.g. var += expr) statements. The main part of this is correctly storing the operator token.

Like binary operators, we could type the operator as a union of singleton strings representing the possible operators. For now we leave this alone, but it can be modified in a future change.

Base automatically changed from johnny/cst/for-loops to primary April 28, 2025 21:50
@JohnnyMorganz JohnnyMorganz force-pushed the johnny/cst/assignment branch from cf39437 to 53cbd85 Compare April 29, 2025 18:39
@JohnnyMorganz JohnnyMorganz enabled auto-merge (squash) April 29, 2025 18:43
@JohnnyMorganz JohnnyMorganz merged commit 278d1d8 into primary Apr 29, 2025
6 checks passed
@JohnnyMorganz JohnnyMorganz deleted the johnny/cst/assignment branch April 29, 2025 18:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants