File tree Expand file tree Collapse file tree 3 files changed +6
-6
lines changed
Expand file tree Collapse file tree 3 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ public override IEnumerable<IExtractionProduct> Contents
3737 get
3838 {
3939 var directoryName = System . IO . Path . GetDirectoryName ( path ) ;
40- if ( directoryName == null )
40+ if ( directoryName is null )
4141 throw new InternalError ( $ "Directory name for path '{ path } ' is null.") ;
4242
4343 var parent = cx . CreateFolder ( directoryName ) ;
Original file line number Diff line number Diff line change @@ -146,7 +146,7 @@ sealed class DefinitionMethod : Method, IMember
146146 readonly PDB . IMethod ? methodDebugInformation ;
147147 readonly Type declaringType ;
148148
149- string name ;
149+ readonly string name ;
150150 LocalVariable [ ] ? locals ;
151151
152152 public MethodImplementation ? Implementation { get ; private set ; }
@@ -417,7 +417,7 @@ public MemberReferenceMethod(GenericContext gc, MemberReferenceHandle handle) :
417417
418418 var parentMethod = parent as Method ;
419419
420- var declType = parentMethod == null ? parent as Type : parentMethod . DeclaringType ;
420+ var declType = parentMethod is null ? parent as Type : parentMethod . DeclaringType ;
421421
422422 if ( declType is null )
423423 throw new InternalError ( "Parent context of method is not a type" ) ;
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ public sealed class Namespace : TypeContainer, INamespace
2020 public Namespace ? ParentNamespace ;
2121 public readonly string Name ;
2222
23- public bool IsGlobalNamespace => ParentNamespace == null ;
23+ public bool IsGlobalNamespace => ParentNamespace is null ;
2424
2525 public override string IdSuffix => ";namespace" ;
2626
@@ -85,8 +85,8 @@ public override IEnumerable<IExtractionProduct> Contents
8585 get
8686 {
8787 yield return Tuples . namespaces ( this , Name ) ;
88- if ( ! IsGlobalNamespace )
89- yield return Tuples . parent_namespace ( this , ParentNamespace ! ) ;
88+ if ( ParentNamespace is object )
89+ yield return Tuples . parent_namespace ( this , ParentNamespace ) ;
9090 }
9191 }
9292 }
You can’t perform that action at this time.
0 commit comments