added printD function which replaces 'definedEx' with 'defined'
changed initializer handling, isTopLevel information is now correctly preserved