library property
Library that contains this element.
This will be the element itself if it is a library element. This will be
null
if this element is MultiplyDefinedElement2
that is not contained
in a library.
Implementation
@override
LibraryElementImpl get library {
var thisFragment = this as Fragment;
var enclosingFragment = thisFragment.enclosingFragment!;
var libraryFragment = enclosingFragment.libraryFragment;
libraryFragment as CompilationUnitElementImpl;
return libraryFragment.element;
}