Operational Semantics and Type Systems: Understanding Functional Programming, Study notes of Programming Languages

The operational semantics and type systems rules for the sint and typeint systems. It covers the basics of variable assignment, function definition, and function application using examples. This information is essential for anyone studying functional programming, especially those interested in the operational aspects of programming languages.

Typology: Study notes

Pre 2010

Uploaded on 02/13/2009

koofers-user-5dw
koofers-user-5dw 🇺🇸

9 documents

1 / 1

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Operational Semantics
SInt A`nnSVar x7→ vA
A`xv
SFun A`e2v A, x 7→ v`e1v0
A`(fun x=e1)e2v0SAdd A`e1v1A`e2v2
A`+e1e2v1+v2
Type Systems
TInt A`n:int TVar x:tA
A`x:t
TFun A, x :t`e:t0
A`λx :t.e :tt0TApp A`e1:tt0A`e2:t
A`e1e2:t0
1

Partial preview of the text

Download Operational Semantics and Type Systems: Understanding Functional Programming and more Study notes Programming Languages in PDF only on Docsity!

Operational Semantics

SInt A ` n → n

SVar x^7 →^ v^ ∈^ A A ` x → v

SFun

A e 2 → v A, x 7 → v e 1 → v′ A ` (fun x = e 1 ) e 2 → v′^

SAdd

A e 1 → v 1 A e 2 → v 2 A ` + e 1 e 2 → v 1 + v 2

Type Systems

TInt A ` n : int

TVar x^ :^ t^ ∈^ A A ` x : t

TFun

A, x : t e : t′ A λx : t.e : t → t′^

TApp

A e 1 : t → t′^ A e 2 : t A ` e 1 e 2 : t′