Mercurial > vim
comparison src/ex_cmds.c @ 8879:cea5ff374062 v7.4.1726
commit https://github.com/vim/vim/commit/700eefe5a4385fd128f5496e3ca384869752376a
Author: Bram Moolenaar <Bram@vim.org>
Date: Wed Apr 13 21:14:37 2016 +0200
patch 7.4.1726
Problem: ANSI compiler complains about string length.
Solution: Split long string in two parts. (Michael Jarvis)
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Wed, 13 Apr 2016 21:15:05 +0200 |
parents | 24b43dd167eb |
children | b7de875169e6 |
comparison
equal
deleted
inserted
replaced
8878:ff724c3a0746 | 8879:cea5ff374062 |
---|---|
7803 * Make the user happy. | 7803 * Make the user happy. |
7804 */ | 7804 */ |
7805 void | 7805 void |
7806 ex_smile(exarg_T *eap UNUSED) | 7806 ex_smile(exarg_T *eap UNUSED) |
7807 { | 7807 { |
7808 static char *code = "\34 \4o\14$\4ox\30 \2o\30$\1ox\25 \2o\36$\1o\11 \1o\1$\3 \2$\1 \1o\1$x\5 \1o\1 \1$\1 \2o\10 \1o\44$\1o\7 \2$\1 \2$\1 \2$\1o\1$x\2 \2o\1 \1$\1 \1$\1 \1\"\1$\6 \1o\11$\4 \15$\4 \11$\1o\7 \3$\1o\2$\1o\1$x\2 \1\"\6$\1o\1$\5 \1o\11$\6 \13$\6 \12$\1o\4 \10$x\4 \7$\4 \13$\6 \13$\6 \27$x\4 \27$\4 \15$\4 \16$\2 \3\"\3$x\5 \1\"\3$\4\"\61$\5 \1\"\3$x\6 \3$\3 \1o\62$\5 \1\"\3$\1ox\5 \1o\2$\1\"\3 \63$\7 \3$\1ox\5 \3$\4 \55$\1\"\1 \1\"\6$\5o\4$\1ox\4 \1o\3$\4o\5$\2 \45$\3 \1o\21$x\4 \10$\1\"\4$\3 \42$\5 \4$\10\"x\3 \4\"\7 \4$\4 \1\"\34$\1\"\6 \1o\3$x\16 \1\"\3$\1o\5 \3\"\22$\1\"\2$\1\"\11 \3$x\20 \3$\1o\12 \1\"\2$\2\"\6$\4\"\13 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x\47 \12$\1\"x\50 \1\"\3$\4\"x" | |
7811 }; | |
7809 char *p; | 7812 char *p; |
7810 int n; | 7813 int n; |
7814 int i; | |
7811 | 7815 |
7812 msg_start(); | 7816 msg_start(); |
7813 msg_putchar('\n'); | 7817 msg_putchar('\n'); |
7814 for (p = code; *p != NUL; ++p) | 7818 for (i = 0; i < 2; ++i) |
7815 if (*p == 'x') | 7819 for (p = code[i]; *p != NUL; ++p) |
7816 msg_putchar('\n'); | 7820 if (*p == 'x') |
7817 else | 7821 msg_putchar('\n'); |
7818 for (n = *p++; n > 0; --n) | 7822 else |
7819 if (*p == 'o' || *p == '$') | 7823 for (n = *p++; n > 0; --n) |
7820 msg_putchar_attr(*p, hl_attr(HLF_L)); | 7824 if (*p == 'o' || *p == '$') |
7821 else | 7825 msg_putchar_attr(*p, hl_attr(HLF_L)); |
7822 msg_putchar(*p); | 7826 else |
7827 msg_putchar(*p); | |
7823 msg_clr_eos(); | 7828 msg_clr_eos(); |
7824 } | 7829 } |
7825 | 7830 |
7826 #if defined(FEAT_GUI) || defined(FEAT_CLIENTSERVER) || defined(PROTO) | 7831 #if defined(FEAT_GUI) || defined(FEAT_CLIENTSERVER) || defined(PROTO) |
7827 /* | 7832 /* |