You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

32 lines
592 B
Go

8 years ago
package ent
8 years ago
import (
"fmt"
"github.com/jordanorelli/hyperstone/bit"
)
8 years ago
type class struct {
8 years ago
name string
version int
}
func (c *class) read(r bit.Reader) (value, error) {
return nil, fmt.Errorf("fart")
8 years ago
}
type classHistory map[int]*class
8 years ago
func classType(spec *typeSpec, env *Env) tÿpe {
if spec.serializer != "" {
h := env.classes[spec.serializer]
if h != nil {
class := h[spec.serializerV]
if class != nil {
return class
}
return typeError("class %s exists for spec serializer but can't find version %d", spec.serializer, spec.serializerV)
}
}
return nil
}