kDebugMode top-level constant

const kDebugMode = !kReleaseMode && !kProfileMode

A constant that is true if the application was compiled in debug mode.

More specifically, this is a constant that is true if the application was not compiled with '-Ddart.vm.product=true' and '-Ddart.vm.profile=true'.

Since this is a const value, it can be used to indicate to the compiler that a particular block of code will not be executed in debug mode, and hence can be removed.

Implementation

const bool kDebugMode = !kReleaseMode && !kProfileMode