From: nobu.nokada@... Date: 2002-04-11T02:31:29+09:00 Subject: Re: regex: how to negate sequences? Hi, At Thu, 11 Apr 2002 01:31:39 +0900, Tobias Reif wrote: > In > '-f-o>o-bar-->' > , I need to match the string before > --> > , which is > -f-o>o-bar > . How to? irb(main):002:0> '-f-o>o-bar-->' =~ /.*?(?=-->|\z)/; puts $& -f-o>o-bar nil Although it's not negating. -- Nobu Nakada