Bash – Using “@” as a bash function name

bashfunction

Is it possible to use the "@" symbol as a function name in a bash script? The following does not work:

function @() {
  echo hello
}

Best Answer

From man bash

   name   A word consisting only of alphanumeric characters and underscores, 
          and beginning with an  alphabetic character or an underscore.  Also 
          referred to as an identifier.

Shell functions are declared as follows:
          name () compound-command [redirection]
          function name [()] compound-command [redirection]