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

Serialized Class ID <-> Value #396

Merged
merged 4 commits into from
Jul 31, 2024

Conversation

saulshanabrook
Copy link
Member

@saulshanabrook saulshanabrook commented Jul 15, 2024

This PR fixes #392 to add a public API for going from serialized Class IDs to Values.

It does this by changing the serialized class IDs to be more uniform. It should preserve all behavior.

cc @gussmith23

@saulshanabrook saulshanabrook requested a review from a team as a code owner July 15, 2024 17:56
@saulshanabrook saulshanabrook requested review from oflatt and removed request for a team July 15, 2024 17:56
@gussmith23
Copy link
Contributor

You're a lifesaver!!

Just to be clear: there's a lot of things I have to do over a serialized egraph, because I can't inspect the egglog::EGraph enough to do what I need. I realize that egglog is different from egg, and that this is one of the results. I'm just trying to say that my use of the serialized egraph is mostly just a hack around the core problem of not being able to inspect the egglog::EGraph. Either way, Saul's PR helps my hack be less hacky :)

@saulshanabrook
Copy link
Member Author

I think having the serialized e-graph as a public API maybe isn't the worst, it at least makes it easy to change the internals of egglog without disrupting the API at all.

@saulshanabrook saulshanabrook changed the base branch from main to backoff-fix July 23, 2024 20:51
@saulshanabrook saulshanabrook changed the base branch from backoff-fix to main July 23, 2024 20:52
src/serialize.rs Outdated Show resolved Hide resolved
Copy link
Member

@oflatt oflatt left a comment

Choose a reason for hiding this comment

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

Looks good!

@saulshanabrook saulshanabrook merged commit 5d8c025 into egraphs-good:main Jul 31, 2024
3 checks passed
@saulshanabrook saulshanabrook deleted the back-and-forth branch July 31, 2024 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants