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

Fix code generation for Dictionary and List which use Array values #855

Merged

Conversation

prochnowc
Copy link
Contributor

Fixes #854

@prochnowc
Copy link
Contributor Author

@EdwardCooke I have another fix for static code generation prepared, so please do not do a release immediately ;)

@EdwardCooke
Copy link
Collaborator

Sounds good. I’ll try and get to it as soon as your ready.

@prochnowc
Copy link
Contributor Author

Should I put the fix in this PR or do another one ?
It is about deserializing into object (which already uses Dictionary<object, object> without static code generation)

@EdwardCooke
Copy link
Collaborator

It doesn’t always go into a dictionary. You can serialize/deserialize just a single value like an int or string. Also, you won’t know what the type of the object should be so it doesn’t know what to deserialize into which is why it throws an exception there. There was another case where it couldn’t figure it out back when I built out the static stuff and I can’t remember exactly what it is. I very vaguely remember it had something to do with dictionary object, object not working right in aot compiled applications. Might be way off there though.

did you find a way around those object limits?

@prochnowc
Copy link
Contributor Author

At least I managed to deserialize object into Dictionary<object,object> with AOT. I will open annother issue about that, this PR doesnt seem to be the right place to discuss this. :)

@EdwardCooke
Copy link
Collaborator

Sounds good to me. Do you want me to merge this in then?

@prochnowc
Copy link
Contributor Author

Yes please.

@EdwardCooke
Copy link
Collaborator

Will do

@EdwardCooke EdwardCooke merged commit 7dd57d4 into aaubry:master Oct 5, 2023
@prochnowc prochnowc deleted the support-collections-with-arrays branch October 5, 2023 18:11
@aaubry
Copy link
Owner

aaubry commented Oct 5, 2023

This feature has been released in version 13.5.2.

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.

Static code generation fails to generate code for Dictionary and List which use Array values
3 participants