Introduce derived flag for namespaces.

Change-Id: I77145a6039ec7dc2f90df706d523abf9d9274b27