serialize scopes &  symbol tables