From patchwork Fri Feb 8 02:01:39 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: TAMUKI Shoichi X-Patchwork-Id: 31352 Received: (qmail 89596 invoked by alias); 8 Feb 2019 02:02:10 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 89587 invoked by uid 89); 8 Feb 2019 02:02:09 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-25.9 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 spammy=H*Ad:D*jp X-HELO: mail.linet.jp Message-Id: <201902080201.AA04236@tamuki.linet.gr.jp> Date: Fri, 08 Feb 2019 11:01:39 +0900 To: libc-alpha@sourceware.org Subject: [PATCH v3] tst-strftime2: Use array_length macros instead of magic numbers From: TAMUKI Shoichi MIME-Version: 1.0 ChangeLog: * time/tst-strftime2.c: Use array_length macros instead of magic numbers. --- Remarks: Compared with v2, I just brushed up the commit message a little. Since include/array_length.h has been pushed to master, if there is no problem, I will push this change to master in about 12 hours later. time/tst-strftime2.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/time/tst-strftime2.c b/time/tst-strftime2.c index 57d2144..3dca2a9 100644 --- a/time/tst-strftime2.c +++ b/time/tst-strftime2.c @@ -41,7 +41,8 @@ static const struct { 1, 3, 98 } }; -static char ref[3][3][6][100]; +static char ref[array_length (locales)][array_length (formats)] + [array_length (dates)][100]; static void mkreftable (void)