code: func ParsePartialObjectDocRuleFromEqExpr(module *Module, lhs, rhs *Term) (*Rule, error) {
  
  	ref, ok := lhs.Value.(Ref)
  	if !ok || len(ref) != 2 {
  		return nil, fmt.Errorf("%v cannot be used for rule name", TypeName(lhs.Value))
  	}
  
  	name := ref[0].Value.(Var)
  	key := ref[1]
  
  	rule := &Rule{
  		Location: rhs.Location,
  		Head: &Head{
  			Location: rhs.Location,
  			Name:     name,
  			Key:      key,
  			Value:    rhs,
  		},
  		Body: NewBody(
  			NewExpr(BooleanTerm(true).SetLocation(rhs.Location)).SetLocation(rhs.Location),
  		),
  		Module: module,
  	}
  
  	return rule, nil
  }
docs: // ParsePartialObjectDocRuleFromEqExpr returns a rule if the expression can be
  // interpreted as a partial object document definition.