Get llvm value with expected type (#256) #259

Merged
sb10q merged 1 commits from get_symbol_val_with_type into master 2024-08-17 17:37:19 +08:00
Collaborator

This PR adds an extra parameter to indicate the expected type for getting the llvm value of the host value as discussed here, since some of them like [] or none is essentailly polymorphic.

This PR adds an extra parameter to indicate the expected type for getting the llvm value of the host value as discussed [here](https://git.m-labs.hk/M-Labs/nac3/issues/256#issuecomment-5105), since some of them like `[]` or `none` is essentailly polymorphic.
ychenfo force-pushed get_symbol_val_with_type from 55a5927280 to c7a37217ae 2022-04-09 11:38:37 +08:00 Compare
Author
Collaborator

force-pushed to update on current master branch

force-pushed to update on current master branch
pca006132 approved these changes 2022-04-09 14:48:05 +08:00
pca006132 left a comment
Contributor

It might be better to split the last commit into the symbol resolver change (get_obj_value now accepts an expected_ty param) and the refactoring (adding expected type to all to_basic_value_enum calls)

It might be better to split the last commit into the symbol resolver change (`get_obj_value` now accepts an `expected_ty` param) and the refactoring (adding expected type to all `to_basic_value_enum` calls)
ychenfo force-pushed get_symbol_val_with_type from c7a37217ae to 73bcf7fc3f 2022-04-10 01:27:40 +08:00 Compare
ychenfo force-pushed get_symbol_val_with_type from 73bcf7fc3f to f66f66b3a4 2022-04-10 01:29:03 +08:00 Compare
Author
Collaborator

It might be better to split the last commit into the symbol resolver change (get_obj_value now accepts an expected_ty param) and the refactoring (adding expected type to all to_basic_value_enum calls)

Thanks for the suggestion! force-pushed to split the commit.

> It might be better to split the last commit into the symbol resolver change (get_obj_value now accepts an expected_ty param) and the refactoring (adding expected type to all to_basic_value_enum calls) Thanks for the suggestion! force-pushed to split the commit.
sb10q merged commit f66f66b3a4 into master 2022-04-10 07:21:45 +08:00
sb10q deleted branch get_symbol_val_with_type 2022-04-10 07:21:45 +08:00
Sign in to join this conversation.
No reviewers
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: M-Labs/nac3#259
No description provided.