Commit cf6b5821 authored by Philip Makedonski's avatar Philip Makedonski
Browse files

+refined scope resolution for target gates in interactions



Change-Id: Ie5b89968c1f0079cfe0f3d1fb55d11a47f5dc887
Signed-off-by: Philip Makedonski's avatarmakedonski <makedonski@informatik.uni-goettingen.de>
parent 086dfc9c
......@@ -117,7 +117,10 @@ public class TDLan2ScopeProvider extends AbstractDeclarativeScopeProvider {
if (context instanceof Message) {
//TODO: quick hack until a better solution is found
ICompositeNode oppositeNode = NodeModelUtils.findActualNodeFor(((Message) context).getTarget().get(0));
String targetGateName = oppositeNode.getText().replaceAll("where\\s+it\\s+is.+", "").trim();
String targetGateName = oppositeNode.getText()
.replaceAll("(?s)where\\s+it\\s+is.+", "")
.replaceAll("(?s)with\\s*\\{.+", "")
.trim();
String[] split = targetGateName.split("\\.");
String gate = split[1];
String component = split[0];
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment