if you're ok with a var object, you can do:
    
    
    type Person = object
      first, last: string
    
    proc init(self: var Person, first, last: string) =
      self.first = first
      self.last = last
    
    proc `=`*[T](d: var Person; src: Person) {.error.} =
     discard
    
    var person : Person
    person.init("John", "Doe")
    echo person.first, " ", person.last
    

Reply via email to