Tinderbox v10 Icon

%matches (query back-references)


Operator Type: 

Operator Scope of Action: 

Operator Purpose: 

Data Type Returned: 

Operator First Added: 

Operator in Current Baseline: 

Operator Last Altered: 

 Property  [other Property type actions]

 Query  [operators of similar scope]

 Data manipulation  [other Data manipulation operators]

 List [about List data type]

 v9.6.0

 Baseline

 As at baseline


Syntax note: Operators without any defined mandatory arguments may omit their empty closing parentheses


%matches

The expression %matches represents a list that contains all available back-references to regular expression matches. This is equivalent to the list of back reference values [$0;$1;$2….$N], where N is the count of available regular expression matches.

If $MyString is "I do not like green eggs and ham.", then for this code:

	if($MyString.contains("like (((green) (eggs)) and ham)")){
		$MyList = %matches;
	};

$MyList now holds 5 back-references:

Query back-references are discussed in fuller detail here.


See also—notes linking to here: