Connecting Tech Pros Worldwide Forums | Help | Site Map

[FAQ] What does @ (at-sign) do?

John Dunlop
Guest
 
Posts: n/a
#1: Jul 17 '05
[ This is just a start. I hope somebody will follow up with
more suggestions. Particularly: Is 'at-sign' the best
name? How about the Unicode name 'COMMERCIAL AT'? Does
'error messages' include notices and warnings? What should
the example be? ]

Q: What does @ (at-sign) do?

A: @ is an operator, which, when prepended to an expression,
suppresses error messages.

Example:

[example here]

http://www.php.net/manual/en/languag...rorcontrol.php

--
Jock

Alan Little
Guest
 
Posts: n/a
#2: Jul 17 '05

re: [FAQ] What does @ (at-sign) do?


Carved in mystic runes upon the very living rock, the last words of John
Dunlop of comp.lang.php make plain:
[color=blue]
> [ This is just a start. I hope somebody will follow up with
> more suggestions. Particularly: Is 'at-sign' the best
> name? How about the Unicode name 'COMMERCIAL AT'? Does
> 'error messages' include notices and warnings? What should
> the example be? ]
>
> Q: What does @ (at-sign) do?
>
> A: @ is an operator, which, when prepended to an expression,
> suppresses error messages.
>
> Example:
>
> [example here]
>
> http://www.php.net/manual/en/languag...rorcontrol.php[/color]

Example:

$x = 'a';
extract($x);
@extract($x);

I like this idea. There are a number of things like this that a person
might come across in someone else's code, for example, that are difficult
to look up in the docs without knowing what they are.

--
Alan Little
Phorm PHP Form Processor
http://www.phorm.com/
NSpam
Guest
 
Posts: n/a
#3: Jul 17 '05

re: [FAQ] What does @ (at-sign) do?


John Dunlop wrote:[color=blue]
> [ This is just a start. I hope somebody will follow up with
> more suggestions. Particularly: Is 'at-sign' the best
> name? How about the Unicode name 'COMMERCIAL AT'? Does
> 'error messages' include notices and warnings? What should
> the example be? ]
>
> Q: What does @ (at-sign) do?
>
> A: @ is an operator, which, when prepended to an expression,
> suppresses error messages.
>
> Example:
>
> [example here]
>
> http://www.php.net/manual/en/languag...rorcontrol.php
>[/color]

turns off error messages - don't use it for development environments, do
use it for production environments
John Dunlop
Guest
 
Posts: n/a
#4: Jul 17 '05

re: [FAQ] What does @ (at-sign) do?


NSpam wrote:
[color=blue]
> turns off error messages - don't use it for development environments, do
> use it for production environments[/color]

Good point.

--
Jock
John Dunlop
Guest
 
Posts: n/a
#5: Jul 17 '05

re: [FAQ] What does @ (at-sign) do?


Alan Little wrote:
[color=blue]
> Example:
>
> $x = 'a';
> extract($x);
> @extract($x);[/color]

Great!
[color=blue]
> I like this idea. There are a number of things like this that a person
> might come across in someone else's code, for example, that are difficult
> to look up in the docs without knowing what they are.[/color]

Yes, that's why I think what we call @ is important. If you
were searching for @ on Google, what would you call it?

Here's some results:

"at-sign"
316 000 hits

commercial at"
97 500 hits

"commercial at sign"
1 730 hits

'Commercial at sign', though not as common, covers those
three possibilities, but it does sound a bit stilted,
doesn't it? The AUE FAQ says it's the longest name for @.

http://www.alt-usage-english.org/excerpts/fxnameso.html

The Jargon File 4.4.7 says:

| @
| Common: at sign; at; strudel. Rare: each; vortex; whorl;
| [whirlpool]; cyclone; snail; ape; cat; rose; cabbage;
| <commercial at>.

http://catb.org/~esr/jargon/html/A/ASCII.html

And if you're really interested, /A Natural History of the @
Sign/:

http://www.herodios.com/herron_tc/atsign.html

--
Jock
Chung Leong
Guest
 
Posts: n/a
#6: Jul 17 '05

re: [FAQ] What does @ (at-sign) do?


"NSpam" <chris.newey@gmail.com> wrote in message
news:kmjWd.196201$68.98441@fe1.news.blueyonder.co. uk...[color=blue]
> John Dunlop wrote:[color=green]
> > [ This is just a start. I hope somebody will follow up with
> > more suggestions. Particularly: Is 'at-sign' the best
> > name? How about the Unicode name 'COMMERCIAL AT'? Does
> > 'error messages' include notices and warnings? What should
> > the example be? ]
> >
> > Q: What does @ (at-sign) do?
> >
> > A: @ is an operator, which, when prepended to an expression,
> > suppresses error messages.
> >
> > Example:
> >
> > [example here]
> >
> > http://www.php.net/manual/en/languag...rorcontrol.php
> >[/color]
>
> turns off error messages - don't use it for development environments, do
> use it for production environments[/color]

Actually, the @ sign is mostly useful only during development, when the
level of error reporting is high. In a typical production environment either
error messages are turned off over all.


Closed Thread