I’ve stumbled upon the following two “weird” looking properties:
Process.GetCurrentProcess().MainModule;
Assembly.GetExecutingAssembly().Location;
These properties are a part of the class Process and Assembly, but the properties are only accessible from methods inside those classes.
Neither Private or Protected restricts properties to only being useable from methods inside the same class.
What do you call the protection level of these properties or how does this work at all?
GetExecutingAssembly is a static method that return a process Type, With this type you can access the public properties such as MainModule like this:
So you confused a class and a object of that class.