* @return root file scope for this compilation unit
*/
private ASFileScope createFileScope(final ResourceBundleFileNode fileNode)
{
List<IDefinition> definitions = getDefinitionPromises();
ASFileScope fileScope = new ASFileScope(fileNode);
String packageName = Multiname.getPackageNameForQName(definitions.get(0).getQualifiedName());
PackageScope packageScope = new PackageScope(fileScope, packageName);
packageScope.setContainingScope(fileScope);
PackageDefinition packageDefinition = new PackageDefinition(packageName);
packageDefinition.setContainedScope(packageScope);
fileScope.addDefinition(packageDefinition);
for(IDefinition def : definitions)
{
Multiname mname = Multiname.crackDottedQName(getProject(), def.getQualifiedName());
INamespaceDefinition packageNS = Iterables.getOnlyElement(mname.getNamespaceSet());