LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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, 01:31 PM   #1
LXer
LXer NewsBot
 
Registered: Dec 2005
Posts: 96,885

Rep: Reputation: 96
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, 01:53 PM   #2
Myk267
Member
 
Registered: Apr 2012
Location: California
Posts: 330
Blog Entries: 14

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, 02:11 PM   #3
dugan
LQ Guru
 
Registered: Nov 2003
Location: Canada
Distribution: Slackware
Posts: 7,881

Rep: Reputation: 3077Reputation: 3077Reputation: 3077Reputation: 3077Reputation: 3077Reputation: 3077Reputation: 3077Reputation: 3077Reputation: 3077Reputation: 3077Reputation: 3077
Obligatory:

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

Rep: Reputation: 1612Reputation: 1612Reputation: 1612Reputation: 1612Reputation: 1612Reputation: 1612Reputation: 1612Reputation: 1612Reputation: 1612Reputation: 1612Reputation: 1612
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 02: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 10:50 AM
LXer: Understanding Regular Expressions LXer Syndicated Linux News 0 05-16-2012 05:30 PM
LXer: String Matches in Regular Expressions LXer Syndicated Linux News 0 09-11-2011 02:50 AM
LXer: 13 Features of Regular Expressions LXer Syndicated Linux News 0 11-13-2010 11:40 PM
LXer: Know Your Regular Expressions LXer Syndicated Linux News 0 06-16-2007 01:46 PM

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

All times are GMT -5. The time now is 01:22 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