Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Processing variable name with [ ] in perl

Status
Not open for further replies.

neoflash

Advanced Member level 1
Joined
Jul 2, 2005
Messages
492
Helped
10
Reputation
20
Reaction score
2
Trophy points
1,298
Activity points
4,759
I have trouble with processing variable names with [] by itself since [ ] have special meaning in perl programming.

However, those variable names are read in from other sources and therefore can't be changed.

How can we effectively deal with them without too much trouble?

Added after 2 hours 57 minutes:

Let me specify it a bit more:

if ($p_line =~ / $line[1] /)

where $p_line has a variable as abc[1]. My problem is that it never match with $line[1] which is also abc[1].
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top