Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c++.moderated > #7416

Manipulating std::match_results?

Path csiph.com!xmission!news.snarked.org!border2.nntp.dca1.giganews.com!Xl.tags.giganews.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!local2.nntp.dca.giganews.com!news.giganews.com.POSTED!not-for-mail
NNTP-Posting-Date Mon, 04 Apr 2016 17:50:01 -0500
Return-Path <cppmods@glengoyne.dreamhost.com>
Sender lang-cpp-request@vandevoorde.com
Approved c.l.c.m@bazarov.com
Message-ID <c55btc-e89.ln1@hergen.dyndns.org> (permalink)
Newsgroups comp.lang.c++.moderated
From Hergen Lehmann <hlehmann.expires.5-11@snafu.de>
Subject Manipulating std::match_results?
Organization albasani.net
Content-Type text/plain; charset=utf-8; format=flowed
X-Original-Date Tue, 5 Apr 2016 00:07:08 +0200
X-Submission-Address lang-cpp-submit@vandevoorde.com
Date Mon, 4 Apr 2016 17:44:31 CST
Lines 24
X-Usenet-Provider http://www.giganews.com
X-Trace sv3-nTIPv94uvAOtc94O4+bY+0F24MhThzSgx09nBEfT4zr6+NOCga1gVXWf84Bjm4ndRUbLWtHf8EC+ck/!5iC90kl063lr/xY8I9BScBc0wshkcjxwhHql4FYaApfT0OeuT/X8F2vqTx0=
X-Complaints-To abuse@giganews.com
X-DMCA-Notifications http://www.giganews.com/info/dmca.html
X-Abuse-and-DMCA-Info Please be sure to forward a copy of ALL headers
X-Abuse-and-DMCA-Info Otherwise we will be unable to process your complaint properly
X-Postfilter 1.3.40
X-Original-Bytes 1974
Xref csiph.com comp.lang.c++.moderated:7416

Show key headers only | View raw


Hello,

i am currently in the process of refactoring some old code into 
c++11/14. Part of that code is a regex-like pattern matching mechanism, 
which (due to compatibility reasons) should be kept in place for now.

However, in preparation of a future transition to std::regex, i would 
like to go ahead, and store the results in a std::match_results object.

Unfortunately, i can't find any setter methods or constructors in this 
class, except for the default and copy constructors. Is there any 
(preferably portable) way to set the contents (sub-matches, prefix, 
suffix) of a std::match_results object without going through 
std::basic_regex?

TIA,
Hergen


-- 
      [ See http://www.gotw.ca/resources/clcm.htm for info about ]
      [ comp.lang.c++.moderated.    First time posters: Do this! ]

Back to comp.lang.c++.moderated | Previous | NextNext in thread | Find similar


Thread

Manipulating std::match_results? Hergen Lehmann <hlehmann.expires.5-11@snafu.de> - 2016-04-04 17:44 -0600
  Re: Manipulating std::match_results? Martin Bonner <martinfrompi@yahoo.co.uk> - 2016-04-05 08:19 -0600
  Re: Manipulating std::match_results? guy.tristram@googlemail.com - 2016-04-05 08:19 -0600

csiph-web