diff options
author | johnvg | 2013-04-02 15:26:26 +0000 |
---|---|---|
committer | johnvg | 2013-04-02 15:26:26 +0000 |
commit | d4e397a35be100674c23b2c863210136d5b5d35c (patch) | |
tree | e314addf40d5e1b8ea31701a80dc2435d7ac2b90 /frontend/unitype.dcl | |
parent | in function adjust_type_code, add alternative for TCE_Selector, (diff) |
add type constraints in constructors and function arguments with universal quantifier (from iTask branch)
git-svn-id: https://svn.cs.ru.nl/repos/clean-compiler/trunk@2218 1f8540f1-abd5-4d5b-9d24-4c5ce8603e2d
Diffstat (limited to 'frontend/unitype.dcl')
-rw-r--r-- | frontend/unitype.dcl | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/frontend/unitype.dcl b/frontend/unitype.dcl index 12512e2..438637e 100644 --- a/frontend/unitype.dcl +++ b/frontend/unitype.dcl @@ -9,9 +9,7 @@ import syntax, analunitypes , crc_td_infos :: !.TypeDefInfos } -class coerce a :: !Sign !{# CommonDefs} !{# BOOLVECT} !TypePosition !a !a !*CoercionState -> (!Optional TypePosition, !*CoercionState) - -instance coerce AType +coerce :: !Sign !{#CommonDefs} !{#BOOLVECT} !TypePosition !AType !AType !*CoercionState -> (!Optional TypePosition, !*CoercionState) :: TypePosition :== [Int] @@ -39,9 +37,8 @@ BITINDEX temp_var_id :== temp_var_id >> 5 BITNUMBER temp_var_id :== temp_var_id bitand 31 set_bit :: !Int !*{# BOOLVECT} -> .{# BOOLVECT} -determineAttributeCoercions :: !AType !AType !Bool !u:{! Type} !*Coercions !{# CommonDefs } - !{# BOOLVECT } !*TypeDefInfos !*TypeHeaps - -> (!Optional (TypePosition, AType), !u:{! Type}, !*Coercions, !*TypeDefInfos, !*TypeHeaps) +determineAttributeCoercions :: !AType !AType !Bool !u:{!Type} !*Coercions !{#CommonDefs} !{#BOOLVECT} !*TypeDefInfos !*TypeHeaps + -> (!Optional (TypePosition, AType), !u:{!Type}, !*Coercions, !*TypeDefInfos, !*TypeHeaps) :: AttributePartition :== {# Int} |