1 1.4 rillig /* $NetBSD: msg_360.c,v 1.4 2024/11/05 06:23:04 rillig Exp $ */ 2 1.1 rillig # 3 "msg_360.c" 3 1.1 rillig 4 1.1 rillig // Test for message: missing new-style number base after '\177' [360] 5 1.1 rillig 6 1.1 rillig /* 7 1.1 rillig * The new-style format requires the number base as the second character. 8 1.4 rillig * This check is merely a byproduct of the implementation, it provides little 9 1.4 rillig * value of its own. 10 1.1 rillig */ 11 1.1 rillig 12 1.1 rillig /* lint1-extra-flags: -X 351 */ 13 1.1 rillig 14 1.1 rillig typedef typeof(sizeof(0)) size_t; 15 1.1 rillig typedef unsigned long long uint64_t; 16 1.1 rillig 17 1.3 rillig int snprintb(char *, size_t, const char *, uint64_t); 18 1.1 rillig 19 1.1 rillig void 20 1.1 rillig new_style_number_base(void) 21 1.1 rillig { 22 1.1 rillig char buf[64]; 23 1.1 rillig 24 1.1 rillig /* expect+1: warning: missing new-style number base after '\177' [360] */ 25 1.1 rillig snprintb(buf, sizeof(buf), "\177", 0); 26 1.2 rillig /* expect+1: warning: number base '\002' is 2, must be 8, 10 or 16 [361] */ 27 1.1 rillig snprintb(buf, sizeof(buf), "\177\002", 0); 28 1.1 rillig } 29