comparison runtime/doc/if_perl.txt @ 32449:2a17771529af

Update runtime files Commit: https://github.com/vim/vim/commit/b7398fe41c9e1e731d058105a34158871ee83e3f Author: Bram Moolenaar <Bram@vim.org> Date: Sun May 14 18:50:25 2023 +0100 Update runtime files
author Bram Moolenaar <Bram@vim.org>
date Sun, 14 May 2023 20:00:05 +0200
parents f8116058ca76
children 448aef880252
comparison
equal deleted inserted replaced
32448:62943590c35e 32449:2a17771529af
1 *if_perl.txt* For Vim version 9.0. Last change: 2022 Mar 13 1 *if_perl.txt* For Vim version 9.0. Last change: 2023 May 14
2 2
3 3
4 VIM REFERENCE MANUAL by Sven Verdoolaege 4 VIM REFERENCE MANUAL by Sven Verdoolaege
5 and Matt Gerassimof 5 and Matt Gerassimof
6 6
252 The current buffer object. 252 The current buffer object.
253 253
254 254
255 *script-here* 255 *script-here*
256 When using a script language in-line, you might want to skip this when the 256 When using a script language in-line, you might want to skip this when the
257 language isn't supported. But this mechanism doesn't work: > 257 language isn't supported. >
258 if has('perl') 258 if has('perl')
259 perl << EOF 259 perl << EOF
260 this will NOT work! 260 print 'perl works'
261 EOF 261 EOF
262 endif 262 endif
263 Instead, put the Perl/Python/Ruby/etc. command in a function and call that 263 Note that "EOF" must be at the start of the line without preceding white
264 function: > 264 space.
265 if has('perl')
266 function DefPerl()
267 perl << EOF
268 this works
269 EOF
270 endfunction
271 call DefPerl()
272 endif
273 Note that "EOF" must be at the start of the line.
274 265
275 ============================================================================== 266 ==============================================================================
276 4. Dynamic loading *perl-dynamic* 267 4. Dynamic loading *perl-dynamic*
277 268
278 On MS-Windows and Unix the Perl library can be loaded dynamically. The 269 On MS-Windows and Unix the Perl library can be loaded dynamically. The