w10schools
Login Register
  • Home
  • Tutorials
    • HTML, CSS
      • HTML, HTML5
      • CSS, CSS3
    • XML
    • JavaScript, AJAX
    • PHP
    • Ruby on Rails
      • Ruby
      • Rails
    • ASP.NET
      • ASP
      • C# .NET
    • Java
      • JSP
    • Databases
      • MySQL
      • MSSQL Server
      • Oracle
    • Web Server
      • Windows
      • Linux
      • Apache
      • IIS
    • Design
      • Dreamweaver
      • Flash
      • Photoshop
      • Fireworks
      • CorelDRAW
      • Illustrator
  • References
    • HTML
      • Bootstrap
    • CSS
      • CSS Selectors
      • Sass
    • JavaScript
    • Mobile Apps
      • Cordova
    • Ruby on Rails
      • Ruby
      • Rails
    • PHP
      • Function
      • Language
      • CodeIgniter
      • Phalcon
      • PHPUnit
      • Symfony
      • Drupal
      • Yii
      • Laravel
    • Perl
      • Perl
    • Python
      • Python
      • Django
      • NumPy
      • Pandas
      • scikit-image
      • scikit-learn
      • Statsmodels
      • Matplotlib
    • Lua
      • Lua
    • C, C++
      • C
      • C++
    • Server
      • Docker
      • Apache HTTP Server
      • Nginx
    • Database
      • PostgreSQL
    • Big Data
      • TensorFlow
    • Game Development
      • Phaser
      • LÖVE
  • Articles
    • News
    • General
      • Website Promotion
      • Online Advertising
      • Make Money Online
    • Editorials
    • Interviews
    • Web Roundups
  • Resources
    • Design
      • Fonts
      • Graphics
      • Vectors
      • Templates
      • UI (User Interface)
      • Brushes
      • Patterns, Backgrounds
      • Textures
    • Web Development
      • HTML, CSS
      • XML
      • JavaScript, AJAX
      • Ruby on Rails
      • PHP
      • Java
      • .NET
      • Python
      • Perl
      • Flash
    • Mobile Application Development
      • Mobile Development Tools
      • Swift
    • Online Services
      • Online Storage
      • Web Hosting
  • Tools
    • Generators
Edit
In Place Editing Advanced Editing
  • References
  • Perl
  • Perl
  • Functions

__SUB__

__SUB__

A special token that returns a reference to the current subroutine, or undef outside of a subroutine.

The behaviour of __SUB__ within a regex code block (such as /(?{...})/ ) is subject to change.

This token is only available under use v5.16 or the "current_sub" feature. See feature.

Links:
  • http://perldoc.perl.org/5.24.0/functions/__SUB__.html
doc_perl
doc_perl
2025-01-10 15:47:30
Comments
Leave a Comment

Please login to continue.

Popular Articles
sub sub(pattern, replacement) â $_sub(pattern) { block } â $_ Instance Public methods Equivalent to $_.sub(args), except that $_ wil
sub sub NAME BLOCK sub NAME (PROTO) BLOCK sub NAME : ATTRS BLOCK sub NAME (PROTO) : ATTRS BLOCK This is subroutine definition, not a real function per se
sub sub(*args) Instance Public methods Return a pathname which is substituted by String#sub. path1 = Pathname.new('/usr/bin/perl') path1.sub
sub str.sub(pattern, replacement) â new_strstr.sub(pattern, hash) â new_strstr.sub(pattern) {|match| block } â new_str
sub sub(p1, p2) Instance Public methods


Return to View
  • Facebook
  • Tweet
  • Digg it
  • Stumbleupon
  • Delicious
  • Plus Share

Designed by : w10schools

service@w10schools.com

Our Partners: aeeble – Providing content publishing and search solutions