DateTime object not bound by its timestamp?
问题 Is a DateTime object not bound by its timestamp? Or does getTimestamp() has some kind of side-effect when used on DST change? Details When setting the timestamp of a DateTime object which is on DST (meaning the formatted time exists both before/after changing the clock) the returned timestamp differs from the set timestamp. $ php --version PHP 7.1.3 (cli) (built: Mar 17 2017 16:59:59) ( NTS ) Copyright (c) 1997-2017 The PHP Group Zend Engine v3.1.0, Copyright (c) 1998-2017 Zend Technologies