Commit 8f871bc7 authored by vonWenckstern's avatar vonWenckstern
Browse files

fixed bug

parent 4ebad7ab
Pipeline #69014 passed with stage
in 2 minutes and 37 seconds
......@@ -82,8 +82,9 @@ grammar EmbeddedMontiArc extends de.monticore.lang.monticar.Common2 {
*/
symbol scope Component implements Element =
"component" ["interface"]? Name
genericTypeParameters:TypeParameters2?
"component" (["interface"])? Name
//("component" | ["component_interface"]) Name
genericTypeParameters:TypeParameters2?
( "(" (Parameter || ",")+ ")" )?
("implements" superComponent:ReferenceType)?
body:ComponentBody;
......
......@@ -40,8 +40,8 @@ public class ASTComponent extends ASTComponentTOP {
super();
}
public ASTComponent(String name, Optional<ASTTypeParameters2> genericTypeParameters, List<ASTParameter> parameters, Optional<ASTReferenceType> superComponent, ASTComponentBody body) {
super(name, genericTypeParameters, parameters, superComponent, body);
public ASTComponent(String name, Optional<ASTTypeParameters2> genericTypeParameters, List<ASTParameter> parameters, Optional<ASTReferenceType> superComponent, ASTComponentBody body, boolean r__interface) {
super(name, genericTypeParameters, parameters, superComponent, body, r__interface);
}
// do not use symbol table, since symbol table must not be created
......
......@@ -5,6 +5,6 @@ component interface CarInterface { // interface defines the contract with develo
in Q(0 km/h : 0.1 km/h: 250 km/h) carSpeed,
in Q(0 cm : 0.1 cm : 100 cm) distanceFront[20],
out Q(0 lx : 2 lx : 60 lx) leftFrontLights[40],
Q(-10 m/s^2 : 0.01 m/s^2: 15 m/s^2) acceleration,
Q(-90°: 0.2°:90°) steering;
out Q(-10 m/s^2 : 0.01 m/s^2: 15 m/s^2) acceleration,
out Q(-90°: 0.2°:90°) steering;
}
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