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

bytecode: Implement string literals and operations #304

Merged
merged 1 commit into from
Mar 18, 2024

Conversation

Rossiar
Copy link
Collaborator

@Rossiar Rossiar commented Mar 18, 2024

Add an internal representation for strings to the package and support
assigning strings. Add opcodes for concatenating and comparing strings.
The compiler takes the burden of type checking the arguments so that
the vm can run an optimised hot path.

Copy link
Member

@juliaogris juliaogris left a comment

Choose a reason for hiding this comment

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

aah, so now the OpStringLessThan etc come together, yes makes sense to me to have them is seprate operators and not do the typecheck during runtime.

Again, lgtm, curious to see what @camh- will find.

@juliaogris juliaogris linked an issue Mar 18, 2024 that may be closed by this pull request
Copy link
Member

@camh- camh- left a comment

Choose a reason for hiding this comment

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

LGTM

Base automatically changed from compiler-comparison-operators to main March 18, 2024 23:47
Add an internal representation for strings to the package and support
assigning strings. Add opcodes for concatenating and comparing strings.
The compiler takes the burden of type checking the arguments so that
the vm can run an optimised hot path.
@juliaogris juliaogris merged commit 4452a93 into main Mar 18, 2024
3 checks passed
@juliaogris juliaogris deleted the compiler-strings branch March 18, 2024 23:50
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.

Implement compiler with stack-based VM
3 participants