Skip to content

Make type hashing :total #52427

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 5 commits into from
Dec 7, 2023
Merged

Conversation

Seelengrab
Copy link
Contributor

Since types can't really be deleted and the hash of a type is already being cached inside of the type object itself, it should be legal to mark the ccall retrieving that hash as :total, permitting hashing of types to be concretely evaluated.

I'm unsure if the test I've added is good as written, or whether this should be done differently.

@Tokazama
Copy link
Contributor

Tokazama commented Dec 6, 2023

I thought the hash of data types could change between runs

@vtjnash
Copy link
Member

vtjnash commented Dec 7, 2023

That was fixed on master recently, so we should remove that documentation

@Seelengrab
Copy link
Contributor Author

I think "run to run" in that documentation refers to different invocations of julia/"sessions of the REPL", not different queries of hash, so that should already be consistent.

@aviatesk aviatesk merged commit 710bf90 into JuliaLang:master Dec 7, 2023
@Seelengrab Seelengrab deleted the type_hash_effects branch December 7, 2023 22:11
@topolarity
Copy link
Member

@vtjnash Do you know if the hashing changes you mention on master were backported to 1.10?

Would be nice to backport this as well, if so

@oscardssmith
Copy link
Member

This wasn't backported (and it would be a somewhat risky backport imo #52119)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants