1// © 2017 and later: Unicode, Inc. and others.
2// License & terms of use: http://www.unicode.org/copyright.html
3/*
4******************************************************************************
5*
6*   Copyright (C) 2006-2008, International Business Machines
7*   Corporation and others.  All Rights Reserved.
8*
9******************************************************************************
10*
11*  FILE NAME : testTimezone.c
12*
13*   Date        Name        Description
14*   03/02/2006  grhoten     Creation.
15******************************************************************************
16*/
17#include "unicode/putil.h"
18#include "unicode/ucnv.h"
19#include "unicode/uloc.h"
20#include "unicode/ures.h"
21#include <stdbool.h>
22#include <stdio.h>
23#include <string.h>
24
25int main(int argc, const char* const argv[]) {
26    UErrorCode status = U_ZERO_ERROR;
27
28    ures_close(ures_open(NULL, NULL, &status));
29    if (status != U_ZERO_ERROR) {
30        printf("uloc_getDefault = %s\n", uloc_getDefault());
31        printf("Locale available in ICU = %s\n", status == U_ZERO_ERROR ? "true" : "false");
32    }
33    if (strcmp(ucnv_getDefaultName(), "US-ASCII") == 0) {
34        printf("uprv_getDefaultCodepage = %s\n", uprv_getDefaultCodepage());
35        printf("ucnv_getDefaultName = %s\n", ucnv_getDefaultName());
36    }
37    return 0;
38}
39