debugging desctruction error
fix SchemeBuffer (char*) buffer problems
add ref-const to return val of schememetadata
add some assertion and validation to schememetadata.