File: questionmark.cc

package info (click to toggle)
flexc%2B%2B 2.17.01-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 7,180 kB
  • sloc: cpp: 6,467; makefile: 148; sh: 130; ansic: 18
file content (13 lines) | stat: -rw-r--r-- 351 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
#include "fpattern.ih"

FPattern FPattern::questionMark(States &states, FPattern const &fpattern)
{
    size_t idx = states.next();     // new start state

        // connect the new Start state with the fpattern and FINAL 
    states[idx] = State(EMPTY, fpattern.begin(), fpattern.end());

    FPattern ret({idx, fpattern.end()});

    return ret;
}