• Keine Ergebnisse gefunden

haskell-classes and instances

N/A
N/A
Protected

Academic year: 2021

Aktie "haskell-classes and instances"

Copied!
2
0
0

Wird geladen.... (Jetzt Volltext ansehen)

Volltext

(1)

haskell-classes and instances

topdecl → . . .

| class tyconstr var [where {cdecl1; . . . ; cdecln}], n ≥ 1

| instance tyconstr instype [where {idecl1; . . . ; idecln}]

cdecl → typedecl | fundecl | infixdecl | var rhs instype → (tyconstr var1 . . . varn), n ≥ 0

| [var]

| (var1 → var2)

| (var1, . . . , varn), n ≥ 2 idecl → fundecl | var rhs

19

(2)

haskell-contexts

context → (tyconstr

1var1, . . . , tyconstr

nvarn), n ≥ 1 typedecl → var1, . . . , varn :: [context ⇒] type, n ≥ 1 topdecl → decl

| type . . .

| data . . .

| class [context ⇒] tyconstr var [where . . .]

| instance [context ⇒] tyconstr instype [where . . .]

20

Referenzen

ÄHNLICHE DOKUMENTE

•  During program execution, objects of declared classes are created (instances).. •  Classes cannot be modified

In software development, a domain-specific language (DSL) is a programming language or specification language dedicated to a particular problem domain, a particular

Imprecise Error Semantics [Peyton Jones et al... Imprecise Error Semantics [Peyton Jones

•  set of those Decision problems, for that an algorithm exists, which solves the problem and which consumes no more than polynomial runtime.. The class P:

termAlg = JavaAlg id Skip Assign Cond Loop IntE Var Sub Sum Prod BoolE Greater Not.. Beispiel Generic evaluation of

Thickening and Theta inflation with the analysis in the proof of Lemma 5.6 suffice to show that every point is as hard as computing the coefficients of F ( G ; w ) without

⇒ member functions which either are virtual, i.e., are called depending on the run-time type or non-virtual, i.e., called according to the static type of an object :-).. ⇒ static

Figure 2.5 summarizes the last paragraphs and shows the overall structure of a single database instance. Virtual columns, which are not explicitly stored, are indicated only by