1--TEST-- 2GitHub #12043 segfault with IntlDateFormatter::dateType where it equals to UDAT_PATTERN (icu 50) but 3IntldateFormatter::timeType needs to be set as such. 4--EXTENSIONS-- 5intl 6--FILE-- 7<?php 8 9$datetime = new \DateTime('2017-05-12 23:11:00 GMT+2'); 10 11try { 12 new IntlDateFormatter( 13 locale: 'en', 14 dateType: IntlDateFormatter::PATTERN, 15 timeType: 0, 16 timezone: $datetime->getTimezone(), 17 ); 18} catch (\IntlException $e) { 19 echo $e->getMessage(); 20} 21 22?> 23--EXPECT-- 24datefmt_create: time format must be UDAT_PATTERN if date format is UDAT_PATTERN: U_ILLEGAL_ARGUMENT_ERROR 25