<commit_before>package orc.runtime.regions;

import orc.runtime.Token;

public class SemiRegion extends Region {

	Region parent;
	Token t;
	
	/* Create a new group region with the given parent and coupled group cell */
	public SemiRegion(Region parent, Token t) {
		this.parent = parent;
		this.t = t;
		this.parent.add(this);
	}
	
	protected void reallyClose(Token closer) {
		if (t != null) {
			t.getTracer().after(closer.getTracer().before());
			t.setPending();
			t.activate();
		}
		parent.remove(this, closer);
	}

	public Region getParent() {
		return parent;
	}

	public void cancel() {
		if (t != null) {
			t.die();
			t = null;
		}
	}
}
<commit_msg>Fix crash bug with new semicolon semantics.<commit_after>package orc.runtime.regions;

import orc.runtime.Token;

public class SemiRegion extends Region {

	Region parent;
	Token t;
	
	/* Create a new group region with the given parent and coupled group cell */
	public SemiRegion(Region parent, Token t) {
		this.parent = parent;
		this.t = t;
		this.parent.add(this);
	}
	
	protected void reallyClose(Token closer) {
		if (t != null) {
			t.getTracer().after(closer.getTracer().before());
			t.setPending();
			t.activate();
		}
		parent.remove(this, closer);
	}

	public Region getParent() {
		return parent;
	}

	public void cancel() {
		if (t != null) {
			// setPending so that the token can unsetPending when it
			// dies
			t.setPending();
			t.die();
			t = null;
		}
	}
}

{'fraction_non_alphanumeric': 0.13070539419087138, 'fraction_numerical': 0.0, 'mean_word_length': 3.2186588921282797, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2759062', 'n_tokens_mistral': 550, 'n_tokens_neox': 489, 'n_words': 141}