473,395 Members | 1,791 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

strange syntax: $var'token

I have the O'Rielly Camel book and didn't find any reference to the
following syntax I saw in some code for a web store:

$cgi_lib'filepre = "cgi-lib";

Is this some sort of shorthand for

$cgi_lib['filepre'] = "cgi-lib";

I'm used to using perl 5.0 but don't know if this an addition in later
versions (5.[68]). Is it?

TIA...

--
DeeDee, don't press that button! DeeDee! NO! Dee...

Jul 19 '05 #1
1 2371
"Michael Vilain <vi****@spamcop.net>" wrote:
I have the O'Rielly Camel book and didn't find any reference to the
following syntax I saw in some code for a web store:

$cgi_lib'filepre = "cgi-lib";


That is perl4 syntax for setting the variable $filpre in package cgi_lib.
For perl version 5.x, use :: instead of ' after the package name.

$cgi_lib::filpre = 'cgi-lib';

I would not trust code like that as a web store or shopping cart.

If you have any other questions, post them to comp.lang.perl.misc
not here (comp.lang.perl).
-Joe
Jul 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Andrew James | last post by:
Gentlemen, I'm running into a problem whilst testing the parsing of a language I've created with TPG . It seems that for some reason, TPG balks when I try to parse an expression whose first...
9
by: g.kanaka.raju | last post by:
Hi, I wanted to write a function that gets the file path as an argument. The file path make take one of the two forms : (i) Absolute file path e.g., /usr/local/file.log or (ii)it may...
4
by: Bob hotmail.com> | last post by:
Everyone I have been spending weeks looking on the web for a good tutorial on how to use regular expressions and other methods to satisfy my craving for learning how to do FAST c-style syntax...
6
by: Nick Weekes | last post by:
Hi all, I am trying to cast a Double (its actually the NextDouble method of the Random class, but could be any type of number) to a Type via its name. Im trying the following syntax: ...
5
by: r.nikhilk | last post by:
Hi, Currently, we are porting C++ applications from 32 bit to 64 bit on AIX platform. (The current version of AIX is 5.3 and xlC verison is 8.0). We are able to compile the applications by...
0
by: Jay C. | last post by:
Jay 3 Jan. 11:38 Optionen anzeigen Newsgroups: microsoft.public.dotnet.framework.webservices.enhancements Von: "Jay" <p.brunm...@nusurf.at> - Nachrichten dieses Autors suchen Datum: 3 Jan...
3
by: Manuel | last post by:
I'm trying to compile glut 3.7.6 (dowbloaded from official site)using devc++. So I've imported the glut32.dsp into devc++, included manually some headers, and start to compile. It return a very...
1
by: Hollywood | last post by:
Hello dear membres of the comp.unix.programmer. Please , I've got the following question to submit and I need your help. Here below you'll find a lexical and a syntaxic analysers. The lexical...
4
by: nickyeng | last post by:
i calling this piece of java code in jsp : List<Customer> list = Customer.listby_page(currentRs); ... ... then it gives me the following error:
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.