 //
 //  ---------------------------------------------------------------------------
 //
-//  © 2018 1024jp
+//  © 2018-2019 1024jp
 //
 //  Licensed under the Apache License, Version 2.0 (the "License");
 //  you may not use this file except in compliance with the License.

//  limitations under the License.
//

import Foundation

/// regex pattern to avoid matching escaped character
private let escapeIgnorer = "(?<!\\\\)(?:\\\\\\\\)*"


enum RegularExpressionParseMode {
    




private extension StringProtocol {
    
    /// ranges of inside of the most outer pairs of brace
    func ranges(bracePair: BracePair) -> [Range<Index>] {
        
        var index = self.startIndex
