Transformation of Applicative Specifications into Imperative ...

Transformation of Applicative Specifications into Imperative ... Transformation of Applicative Specifications into Imperative ...

26.09.2013 Views

APPENDIX D. SPECIFICATION OF TRANSFORMER IN RSL1 BOOL_FFP_ENV_TYPES_LDL TRFFPProduct(ffpl, tel, trans, env, types, prlet) ≡ if lengthBinding(binding_list(ffpl)) = 0 then if not(tel = 〈〉) then mk_BOOL_FFP_ENV_TYPES_LDL( false, mk_FormalFunctionParameter(〈〉), env, types, prlet) else mk_BOOL_FFP_ENV_TYPES_LDL( true, mk_FormalFunctionParameter(〈〉), env, types, prlet) end else case hd binding_list(ffpl) of Make_ProductBinding(pb) → if emptyList( binding_list( formalfp( TRFormalFuncParam( mk_FormalFunctionParameter( binding_list(pb)), hd tel, trans, env, types, prlet)))) then mk_BOOL_FFP_ENV_TYPES_LDL( and( bool( TRFormalFuncParam( mk_FormalFunctionParameter( binding_list(pb)), hd tel, trans, env, types, prlet)), bool( TRFFPProduct( mk_FormalFunctionParameter( tl binding_list(ffpl)), tl tel, trans, envMap( TRFormalFuncParam( mk_FormalFunctionParameter( binding_list(pb)), hd tel, trans, env, types, prlet)), 364

D.2. FORMAL SPECIFICATION OF THE TRANSFORMER IN RSL1 typesMap( TRFormalFuncParam( mk_FormalFunctionParameter( binding_list(pb)), hd tel, trans, env, types, prlet)), letdefList( TRFormalFuncParam( mk_FormalFunctionParameter( binding_list(pb)), hd tel, trans, env, types, prlet))))), mk_FormalFunctionParameter( binding_list( formalfp( TRFFPProduct( mk_FormalFunctionParameter( tl binding_list(ffpl)), tl tel, trans, envMap( TRFormalFuncParam( mk_FormalFunctionParameter( binding_list(pb)), hd tel, trans, env, types, prlet)), typesMap( TRFormalFuncParam( mk_FormalFunctionParameter( binding_list(pb)), hd tel, trans, env, types, prlet)), letdefList( TRFormalFuncParam( mk_FormalFunctionParameter( binding_list(pb)), hd tel, trans, env, types, prlet)))))), envMap( TRFFPProduct( mk_FormalFunctionParameter( tl binding_list(ffpl)), tl tel, trans, envMap( TRFormalFuncParam( 365

D.2. FORMAL SPECIFICATION OF THE TRANSFORMER IN RSL1<br />

typesMap(<br />

TRFormalFuncParam(<br />

mk_FormalFunctionParameter(<br />

binding_list(pb)),<br />

hd tel, trans, env, types,<br />

prlet)),<br />

letdefList(<br />

TRFormalFuncParam(<br />

mk_FormalFunctionParameter(<br />

binding_list(pb)),<br />

hd tel, trans, env, types,<br />

prlet))))),<br />

mk_FormalFunctionParameter(<br />

binding_list(<br />

formalfp(<br />

TRFFPProduct(<br />

mk_FormalFunctionParameter(<br />

tl binding_list(ffpl)),<br />

tl tel, trans,<br />

envMap(<br />

TRFormalFuncParam(<br />

mk_FormalFunctionParameter(<br />

binding_list(pb)),<br />

hd tel, trans, env,<br />

types, prlet)),<br />

typesMap(<br />

TRFormalFuncParam(<br />

mk_FormalFunctionParameter(<br />

binding_list(pb)),<br />

hd tel, trans, env,<br />

types, prlet)),<br />

letdefList(<br />

TRFormalFuncParam(<br />

mk_FormalFunctionParameter(<br />

binding_list(pb)),<br />

hd tel, trans, env,<br />

types, prlet)))))),<br />

envMap(<br />

TRFFPProduct(<br />

mk_FormalFunctionParameter(<br />

tl binding_list(ffpl)), tl tel,<br />

trans,<br />

envMap(<br />

TRFormalFuncParam(<br />

365

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!