add cost table

This commit is contained in:
Rígille S. B. Menezes 2021-09-27 15:25:23 -03:00
parent 5422437c62
commit ea93477de6

View File

@ -3,7 +3,7 @@
// TODO:
// - merge type-checking and validation / allow reusing word terms
// - cost measure
// - cost measure, WIP rígille
// - Lit.Core.Term.get_caller ?
// - owned types/constructors ?
// - conseguir modificar o dono no Lit.Core.Term.bind
@ -146,6 +146,27 @@ type Lit.Core.Statement {
Lit.Core.Page: Type
List<Lit.Core.Statement>
type Lit.Core.Costs {
new(
var: Nat
create: Nat
match: Nat
compare: Nat
operate: Nat
call: Nat
)
}
Lit.Core.Costs.default: Lit.Core.Costs
Lit.Core.Costs.new(
Nat.pow(2, 8*0)
Nat.pow(2, 8*1)
Nat.pow(2, 8*2)
Nat.pow(2, 8*3)
Nat.pow(2, 8*4)
Nat.pow(2, 8*5)
)
// Getters and Setters
// -------------------