diff options
author | johnvg | 2005-09-16 13:59:14 +0000 |
---|---|---|
committer | johnvg | 2005-09-16 13:59:14 +0000 |
commit | 0ae58d602fa6d478d88f501ce77663a34c6334e7 (patch) | |
tree | 01b3c4afcef039e277ad1772615d8d74bd05692d /frontend/postparse.icl | |
parent | make function markPatternVariables recursive to report an error (diff) |
make line number in the
"demanded attribute cannot be offered by shared object" error
message more accurate,
store position in CaseAlt (added field calt_position)
git-svn-id: https://svn.cs.ru.nl/repos/clean-compiler/trunk@1544 1f8540f1-abd5-4d5b-9d24-4c5ce8603e2d
Diffstat (limited to 'frontend/postparse.icl')
-rw-r--r-- | frontend/postparse.icl | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/frontend/postparse.icl b/frontend/postparse.icl index 228cba4..4cd3239 100644 --- a/frontend/postparse.icl +++ b/frontend/postparse.icl @@ -146,8 +146,8 @@ where # true_pattern = PE_Basic (BVB True) false_pattern = PE_WildCard // PE_Basic (BVB False) = collectFunctions (PE_Case if_ident c - [ {calt_pattern = true_pattern , calt_rhs = exprToRhs t} - , {calt_pattern = false_pattern, calt_rhs = exprToRhs e} + [ {calt_pattern = true_pattern , calt_rhs = exprToRhs t, calt_position=NoPos} + , {calt_pattern = false_pattern, calt_rhs = exprToRhs e, calt_position=NoPos} ]) icl_module ca collectFunctions (PE_Let strict locals in_expr) icl_module ca # ((node_defs,in_expr), ca) = collectFunctions (locals,in_expr) icl_module ca @@ -686,8 +686,8 @@ where # smaller_fun = get_predef_id PD_SmallerFun # (case_ident,ca) = prefixAndPositionToIdent ("g_s"+++toString n) gen_position ca = (PE_Case case_ident (PE_List [ident1,PE_Ident smaller_fun,ident2]) - [{calt_pattern = PE_Basic (BVB True), calt_rhs = exprToRhs ident1}, - {calt_pattern = PE_WildCard, calt_rhs = exprToRhs ident2}],ca) + [{calt_pattern = PE_Basic (BVB True), calt_rhs = exprToRhs ident1, calt_position=NoPos}, + {calt_pattern = PE_WildCard, calt_rhs = exprToRhs ident2, calt_position=NoPos}],ca) = (node_defs,to_exp,ident1,ca) store_minimum_of_sizes_in_generator :: [ParsedDefinition] ParsedExpr Int TransformedGenerator -> TransformedGenerator; @@ -948,8 +948,8 @@ makeComprehensions [{tq_generators,tq_let_defs,tq_filter, tq_end, tq_call, tq_lh = rhs case_with_default case_ident expr expr_is_uselect pattern rhs default_rhs = exprToRhs (PE_Case case_ident expr - [ {calt_pattern = pattern, calt_rhs = rhs} - , {calt_pattern = PE_WildCard, calt_rhs = exprToRhs default_rhs} + [ {calt_pattern = pattern, calt_rhs = rhs, calt_position=NoPos} + , {calt_pattern = PE_WildCard, calt_rhs = exprToRhs default_rhs, calt_position=NoPos} ]) /* +++ remove code duplication (bug in 2.0 with nested cases) |