On 25/01/2022 19:44, Chase Peeler wrote:
If we start throwing exceptions, which can't be suppressed, it will make
this much more difficult to read since the constants.php will have to be
updated:
if(!defined('dbserver')){
define('dbserver','productiondb.example.com');
}
if(!defined('othercons
On Tue, Jan 25, 2022 at 9:45 PM Chase Peeler wrote:
> it will make this much more difficult to read since the constants.php will
> have to be
> updated:
>
> if(!defined('dbserver')){
> define('dbserver','productiondb.example.com');
> }
> if(!defined('otherconstant')){
>define('otherconstan
On Tue, Jan 25, 2022 at 3:08 PM Kamil Tekiela wrote:
> A constant is a value that, unlike a variable, cannot be reassociated with
> a different value. A properly written software should never redefine
> constants. The possibility of redefining constants in PHP should be
> considered a bug rather
A constant is a value that, unlike a variable, cannot be reassociated with
a different value. A properly written software should never redefine
constants. The possibility of redefining constants in PHP should be
considered a bug rather than a feature.
Constants are not good for configuration values
We have a main "constants.php" file that resides in git. The first line of
constants.php includes local_constants.php, which is kept out of git. The
idea is that we can "override" any of the constants on a per server basis.
constants.php:
@define('dbserver','productiondb.example.com');
local_cons
On Tue, Jan 25, 2022 at 2:47 AM Mark Randall wrote:
> Let's open a discussion as to what we might want to do in the future,
> and depending on how things shake out, we can decide what route to take
> with regards to bringing RFCs to vote.
My personal opinion: there should be no old style errors