J
John Smith
After reading C# documentation the Conditional attribute seemed the way to
go, but after inspecting the IL it seems those methods are still there and I
imagine the CLR removes them. Using #if DEBUG means the code does not even
reach the IL when compiling in release mode.
Is there any benefit to using the Conditional Attribute? Am I right in
thinking there will small performance overhead using [Conditional("DEBUG")]
over #if DEBUG.
go, but after inspecting the IL it seems those methods are still there and I
imagine the CLR removes them. Using #if DEBUG means the code does not even
reach the IL when compiling in release mode.
Is there any benefit to using the Conditional Attribute? Am I right in
thinking there will small performance overhead using [Conditional("DEBUG")]
over #if DEBUG.