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

feat(vm): support ByteArray in DebugPrint hint #1853

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

m-kus
Copy link

@m-kus m-kus commented Oct 15, 2024

Support ByteArray in DebugPrint hint

Description

Currently DebugPrint (Cairo1 hint) prints every felt separately, either in its raw form or reinterprets it as a Cairo short string.
If you use println! or assert! macros that makes the output unreadable, because ByteArray is used to represent the string.

This PR basically swaps the current implementation with the code from Cairo repo.
The only difference is that it additionally allows ascii escape sequences :)

If I understood correctly, I cannot import stuff from cairo-lang-runner to avoid versioning problems right?

Checklist

  • Linked to Github Issue
  • Unit tests added
  • Integration tests added.
  • This change requires new documentation.
    • Documentation has been added/updated.
    • CHANGELOG has been updated.

@m-kus m-kus changed the title feat(vm): support ByteString in DebugPrint hint feat(vm): support ByteArray in DebugPrint hint Oct 15, 2024
@m-kus m-kus force-pushed the feat/debug-print-hint-bytestring branch from a408cd4 to b42c99c Compare October 16, 2024 16:07
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.

1 participant