Andrei Borzenkov pushed to branch wip/sand-witch/make-set-field at Glasgow Haskell Compiler / GHC

Commits:

7 changed files:

Changes:

  • compiler/GHC/Builtin/Names.hs
    ... ... @@ -2308,7 +2308,7 @@ wildCardKey, absentErrorIdKey, absentConstraintErrorIdKey, augmentIdKey, appendI
    2308 2308
         noMethodBindingErrorIdKey, nonExhaustiveGuardsErrorIdKey,
    
    2309 2309
         impossibleErrorIdKey, impossibleConstraintErrorIdKey,
    
    2310 2310
         patErrorIdKey, voidPrimIdKey,
    
    2311
    -    realWorldPrimIdKey, recConErrorIdKey,
    
    2311
    +    realWorldPrimIdKey, recConErrorIdKey, recUpdErrorIdKey,
    
    2312 2312
         unpackCStringUtf8IdKey, unpackCStringAppendUtf8IdKey, unpackCStringFoldrUtf8IdKey,
    
    2313 2313
         unpackCStringIdKey, unpackCStringAppendIdKey, unpackCStringFoldrIdKey,
    
    2314 2314
         typeErrorIdKey, divIntIdKey, modIntIdKey,
    
    ... ... @@ -2409,6 +2409,7 @@ rationalToFloatIdKey = mkPreludeMiscIdUnique 132
    2409 2409
     rationalToDoubleIdKey  = mkPreludeMiscIdUnique 133
    
    2410 2410
     
    
    2411 2411
     seqHashKey             = mkPreludeMiscIdUnique 134
    
    2412
    +recUpdErrorIdKey       = mkPreludeMiscIdUnique 135
    
    2412 2413
     
    
    2413 2414
     coerceKey :: Unique
    
    2414 2415
     coerceKey                     = mkPreludeMiscIdUnique 157
    

  • compiler/GHC/Core/Make.hs
    ... ... @@ -42,7 +42,7 @@ module GHC.Core.Make (
    42 42
     
    
    43 43
             -- * Error Ids
    
    44 44
             mkRuntimeErrorApp, mkImpossibleExpr, mkAbsentErrorApp, errorIds,
    
    45
    -        rEC_CON_ERROR_ID,
    
    45
    +        rEC_CON_ERROR_ID, rEC_UPD_ERROR_ID,
    
    46 46
             nON_EXHAUSTIVE_GUARDS_ERROR_ID, nO_METHOD_BINDING_ERROR_ID,
    
    47 47
             pAT_ERROR_ID, rEC_SEL_ERROR_ID,
    
    48 48
             tYPE_ERROR_ID, aBSENT_SUM_FIELD_ERROR_ID
    
    ... ... @@ -897,6 +897,7 @@ errorIds
    897 897
           nO_METHOD_BINDING_ERROR_ID,
    
    898 898
           pAT_ERROR_ID,
    
    899 899
           rEC_CON_ERROR_ID,
    
    900
    +      rEC_UPD_ERROR_ID,
    
    900 901
           rEC_SEL_ERROR_ID,
    
    901 902
           iMPOSSIBLE_ERROR_ID, iMPOSSIBLE_CONSTRAINT_ERROR_ID,
    
    902 903
           aBSENT_ERROR_ID,  aBSENT_CONSTRAINT_ERROR_ID,
    
    ... ... @@ -904,13 +905,14 @@ errorIds
    904 905
           tYPE_ERROR_ID   -- Used with Opt_DeferTypeErrors, see #10284
    
    905 906
           ]
    
    906 907
     
    
    907
    -recSelErrorName, recConErrorName, patErrorName :: Name
    
    908
    +recSelErrorName, recConErrorName, patErrorName, recUpdErrorName :: Name
    
    908 909
     nonExhaustiveGuardsErrorName, noMethodBindingErrorName :: Name
    
    909 910
     typeErrorName :: Name
    
    910 911
     absentSumFieldErrorName :: Name
    
    911 912
     
    
    912 913
     recSelErrorName     = err_nm "recSelError"     recSelErrorIdKey     rEC_SEL_ERROR_ID
    
    913 914
     recConErrorName     = err_nm "recConError"     recConErrorIdKey     rEC_CON_ERROR_ID
    
    915
    +recUpdErrorName     = err_nm "recUpdError"     recUpdErrorIdKey     rEC_UPD_ERROR_ID
    
    914 916
     patErrorName        = err_nm "patError"        patErrorIdKey        pAT_ERROR_ID
    
    915 917
     typeErrorName       = err_nm "typeError"       typeErrorIdKey       tYPE_ERROR_ID
    
    916 918
     
    
    ... ... @@ -922,11 +924,12 @@ nonExhaustiveGuardsErrorName = err_nm "nonExhaustiveGuardsError"
    922 924
     err_nm :: String -> Unique -> Id -> Name
    
    923 925
     err_nm str uniq id = mkWiredInIdName gHC_INTERNAL_CONTROL_EXCEPTION_BASE (fsLit str) uniq id
    
    924 926
     
    
    925
    -rEC_SEL_ERROR_ID, rEC_CON_ERROR_ID :: Id
    
    927
    +rEC_SEL_ERROR_ID, rEC_CON_ERROR_ID, rEC_UPD_ERROR_ID :: Id
    
    926 928
     pAT_ERROR_ID, nO_METHOD_BINDING_ERROR_ID, nON_EXHAUSTIVE_GUARDS_ERROR_ID :: Id
    
    927 929
     tYPE_ERROR_ID, aBSENT_SUM_FIELD_ERROR_ID :: Id
    
    928 930
     rEC_SEL_ERROR_ID                = mkRuntimeErrorId TypeLike recSelErrorName
    
    929 931
     rEC_CON_ERROR_ID                = mkRuntimeErrorId TypeLike recConErrorName
    
    932
    +rEC_UPD_ERROR_ID                = mkRuntimeErrorId TypeLike recUpdErrorName
    
    930 933
     pAT_ERROR_ID                    = mkRuntimeErrorId TypeLike patErrorName
    
    931 934
     nO_METHOD_BINDING_ERROR_ID      = mkRuntimeErrorId TypeLike noMethodBindingErrorName
    
    932 935
     nON_EXHAUSTIVE_GUARDS_ERROR_ID  = mkRuntimeErrorId TypeLike nonExhaustiveGuardsErrorName
    

  • compiler/GHC/Tc/Instance/Class.hs
    ... ... @@ -1340,7 +1340,7 @@ matchSetField dflags short_cut clas tys mb_ct_loc
    1340 1340
                              -- Use the equality proof to cast the selector Id to
    
    1341 1341
                              -- type (r -> a), then use the newtype coercion to cast
    
    1342 1342
                              -- it to a HasField dictionary.
    
    1343
    -                         mk_ev (ev1:ev2:evs) = evDFunApp (dataConWrapId dCon) (tys ++ tvs) 
    
    1343
    +                         mk_ev (ev1:ev2:evs) = evDFunApp (dataConWrapId dCon) tys 
    
    1344 1344
                                   [ evSelector modifier_id tvs evs `Cast` co ev2
    
    1345 1345
                                   , evSelector setter_id tvs evs `Cast` co ev1 
    
    1346 1346
                                   ]
    
    ... ... @@ -1395,7 +1395,7 @@ matchSetField dflags short_cut clas tys mb_ct_loc
    1395 1395
                     pure (setter, modifier)
    
    1396 1396
                   Nothing -> do
    
    1397 1397
                     binds@((setter, _), (modifier,_)) <- mkSetFieldBinds tycon fl
    
    1398
    -                writeTcRef req_flds ((fl, binds) : reqs)
    
    1398
    +                updTcRef req_flds ((fl, binds) : )
    
    1399 1399
                     pure (setter, modifier)
    
    1400 1400
          
    
    1401 1401
          tc_inst_setfield_binds setter_id modifier_id
    

  • compiler/GHC/Tc/Module.hs
    ... ... @@ -579,12 +579,13 @@ tcRnSrcDecls explicit_mod_hdr export_ies decls
    579 579
             -- Emit Typeable bindings
    
    580 580
           ; tcg_env <- setGblEnv tcg_env $
    
    581 581
                        mkTypeableBinds
    
    582
    +
    
    582 583
           ; (tcg_env, recs_lie) <- setGblEnv tcg_env $
    
    583 584
                        captureTopConstraints $
    
    584 585
                        tcRecSetterBinds
    
    585 586
     
    
    586 587
           ; rec_ev_binds <- restoreEnvs (tcg_env, tcl_env) $ 
    
    587
    -                          simplifyTop recs_lie -- Is that required?
    
    588
    +                          simplifyTop recs_lie -- TODO sand-witch: Is that required?
    
    588 589
     
    
    589 590
           ; let new_ev_binds = main_ev_binds `mappend` rec_ev_binds
    
    590 591
     
    

  • compiler/GHC/Tc/TyCl/Utils.hs
    ... ... @@ -42,7 +42,7 @@ import GHC.Hs
    42 42
     import GHC.Core.TyCo.Rep( Type(..), Coercion(..), MCoercion(..) )
    
    43 43
     import GHC.Core.Multiplicity
    
    44 44
     import GHC.Core.Predicate
    
    45
    -import GHC.Core.Make( rEC_SEL_ERROR_ID )
    
    45
    +import GHC.Core.Make( rEC_SEL_ERROR_ID, rEC_UPD_ERROR_ID )
    
    46 46
     import GHC.Core.Class
    
    47 47
     import GHC.Core.Type
    
    48 48
     import GHC.Core.TyCon
    
    ... ... @@ -868,19 +868,22 @@ mkRecSelBind (tycon, fl)
    868 868
     mkOneRecordSelector :: [ConLike] -> RecSelParent -> FieldLabel -> FieldSelectors
    
    869 869
                         -> (Id, LHsBind GhcRn)
    
    870 870
     mkOneRecordSelector all_cons idDetails fl has_sel
    
    871
    -  = collectFieldLabelInfo all_cons idDetails fl has_sel mkRecordSelectorBind 
    
    871
    +  = collectFieldLabelInfo all_cons idDetails fl has_sel mkRecordSelectorBind
    
    872 872
     
    
    873 873
     mkRecordSelectorBind :: RecordBindBuilder (Id, LHsBind GhcRn)
    
    874
    -mkRecordSelectorBind = mk_record_bind mk_sel_ty mk_match where
    
    874
    +mkRecordSelectorBind fl = mk_record_bind 1 err_expr mk_sel_ty mk_match fl where
    
    875
    +
    
    876
    +  err_expr = make_rec_error_expr fl rEC_SEL_ERROR_ID
    
    877
    +
    
    875 878
       mk_sel_ty :: Type -> Type -> Type
    
    876
    -  mk_sel_ty data_ty field_ty = 
    
    879
    +  mk_sel_ty data_ty field_ty =
    
    877 880
           mkVisFunTyMany data_ty            $
    
    878 881
             -- Record selectors are always typed with Many. We
    
    879 882
             -- could improve on it in the case where all the
    
    880 883
             -- fields in all the constructor have multiplicity Many.
    
    881 884
           field_ty
    
    882 885
     
    
    883
    -  mk_match sel_name match_ctxt con = 
    
    886
    +  mk_match sel_name match_ctxt con =
    
    884 887
           mkSimpleMatch match_ctxt
    
    885 888
             (L loc [L loc (mk_sel_pat con)])
    
    886 889
             (L loc (mkHsVar (L loc field_var)))
    
    ... ... @@ -915,7 +918,7 @@ tcRecSetterBinds = do
    915 918
       where
    
    916 919
         remove_binds (n, ((setter, _), (modifier, _))) = (flSelector n, (setter, modifier))
    
    917 920
         get_ids_to_check [] = []
    
    918
    -    get_ids_to_check ( (_, (setter, modifier)) : flds) = 
    
    921
    +    get_ids_to_check ( (_, (setter, modifier)) : flds) =
    
    919 922
             setter : modifier : get_ids_to_check flds
    
    920 923
     
    
    921 924
     
    
    ... ... @@ -928,41 +931,44 @@ mkSetFieldBinds tycon fl =
    928 931
         idDetails = RecSelData tycon
    
    929 932
     
    
    930 933
         mk_field_lbl prefix uniq =
    
    931
    -      let 
    
    934
    +      let
    
    932 935
             lbl = flLabel fl
    
    933 936
             newOcc = mkOccNameFS varName (mkFastString prefix `mappend` field_label lbl)
    
    934
    -      in fl {flSelector = flSelector fl `setNameUnique` uniq `tidyNameOcc` newOcc}
    
    937
    +      in fl { flSelector = flSelector fl `setNameUnique` uniq `tidyNameOcc` newOcc }
    
    935 938
     
    
    936 939
         mk_binds cons_w_field rec_details ty_builder = do
    
    937 940
           setter_fl <- mk_field_lbl "setter_" <$> newUnique
    
    938
    -      modifier_fd <- mk_field_lbl "modifier_" <$> newUnique
    
    941
    +      modifier_fl <- mk_field_lbl "modifier_" <$> newUnique
    
    939 942
           let setter_bind = mkRecordSetterBind fl setter_fl all_cons cons_w_field rec_details ty_builder
    
    940
    -          modifier_bind = mkRecordModifierBind fl modifier_fd all_cons cons_w_field rec_details ty_builder
    
    943
    +          modifier_bind = mkRecordModifierBind fl modifier_fl all_cons cons_w_field rec_details ty_builder
    
    941 944
           pure (setter_bind, modifier_bind)
    
    942 945
     
    
    943
    -
    
    944 946
     mkRecordSetterBind :: FieldLabel -> RecordBindBuilder (Id, LHsBind GhcRn)
    
    945
    -mkRecordSetterBind origFl fl = mk_record_bind mkRecordSetterType mk_match fl where
    
    947
    +mkRecordSetterBind origFl fl = mk_record_bind 2 err_expr mkRecordSetterType mk_match fl where
    
    946 948
     
    
    947
    -  mk_match = 
    
    948
    -    mk_set_fld_match (getOccName $ flSelector fl) origFl $ 
    
    949
    +  err_expr = make_rec_error_expr origFl rEC_UPD_ERROR_ID
    
    950
    +
    
    951
    +  mk_match =
    
    952
    +    mk_set_fld_match (getOccName $ flSelector origFl) origFl $
    
    949 953
           \_ field_var -> (genWildPat, genLHsVar field_var)
    
    950 954
     
    
    951 955
     mkRecordSetterType :: Type -> Type -> Type
    
    952
    -mkRecordSetterType data_ty field_ty = 
    
    956
    +mkRecordSetterType data_ty field_ty =
    
    953 957
         mkVisFunTyMany field_ty $
    
    954 958
         mkVisFunTyMany data_ty data_ty
    
    955 959
     
    
    956 960
     mkRecordModifierBind :: FieldLabel -> RecordBindBuilder (Id, LHsBind GhcRn)
    
    957
    -mkRecordModifierBind origFl fl = mk_record_bind mkRecordModifierType mk_match fl where
    
    961
    +mkRecordModifierBind origFl fl = mk_record_bind 2 err_expr mkRecordModifierType mk_match fl where
    
    962
    +
    
    963
    +  err_expr = make_rec_error_expr origFl rEC_UPD_ERROR_ID
    
    958 964
     
    
    959
    -  mk_match = mk_set_fld_match (mkOccName varName "f") origFl $ \i fun_var -> 
    
    965
    +  mk_match = mk_set_fld_match (mkOccName varName "f") origFl $ \i fun_var ->
    
    960 966
           let fld_nm = mk_set_fld_bind i fl
    
    961 967
               expr = wrapGenSpan $ HsPar noExtField $ genLHsApp (genHsVar fun_var) (genLHsVar fld_nm)
    
    962 968
           in (genVarPat fld_nm, expr)
    
    963 969
     
    
    964 970
     mkRecordModifierType :: Type -> Type -> Type
    
    965
    -mkRecordModifierType data_ty field_ty = 
    
    971
    +mkRecordModifierType data_ty field_ty =
    
    966 972
         mkVisFunTyMany (mkVisFunTyMany field_ty field_ty) $
    
    967 973
         mkVisFunTyMany data_ty data_ty
    
    968 974
     
    
    ... ... @@ -981,11 +987,11 @@ mk_set_fld_match occ_name fl on_fld setter_name match_ctxt con =
    981 987
         loc = noAnnSrcSpan (getSrcSpan setter_name)
    
    982 988
     
    
    983 989
     
    
    984
    -    mk_con_arg i fld_lbl 
    
    990
    +    mk_con_arg i fld_lbl
    
    985 991
           | fl == fld_lbl = on_fld i arg_var
    
    986 992
           | otherwise =
    
    987 993
               let fld_nm = mk_set_fld_bind i fld_lbl
    
    988
    -                      in (genVarPat fld_nm, genLHsVar fld_nm) 
    
    994
    +                      in (genVarPat fld_nm, genLHsVar fld_nm)
    
    989 995
     
    
    990 996
         arg_var = mkInternalName (mkBuiltinUnique 1) occ_name loc
    
    991 997
     
    
    ... ... @@ -993,14 +999,14 @@ mk_set_fld_bind :: Int -> FieldLabel -> Name
    993 999
     mk_set_fld_bind i fld_lbl =
    
    994 1000
       mkInternalName (mkBuiltinUnique i)
    
    995 1001
         (nameOccName $ flSelector $ fld_lbl)
    
    996
    -    generatedSrcSpan 
    
    1002
    +    generatedSrcSpan
    
    997 1003
     
    
    998 1004
     type ConLikeWithField = ConLike
    
    999 1005
     
    
    1000
    -type RecordBindBuilder r = 
    
    1006
    +type RecordBindBuilder r =
    
    1001 1007
       FieldLabel -> [ConLike] -> [ConLikeWithField] -> IdDetails -> ((Type -> Type -> Type) -> Type) -> r
    
    1002 1008
     
    
    1003
    -type FldBindMatchBuilder = 
    
    1009
    +type FldBindMatchBuilder =
    
    1004 1010
       Name -> HsMatchContext (LocatedN Name) -> ConLikeWithField -> LMatch GhcRn (LHsExpr GhcRn)
    
    1005 1011
     
    
    1006 1012
     collectFieldLabelInfo :: [ConLike] ->
    
    ... ... @@ -1052,7 +1058,7 @@ collectFieldLabelInfo all_cons idDetails fl has_sel k
    1052 1058
                                                       -- A slight hack!
    
    1053 1059
     
    
    1054 1060
         sel_ty | is_naughty = \_ -> unitTy  -- See Note [Naughty record selectors]
    
    1055
    -           | otherwise  = \mk_ty -> 
    
    1061
    +           | otherwise  = \mk_ty ->
    
    1056 1062
                               mkForAllTys (tyVarSpecToBinders sel_tvbs) $
    
    1057 1063
                               -- Urgh! See Note [The stupid context] in GHC.Core.DataCon
    
    1058 1064
                               mkPhiTy (conLikeStupidTheta con1) $
    
    ... ... @@ -1060,11 +1066,21 @@ collectFieldLabelInfo all_cons idDetails fl has_sel k
    1060 1066
                               mkPhiTy req_theta                 $
    
    1061 1067
                               mk_ty data_ty field_ty
    
    1062 1068
     
    
    1063
    -mk_record_bind :: 
    
    1069
    +make_rec_error_expr :: FieldLabel -> Id -> LHsExpr GhcRn
    
    1070
    +make_rec_error_expr fl err_id =
    
    1071
    +  genLHsApp
    
    1072
    +      (genHsVar (getName err_id))
    
    1073
    +      (genLHsLit msg_lit)
    
    1074
    +  where
    
    1075
    +    msg_lit = HsStringPrim NoSourceText (bytesFS (field_label (flLabel fl)))
    
    1076
    +
    
    1077
    +mk_record_bind ::
    
    1078
    +  Int ->
    
    1079
    +  LHsExpr GhcRn ->
    
    1064 1080
       (Type -> Type -> Type) ->
    
    1065 1081
       FldBindMatchBuilder ->
    
    1066 1082
       RecordBindBuilder (Id, LHsBind GhcRn)
    
    1067
    -mk_record_bind mk_ty mk_match fl all_cons cons_w_field rec_details ty_builder
    
    1083
    +mk_record_bind num_args err_expr mk_ty mk_match fl all_cons cons_w_field rec_details ty_builder
    
    1068 1084
       = (sel_id, L loc sel_bind)
    
    1069 1085
       where
    
    1070 1086
         sel_ty = ty_builder mk_ty
    
    ... ... @@ -1092,10 +1108,8 @@ mk_record_bind mk_ty mk_match fl all_cons cons_w_field rec_details ty_builder
    1092 1108
         -- We do this explicitly so that we get a nice error message that
    
    1093 1109
         -- mentions this particular record selector
    
    1094 1110
         deflt | all dealt_with all_cons = []
    
    1095
    -          | otherwise = [mkSimpleMatch match_ctxt (wrapGenSpan [genWildPat])
    
    1096
    -                            (genLHsApp
    
    1097
    -                                (genHsVar (getName rEC_SEL_ERROR_ID))
    
    1098
    -                                (genLHsLit msg_lit))]
    
    1111
    +          | otherwise = [mkSimpleMatch match_ctxt (wrapGenSpan (replicate num_args genWildPat))
    
    1112
    +                            err_expr]
    
    1099 1113
     
    
    1100 1114
             -- Do not add a default case unless there are unmatched
    
    1101 1115
             -- constructors.  We must take account of GADTs, else we
    
    ... ... @@ -1114,7 +1128,6 @@ mk_record_bind mk_ty mk_match fl all_cons cons_w_field rec_details ty_builder
    1114 1128
             inst_tys = dataConResRepTyArgs dc
    
    1115 1129
     
    
    1116 1130
         unit_rhs = mkLHsTupleExpr [] noExtField
    
    1117
    -    msg_lit = HsStringPrim NoSourceText (bytesFS (field_label (flLabel fl)))
    
    1118 1131
     
    
    1119 1132
     {-
    
    1120 1133
     Note [Polymorphic selectors]
    

  • compiler/GHC/Tc/Types.hs
    ... ... @@ -561,7 +561,7 @@ data TcGblEnv
    561 561
               -- they all have a non-empty gre_imp field.
    
    562 562
             tcg_keep      :: TcRef NameSet,
    
    563 563
     
    
    564
    -        tcg_requested_fields :: TcRef [(FieldLabel, ((Id, LHsBind GhcRn), (Id, LHsBind GhcRn)))],
    
    564
    +        tcg_requested_fields :: TcRef [(FieldLabel, (FieldBind, FieldBind))],
    
    565 565
     
    
    566 566
             tcg_th_used :: TcRef Bool,
    
    567 567
               -- ^ @True@ \<=> Template Haskell syntax used.
    
    ... ... @@ -706,7 +706,8 @@ data TcGblEnv
    706 706
             -- ^ See Note [Generating fresh names for FFI wrappers]
    
    707 707
         }
    
    708 708
     
    
    709
    -type FieldInstEnv = NameEnv (Id, Id) 
    
    709
    +type FieldInstEnv = NameEnv (Id, Id)
    
    710
    +type FieldBind = (Id, LHsBind GhcRn) 
    
    710 711
     
    
    711 712
     -- NB: topModIdentity, not topModSemantic!
    
    712 713
     -- Definition sites of orphan identities will be identity modules, not semantic
    

  • libraries/ghc-internal/src/GHC/Internal/Control/Exception/Base.hs
    ... ... @@ -104,7 +104,7 @@ module GHC.Internal.Control.Exception.Base (
    104 104
             finally,
    
    105 105
     
    
    106 106
             -- * Calls for GHC runtime
    
    107
    -        recSelError, recConError,
    
    107
    +        recSelError, recConError, recUpdError,
    
    108 108
             impossibleError, impossibleConstraintError,
    
    109 109
             nonExhaustiveGuardsError, patError, noMethodBindingError,
    
    110 110
             typeError,
    
    ... ... @@ -422,12 +422,14 @@ instance Exception NoMatchingContinuationPrompt
    422 422
     -----
    
    423 423
     
    
    424 424
     -- See Note [Compiler error functions] in ghc-internal:GHC.Internal.Prim.Panic
    
    425
    -recSelError, recConError, typeError,
    
    425
    +recSelError, recUpdError, recConError, typeError,
    
    426 426
       nonExhaustiveGuardsError, patError, noMethodBindingError
    
    427 427
             :: Addr# -> a   -- All take a UTF8-encoded C string
    
    428 428
     
    
    429 429
     recSelError              s = throw (RecSelError ("No match in record selector "
    
    430 430
                                                      ++ unpackCStringUtf8# s))  -- No location info unfortunately
    
    431
    +recUpdError              s = throw (RecUpdError ("No match in record update "
    
    432
    +                                                 ++ unpackCStringUtf8# s))  -- No location info unfortunately
    
    431 433
     nonExhaustiveGuardsError s = throw (PatternMatchFail (untangle s "Non-exhaustive guards in"))
    
    432 434
     recConError              s = throw (RecConError      (untangle s "Missing field in record construction"))
    
    433 435
     noMethodBindingError     s = throw (NoMethodError    (untangle s "No instance nor default method for class operation"))