icu::DateTimePatternGenerator::createInstance returns U_MISSING_RESOURCE_ERROR when default locale = ROOT and input locale is invalid

Description

Reproduced the issue with ICU 63 and latest ICU codes.

1 2 3 4 5 6 7 8 9 int main(int argc, char **argv) { UErrorCode status = U_ZERO_ERROR; uloc_setDefault("root", &status); icu::DateTimePatternGenerator::createInstance("abc", status); // "abc" is a invalid local printf("Error:%s\n", u_errorName(status)); // Error:U_MISSING_RESOURCE_ERROR u_cleanup(); return 0; }

GoogleIssue:129070579

Status

Assignee

Jeff Genovy

Reporter

Victor Chang

Reviewer

None

Time Needed

None

Start date

None

Components

Fix versions

Priority

critical