LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - News > Syndicated Linux News
User Name
Password
Syndicated Linux News This forum is for the discussion of Syndicated Linux News stories.

Notices


Reply
  Search this Thread
Old 05-06-2014, 12:31 PM   #1
LXer
LXer NewsBot
 
Registered: Dec 2005
Posts: 99,755

Rep: Reputation: 102Reputation: 102
LXer: Why I (sometimes) love regular expressions


Published at LXer:

Command line wizards are forever encouraging the rest of us to learn regular expressions (regex). We're told regex is elegant, powerful and incredibly useful.The downside is that regex can be seriously fiddly. One fly-spot out of place, and the code fails. For this reason I only use 'non-simple' regex when I absolutely have to. But when I do, sigh... Regex really is elegant and powerful, as the following example shows.

Read More...
 
Old 05-06-2014, 12:53 PM   #2
Myk267
Member
 
Registered: Apr 2012
Location: California
Posts: 381
Blog Entries: 15

Rep: Reputation: Disabled
Wait.

So the guy loves regular expressions because you can attempt to parse XML with them, even though everyone tells you not to do that?
 
Old 05-06-2014, 01:11 PM   #3
dugan
LQ Guru
 
Registered: Nov 2003
Location: Canada
Distribution: Slackware
Posts: 8,283

Rep: Reputation: 3363Reputation: 3363Reputation: 3363Reputation: 3363Reputation: 3363Reputation: 3363Reputation: 3363Reputation: 3363Reputation: 3363Reputation: 3363Reputation: 3363
Obligatory:

http://blog.codinghorror.com/parsing...e-cthulhu-way/
 
Old 05-06-2014, 01:23 PM   #4
szboardstretcher
Senior Member
 
Registered: Aug 2006
Location: Detroit, MI
Distribution: GNU/Linux systemd
Posts: 4,213

Rep: Reputation: 1613Reputation: 1613Reputation: 1613Reputation: 1613Reputation: 1613Reputation: 1613Reputation: 1613Reputation: 1613Reputation: 1613Reputation: 1613Reputation: 1613
Seems like there might be a far easier way to do that.

Edit: Yep, cthulu seems like it.

Last edited by szboardstretcher; 05-06-2014 at 01:26 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Regular expressions guide LXer Syndicated Linux News 0 04-14-2014 09:50 AM
LXer: Understanding Regular Expressions LXer Syndicated Linux News 0 05-16-2012 04:30 PM
LXer: String Matches in Regular Expressions LXer Syndicated Linux News 0 09-11-2011 01:50 AM
LXer: 13 Features of Regular Expressions LXer Syndicated Linux News 0 11-13-2010 10:40 PM
LXer: Know Your Regular Expressions LXer Syndicated Linux News 0 06-16-2007 12:46 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - News > Syndicated Linux News

All times are GMT -5. The time now is 02:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration