-
Notifications
You must be signed in to change notification settings - Fork 14
refactor(hugrv2)!: WIP+RFC: Unify Type and Term #2785
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
Closed
Closed
Changes from all commits
Commits
Show all changes
97 commits
Select commit
Hold shift + click to select a range
dfc038b
Hide SeqPart stuff - some can be removed, not sure if we need rest
acl-cqc ce1d652
collect_signature_exts is monomorphic, Type::Function does not use
acl-cqc 5bab2ec
import.rs: import_poly_func_type is used only monomorphically
acl-cqc 0113579
import.rs: Explicit typeargs to import_type_row; inline singly-used i…
acl-cqc 74d9a07
export.rs: use SumType::num_variants/get_variant, uniform across Unit…
acl-cqc 0247266
refactor: rephrase root_checked/dfg.rs TypeBase<NoRV> -> Type
acl-cqc 740e227
WIP add new Term variants, declare Type=Term, remove row_var.rs
acl-cqc d8b7d38
GeneralSum with cached Option<TypeBound>
acl-cqc 1ccc7eb
Move Transformable clauses into Term + SumType
acl-cqc cda8762
TypeRow now stores Terms, deparametrize; move (dubious) TypeRV->Term …
acl-cqc 2a462e8
Remove some defunct RV conversions from types.rs
acl-cqc 9d327ea
SumType stores Vec<Term> not Term, so fixed #variants
acl-cqc d431be1
zap various conversions etc., handle Term::Variable in least_upper_bound
acl-cqc 75fe99c
trait Substitutable
acl-cqc 49e9637
Combine Type/Term ::validate
acl-cqc 5cd9bcd
PolyFunc, Signature, also Extension + Reinstate least_upper_bound
acl-cqc 158830d
import.rs: combine import_{type,term}; import_type_row == closed_list…
acl-cqc 8fc6a40
export.rs
acl-cqc 5e42791
Remove a bunch of serde
acl-cqc 1283b24
Revert "Remove a bunch of serde"
acl-cqc 6231e7d
extension resolution
acl-cqc 3647822
more types.rs
acl-cqc 62a9268
export.rs: generalize export_poly_func_type => export_symbol_params
acl-cqc aa91785
Rename Type::new_{=>runtime_}tuple
acl-cqc 9a27f98
SumType::new_from_row and many others
acl-cqc 6a95f9a
test Term->TypeRow, add /*more complex Term::try_into_list_elements*/…
acl-cqc ae39bca
poly_func.rs: split validate
acl-cqc 7c1055a
serialize (to some extent)
acl-cqc 591d0e9
check.rs
acl-cqc 0dbae20
new_var_use takes impl Into<Term>
acl-cqc c990657
std_extensions (at least start on)
acl-cqc 372a341
prelude.rs
acl-cqc af3d9e6
Remove AliasID and related
acl-cqc 9ec8877
simple_replace
acl-cqc bffdddd
Fix check_term_type; fix+extend is_supertype
acl-cqc f1f4b57
TEMP TO REVERT remove dev-dep hugr-core -> hugr
acl-cqc 23eeb8c
WIP hugr-core tests...almost compile, but problems with Arbitrary
acl-cqc a8174c9
Arbitrary for (Poly)FuncTypes
acl-cqc 1ead319
fix test types.rs/as_option
acl-cqc 8b810ca
Fix new_runtime_tuple
acl-cqc e8fe1a8
validate check_term_types the subtrees (RTSum/RTFunc) that check_term…
acl-cqc c1fe1b6
Fix no_outer_row_variables
acl-cqc b5bbcfd
fix prelude type errors
acl-cqc 81d7fc5
move check_typevar_decl, remove bad assert
acl-cqc d3fb5c4
Change Display for Term::List
acl-cqc 4bbff67
Fix extension_with_eval_parallel; polyfunc, type{_row,_param,s}, vali…
acl-cqc ca2d0e1
hugr-core test fixes
acl-cqc 8f41bd2
Some serialization fixes but still many problems; [...] becoming Type…
acl-cqc f022c59
DISABLE check_{hugr,testing}_roundtrip as TEST WORKAROUND
acl-cqc 78a6fab
hugr-passes...all compile, all tests passing
acl-cqc c8bda84
monomorphize/mangle_name: use different prefix for extension/function…
acl-cqc 0446bb5
hugr-llvm and benches compile; hugr-llvm snapshots failing "legacy fo…
acl-cqc 61444e4
FunctionType + GeneralSum checking (RIP new_from_row)
acl-cqc a84ce48
Sum bound is just TypeBound not Option
acl-cqc 1e5e9f3
clippy
acl-cqc 68fba45
splicing for sums + FuncValueType; no tests, but use (saving only 5 l…
acl-cqc 57b8921
Revert "splicing for sums + FuncValueType; no tests, but use (saving …
acl-cqc 64db4a7
Revert "TEMP TO REVERT remove dev-dep hugr-core -> hugr"
acl-cqc 0066fdd
docs, remove TypeRow::new_from_list (is TryInto), reduce change
acl-cqc 259b3a7
fix: CustomSerialized (consts)
acl-cqc e402a73
Fix some bad PolyFuncType's in serialize/test.rs
acl-cqc cc4c40e
better fix for constants, use serde_with
acl-cqc 74bd0b1
even better, use serde_as
acl-cqc 999e712
Revert "even better, use serde_as"
acl-cqc 320ea5d
RIP PolyFuncTypeBase, have two separate structs and a macro
acl-cqc 245b542
RIP FuncTypeBase, same way
acl-cqc 0f06b92
Add ser_type_row for serializing a TypeRow of SerSimpleType...use for…
acl-cqc 2164c3a
Try to serialize FuncValueType inputs/outputs like old TypeRowRVs
acl-cqc edf28b1
Redo Term->Vec<SerSimpleType> with serde_as
acl-cqc 81c638e
Revert "Redo Term->Vec<SerSimpleType> with serde_as"
acl-cqc 76d3392
Refactor out term_(from,to)_ssts, define ser_sum_rows -> fix*3
acl-cqc ecf0cfc
Serialize a bunch of OpType TypeRows correctly -> many fixes
acl-cqc de82507
serde_as SerTypeRow does TypeRow->Vec<SST> -> also Vec<TypeRow>s in c…
acl-cqc 0b58e82
serde_as SerTypeRowRV + SerGenSum(Vec<Term>) -> fix cfg_edge_ordering
acl-cqc 9306be6
Fix Arbitrary for Term; prop_roundtrip SIGABRTs now just FAIL
acl-cqc 7692b4e
Add any_type; use new_unchecked, any::<(->Custom)Type> -> fix prop_ro…
acl-cqc b8b9a5d
REINSTATE check_{hugr,testing}_roundtrip ---> 18 fails
acl-cqc 710641f
mod ser_type -> serde_as SerType, use for Option in SerTestingLatest:…
acl-cqc f3d91da
proptest + serialize the 'type' in AliasDefn
acl-cqc 4252158
Restrict prop_roundtrip_type; Arbitrary+serde_as LoadConstant
acl-cqc f42da0a
FuncValueType: Arbitrary type or row var using SeqPart
acl-cqc 029469b
remove todo
acl-cqc e4a9a15
move any_type into proptest_utils
acl-cqc 9ebf211
Term::(new_list_concat->concat_lists) returns singleton - final fix, …
acl-cqc cd0a264
clippy
acl-cqc 2e362d5
Redefine TypeRowRV as Term; only a couple of fixes needed (dropping I…
acl-cqc 65eed1c
docs
acl-cqc e3089d7
rm SerTypeRow, directly impl (Des/S)erialize for TypeRow
acl-cqc ba34337
Remove trait Substitutable
acl-cqc e224c5b
Merge branch 'acl/no_1type_row' into HEAD
acl-cqc 273b45b
clippy (inc 4*std::slice::from_ref)
acl-cqc 536e511
docs
acl-cqc 5c69585
update hugr-llvm snapshot updates...right
acl-cqc 3601613
and some more
acl-cqc f85724a
Re-pub into_list/tuple_parts, new_list/tuple_from_parts, SeqPart
acl-cqc f5047be
Fix ops/constant.rs...no way to do serde_as SerType ??
acl-cqc f226d19
Rm commented-out from<TypeBase<RV>> for Term
acl-cqc File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a nice example of where we go back on #2784: this "row variable" previously had to be written in square brackets so it could be placed as an element of a TypeRow, despite the variable standing for a list itself