File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1311,7 +1311,7 @@ blob2str({blob} [, {options}]) *blob2str()*
13111311 encoding. The value is a | String | . See
13121312 | encoding-names | for the supported values
13131313 (plus the special value "none").
1314- *E1515*
1314+ *E1515* *E1516*
13151315 When current 'encoding' is "utf-8", an error is given and an
13161316 empty List is returned if an invalid byte sequence is
13171317 encountered in {blob} . To suppress this validation and get
Original file line number Diff line number Diff line change @@ -4589,6 +4589,7 @@ E1512 options.txt /*E1512*
45894589E1513 message.txt /*E1513*
45904590E1514 options.txt /*E1514*
45914591E1515 builtin.txt /*E1515*
4592+ E1516 builtin.txt /*E1516*
45924593E152 helphelp.txt /*E152*
45934594E153 helphelp.txt /*E153*
45944595E154 helphelp.txt /*E154*
Original file line number Diff line number Diff line change @@ -3660,5 +3660,7 @@ EXTERN char e_winfixbuf_cannot_go_to_buffer[]
36603660 INIT (= N_ ("E1513: Cannot switch buffer. 'winfixbuf' is enabled" ));
36613661EXTERN char e_invalid_return_type_from_findfunc []
36623662 INIT (= N_ ("E1514: 'findfunc' did not return a List type" ));
3663- EXTERN char e_str_encoding_failed []
3664- INIT (= N_ ("E1515: Unable to convert %s '%s' encoding" ));
3663+ EXTERN char e_str_encoding_from_failed []
3664+ INIT (= N_ ("E1515: Unable to convert from '%s' encoding" ));
3665+ EXTERN char e_str_encoding_to_failed []
3666+ INIT (= N_ ("E1516: Unable to convert to '%s' encoding" ));
Original file line number Diff line number Diff line change @@ -1339,7 +1339,7 @@ f_blob2str(typval_T *argvars, typval_T *rettv)
13391339 vim_free (str );
13401340 if (converted_str == NULL )
13411341 {
1342- semsg (_ (e_str_encoding_failed ), "from" , from_encoding );
1342+ semsg (_ (e_str_encoding_from_failed ) , from_encoding );
13431343 goto done ;
13441344 }
13451345 }
@@ -1348,7 +1348,7 @@ f_blob2str(typval_T *argvars, typval_T *rettv)
13481348 {
13491349 if (!utf_valid_string (converted_str , NULL ))
13501350 {
1351- semsg (_ (e_str_encoding_failed ), "from" , p_enc );
1351+ semsg (_ (e_str_encoding_from_failed ) , p_enc );
13521352 vim_free (converted_str );
13531353 goto done ;
13541354 }
@@ -1414,7 +1414,7 @@ f_str2blob(typval_T *argvars, typval_T *rettv)
14141414 str = convert_string (str , p_enc , to_encoding );
14151415 if (str == NULL )
14161416 {
1417- semsg (_ (e_str_encoding_failed ), "to" , to_encoding );
1417+ semsg (_ (e_str_encoding_to_failed ) , to_encoding );
14181418 goto done ;
14191419 }
14201420 }
Original file line number Diff line number Diff line change @@ -4422,10 +4422,10 @@ func Test_str2blob()
44224422
44234423 call assert_fails (" call str2blob(['abc'], [])" , ' E1206: Dictionary required for argument 2' )
44244424 call assert_fails (" call str2blob(['abc'], {'encoding': []})" , ' E730: Using a List as a String' )
4425- call assert_fails (" call str2blob(['abc'], {'encoding': 'ab12xy'})" , ' E1515 : Unable to convert to '' ab12xy'' encoding' )
4426- call assert_fails (" call str2blob(['ŝş'], {'encoding': 'latin1'})" , ' E1515 : Unable to convert to '' latin1'' encoding' )
4427- call assert_fails (" call str2blob(['அஇ'], {'encoding': 'latin1'})" , ' E1515 : Unable to convert to '' latin1'' encoding' )
4428- call assert_fails (" call str2blob(['🁰🁳'], {'encoding': 'latin1'})" , ' E1515 : Unable to convert to '' latin1'' encoding' )
4425+ call assert_fails (" call str2blob(['abc'], {'encoding': 'ab12xy'})" , ' E1516 : Unable to convert to '' ab12xy'' encoding' )
4426+ call assert_fails (" call str2blob(['ŝş'], {'encoding': 'latin1'})" , ' E1516 : Unable to convert to '' latin1'' encoding' )
4427+ call assert_fails (" call str2blob(['அஇ'], {'encoding': 'latin1'})" , ' E1516 : Unable to convert to '' latin1'' encoding' )
4428+ call assert_fails (" call str2blob(['🁰🁳'], {'encoding': 'latin1'})" , ' E1516 : Unable to convert to '' latin1'' encoding' )
44294429 END
44304430 call v9.CheckLegacyAndVim9Success (lines )
44314431endfunc
Original file line number Diff line number Diff line change @@ -704,6 +704,8 @@ static char *(features[]) =
704704
705705static int included_patches [] =
706706{ /* Add new patch number below this line */
707+ /**/
708+ 1223 ,
707709/**/
708710 1222 ,
709711/**/
You can’t perform that action at this time.
0 commit comments