scarb
scarb copied to clipboard
[DRAFT] add casm json target
Addressing #676
Now that I think about it, please consider if your usage isn't already covered by a tool called universal-sierra-compiler
https://github.com/software-mansion/universal-sierra-compiler/tree/master, which is already capable of compiling Sierra json to Casm json format (and has not been available when the issue has been created).
@maciektr Thank you. That tool should already cover the use case. I'll close this PR.
@maciektr After discussion with @rodrigo-pino, there are a couple things missing from the generated casm json by the universal-sierra-compiler, namely entrypoint and builtins. It might be better for scarb to produce the json file directly instead of relying on yet another tool since it already generates the sierra json file. What do you think?
@tohrnii It can be added to the universal-sierra-compiler
if you need it. Happy to accept any PRs there :)
Hi @tohrnii!
Very sorry for the delay in response, we had a national holidays here in Poland, so I've been out of office for a bit.
After discussion with @rodrigo-pino, there are a couple things missing from the generated casm json by the universal-sierra-compiler, namely entrypoint and builtins.
I believe this should be added to USC then. I second @Arcticae here.
It might be better for scarb to produce the json file directly instead of relying on yet another tool since it already generates the sierra json file.
We do see Scarb as primarily Cairo -> Sierra compiler, and the CASM is just an addition here. We recommend using the USC wherever you rely on CASM programatically and the builtin Scarb feature for by-hand debuging. We move our tooling to use USC as well.
Would it be ok for you?
Thank you @maciektr @Arcticae for the confirmation. Sounds good, I'll open a PR there. Closing this one then.