Mercurial > pub > ImplabNet
comparison Implab/Automaton/RegularExpressions/RegularDFA.cs @ 180:c32688129f14 ref20160224
refactoring complete, JSONParser rewritten
author | cin |
---|---|
date | Thu, 24 Mar 2016 02:30:46 +0300 |
parents | 478ef706906a |
children | b2b6a6640aa3 |
comparison
equal
deleted
inserted
replaced
179:478ef706906a | 180:c32688129f14 |
---|---|
51 public RegularDFA<TInput,TTag> Optimize(IAlphabetBuilder<TInput> alphabet) { | 51 public RegularDFA<TInput,TTag> Optimize(IAlphabetBuilder<TInput> alphabet) { |
52 Safe.ArgumentNotNull(alphabet, "alphabet"); | 52 Safe.ArgumentNotNull(alphabet, "alphabet"); |
53 | 53 |
54 var dfa = new RegularDFA<TInput, TTag>(alphabet); | 54 var dfa = new RegularDFA<TInput, TTag>(alphabet); |
55 | 55 |
56 var states = new DummyAlphabet(StateCount); | |
57 var alphaMap = new Dictionary<int,int>(); | 56 var alphaMap = new Dictionary<int,int>(); |
58 var stateMap = new Dictionary<int,int>(); | 57 var stateMap = new Dictionary<int,int>(); |
59 | 58 |
60 Optimize(dfa, alphaMap, stateMap); | 59 Optimize(dfa, alphaMap, stateMap); |
61 | 60 |