Giter Club home page Giter Club logo

abstools's Introduction

ABS Tools

compile GitHub release Gitter

Inside this repository we develop the core tools of the ABS modelling language. The current language manual is at https://abs-models.org/manual/.

To compile the command-line compiler and manual, run ./gradlew assemble (See https://abs-models.org/getting_started/local-install/ for more information).

To run the ABS collaboratory (a browser-based IDE for ABS) locally using Docker, execute the following command:

docker run -p 8080:80 --rm abslang/collaboratory:latest

Then connect your browser to http://localhost:8080/. It is not necessary to clone the repository or compile the toolchain to run the ABS collaboratory in this way.

To run the absc compiler locally using docker, create a script such as https://github.com/abstools/abstools/blob/master/frontend/src/main/resources/bash/absc-docker and put it in your path.

Folders

  • frontend - the ABS compiler and runtime support. See https://abs-models.org/getting_started/local-install/ for installation instructions.

  • abs-docs - the ABS language manual, available online at http://abs-models.org/manual/. To generate the manual locally, run make manual.

    • abs-docs/ReferenceManual - an older LaTeX ABS reference manual, now mostly of historical interest

    • abs-docs/Ott - a formal grammar for a large subset of ABS, written in Ott

  • org.abs-models.releng - Files used by Jenkins and Buckminster for continuous integration at https://envisage.ifi.uio.no:8080/jenkins/.

  • abs-unit - demonstration, description and initial ideas about the ABSUnit (a unit testing framework for ABS) (with Maven dependencies management)

  • various leftovers from previous projects, to be evaluated and reactivated or pruned

Note for Windows Users

Please clone the archive without line ending conversion (unfortunately activated by default on Windows). Use -c core.autocrlf=false as argument for the initial git clone command, i.e.,

git clone https://github.com/abstools/abstools -c core.autocrlf=false

Otherwise, running the tools inside Docker will fail with obscure error messages.

Working with the repository

Consider rebasing instead of merging your changes:

git pull --rebase

This avoids spurious "merge branch to master" commits.

git pull --rebase will, in case both you and the remote repository have new commits, replay your local commits on top of upstream changes instead of adding a new local commit that merges the master and origin/master branches. Conflicts have to be resolved per patch (via git add + git rebase --continue) instead of in one go, but we get a cleaner history.

abstools's People

Contributors

abe522 avatar abelunibo avatar ahbnr avatar andotri avatar aqissiaq avatar bezirg avatar bjoernpetersen avatar dependabot[bot] avatar derdrodt avatar ebjohnsen avatar edkamb avatar faizashehzad avatar genaim avatar gzoumix avatar jacopomauro avatar jgrnt avatar larstvei avatar martjac avatar miguelis avatar mzamalloa avatar nobeh avatar oab avatar ostahluio avatar peteryhwong avatar rm2340 avatar rudi avatar vlad-serbanescu avatar volkerstolz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

abstools's Issues

Intermittent build issues (via External Tool Builder) in Eclipse


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 99, https://envisage.ifi.uio.no:8080/redmine/issues/99
Original Date: 2013-12-02
Original Assignee: Volker Stolz


Hitting "Build all" or launching unit-tests sometimes yields this like:

Errors occurred during the build.
Errors running builder 'Integrated External Tool Builder' on project 'org.abs-models.abs.compiler'.
Variable references empty selection: ${project_loc}
Variable references empty selection: ${project_loc}

Retrying will eventually resolve this. Ick.

Bug in Java Backend when type casting


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 133, https://envisage.ifi.uio.no:8080/redmine/issues/133
Original Date: 2014-02-27
Original Assignee: Radu Muschevici


The compilation error is:

An error occurred during compilation: There seems to be a bug in the ABS Java backend. The generated code contains errors:
----------
1. ERROR in /home/bezirg/workspace/Test/gen/Testing/Main.java (at line 45)
    abs.backend.java.lib.types.ABSUnit z = (abs.backend.java.lib.types.ABSUnit)abs.backend.java.lib.types.ABSBool.TRUE.toBoolean() ? y : y.get();
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Cannot cast from boolean to ABSUnit
----------
2. ERROR in /home/bezirg/workspace/Test/gen/Testing/Main.java (at line 45)
    abs.backend.java.lib.types.ABSUnit z = (abs.backend.java.lib.types.ABSUnit)abs.backend.java.lib.types.ABSBool.TRUE.toBoolean() ? y : y.get();
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Type mismatch: cannot convert from ABSUnit to boolean

The code where the error occurs:

module Testing;

interface Interf1 {
  Unit m1();
}

class Cls1 implements Interf1 {
  Unit m1() {

  }
}

{
  Interf1 o1 = new local Cls1();
  Unit x = (if True then o1 else o1).m1();
  Fut<Unit> y = o1 ! m1 ();
  await y?;
  Unit z = (if True then y else y).get;
}

Eclipse autocompletion needs improvement


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 131, https://envisage.ifi.uio.no:8080/redmine/issues/131
Original Date: 2014-02-14


Due to the way the parser handles incomplete input, you will not get useful autocompletion at (*) for the fragment

Bool b() { Int i = 0; return True; this. (*) }

However, for this.(*);, autocompletion will correctly find members. I think there is some basic functionality in the plugin that tries to "inject" the terminator, but for some reason it doesn't seem to "stick".

Align Expression statement documentation and implementation


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 130, https://envisage.ifi.uio.no:8080/redmine/issues/130
Original Date: 2014-02-12


The language spec and the AST state:

  ExpStmt ::= Exp ;

Yet ABS.parser only allows effect expressions:

Stmt stmt_without_annotations =
 …
|  eff_exp.e    {: return new ExpressionStmt(new List(), e) ; :}

The reason for this seems to be a Reduce-Reduce conflict if turning it into an exp:

      [beaver] Error: grammar has conflicts
      [beaver] ABSParser.beaver: Error: reduce-reduce conflict: 
      [beaver]  reduce  case_exp = case_prefix.caseterm RBRACE.RBRACE ``` 1583
      [beaver]  or  case_stmt = case_prefix.caseterm RBRACE.RBRACE ``` 2031
      [beaver]  on MINUS - equal precedence

Runtime error in Eclipse


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 85, https://envisage.ifi.uio.no:8080/redmine/issues/85
Original Date: 2013-11-13
Original Assignee: Volker Stolz


For some variable declarations there's a runtime exception in Eclipse that is usually hidden, resulting in an UnresolvedTypeUse:

java.lang.RuntimeException: Trying to evaluate attribute in subtree not attached to main tree
    at abs.frontend.ast.CompilationUnit.lookupModule(CompilationUnit.java:1298)
    at abs.frontend.ast.CompilationUnit.Define_ModuleDecl_lookupModule(CompilationUnit.java:1354)
    at abs.frontend.ast.ASTNode.Define_ModuleDecl_lookupModule(ASTNode.java:1662)
    at abs.frontend.ast.ModuleDecl.lookupModule(ModuleDecl.java:1515)
    at abs.frontend.typechecker.TypeCheckerHelper.getImportedNames(TypeCheckerHelper.java:279)
    at abs.frontend.ast.ModuleDecl.getImportedNames_compute(ModuleDecl.java:1280)
    at abs.frontend.ast.ModuleDecl.getImportedNames(ModuleDecl.java:1267)
    at abs.frontend.typechecker.TypeCheckerHelper.getVisibleNames(TypeCheckerHelper.java:310)
    at abs.frontend.ast.ModuleDecl.getVisibleNames_compute(ModuleDecl.java:1088)
    at abs.frontend.ast.ModuleDecl.getVisibleNames(ModuleDecl.java:1075)
    at abs.frontend.ast.ModuleDecl.resolveName(ModuleDecl.java:385)
    at abs.frontend.ast.ModuleDecl.lookup_compute(ModuleDecl.java:1494)
    at abs.frontend.ast.ModuleDecl.lookup(ModuleDecl.java:1481)
    at abs.frontend.ast.ModuleDecl.Define_Decl_lookup(ModuleDecl.java:1604)
    at abs.frontend.ast.ASTNode.Define_Decl_lookup(ASTNode.java:1669)
    at abs.frontend.ast.ASTNode.Define_Decl_lookup(ASTNode.java:1669)
    at abs.frontend.ast.ASTNode.Define_Decl_lookup(ASTNode.java:1669)
    at abs.frontend.ast.ASTNode.Define_Decl_lookup(ASTNode.java:1669)
    at abs.frontend.ast.ASTNode.Define_Decl_lookup(ASTNode.java:1669)
    at abs.frontend.ast.ASTNode.Define_Decl_lookup(ASTNode.java:1669)
    at abs.frontend.ast.ASTNode.Define_Decl_lookup(ASTNode.java:1669)
    at abs.frontend.ast.TypedVarOrFieldDecl.lookup(TypedVarOrFieldDecl.java:327)
    at abs.frontend.ast.TypedVarOrFieldDecl.Define_Decl_lookup(TypedVarOrFieldDecl.java:342)
    at abs.frontend.ast.Exp.lookup(Exp.java:438)
    at abs.frontend.ast.TypeUse.getDecl_compute(TypeUse.java:393)
    at abs.frontend.ast.TypeUse.getDecl(TypeUse.java:381)
    at abs.frontend.ast.UnresolvedTypeUse.rewriteTo(UnresolvedTypeUse.java:365)
    at abs.frontend.ast.ASTNode.getChild(ASTNode.java:606)
    at abs.frontend.ast.ASTNode.collect_contributors_Stmt_getAACs(ASTNode.java:1098)
    at abs.frontend.ast.ASTNode.collect_contributors_Stmt_getAACs(ASTNode.java:1098)
    at abs.frontend.ast.Stmt.collect_contributors_Stmt_getAACs(Stmt.java:351)
    at abs.frontend.ast.Stmt.getAACs_compute(Stmt.java:618)
    at abs.frontend.ast.Stmt.getAACs(Stmt.java:587)
    at abs.frontend.ast.Stmt.rewriteTo(Stmt.java:529)
    at abs.frontend.ast.VarDeclStmt.rewriteTo(VarDeclStmt.java:578)
    at abs.frontend.ast.ASTNode.getChild(ASTNode.java:606)
    at abs.frontend.ast.List.rewriteTo(List.java:287)
    at abs.frontend.ast.ASTNode.getChild(ASTNode.java:606)
    at abs.frontend.ast.Block.getStmtList(Block.java:600)
    at abs.frontend.ast.Block.getNumStmt(Block.java:540)
    at abs.frontend.ast.Block.hasRewriteBlockAt(Block.java:86)
    at abs.frontend.ast.Block.rewriteTo(Block.java:812)
    at abs.frontend.ast.ASTNode.getChild(ASTNode.java:606)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:40)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:40)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:40)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:40)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:40)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:40)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:40)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:34)
    at org.absmodels.abs.plugin.util.UtilityFunctions.getASTNodeOfOffset(UtilityFunctions.java:373)
    at org.absmodels.abs.plugin.editor.ABSCodeScanner.evalAST(ABSCodeScanner.java:306)
    at org.absmodels.abs.plugin.editor.ABSCodeScanner.internalNextToken(ABSCodeScanner.java:259)
    at org.absmodels.abs.plugin.editor.ABSCodeScanner.nextToken(ABSCodeScanner.java:230)
    at org.eclipse.jface.text.rules.DefaultDamagerRepairer.createPresentation(DefaultDamagerRepairer.java:175)

Parser fail with init block


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 100, https://envisage.ifi.uio.no:8080/redmine/issues/100
Original Date: 2013-12-09


The parser cannot accept a class init block declaration that comes after a method:

class Class1 implements Interf2 {
Int method1(Int n) {
return 0;
}
{

}

}

fails to parse with:

Syntactic errors: 2
Test.abs:18:3:Syntactic error: unexpected token LBRACE
{
--^
Test.abs:24:1:Syntactic error: unexpected token RBRACE
}
^

The parser only accepts init blocks to be the declared first.

Integrate jabsc into eclipse-plugin

jabsc is the currently being developed ABS to Java compiler using jabs which is implementation of ABS semantics as an API in Java 8. Integrate this compiler into the current eclipse-plugin.

[eclipse-plugin] PDE fails to load ABS perspective because of `org.abs-models.sdedit`

I am quite sure that I am missing something, but debugging the eclipse-plugin fails to load ABS perspective:

Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
!SESSION 2015-07-30 21:01:40.087 -----------------------------------------------
eclipse.buildId=4.5.0.I20150603-2000
java.version=1.8.0_60-ea
java.vendor=Oracle Corporation
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_US
Framework arguments:  -product org.eclipse.platform.ide
Command-line arguments:  -product org.eclipse.platform.ide -data /nobeh/dev/workspaces/crisp/ws-abstools/../runtime-EclipseApplication -dev file:/nobeh/dev/workspaces/crisp/ws-abstools/.metadata/.plugins/org.eclipse.pde.core/Eclipse Application/dev.properties -os linux -ws gtk -arch x86_64 -consoleLog

!ENTRY org.abs-models.abs.plugin 4 0 2015-07-30 21:01:42.345
!MESSAGE FrameworkEvent ERROR
!STACK 0
org.osgi.framework.BundleException: Could not resolve module: org.abs-models.abs.plugin [531]
  Unresolved requirement: Require-Bundle: org.abs-models.sdedit; bundle-version="0.0.0"

    at org.eclipse.osgi.container.Module.start(Module.java:434)
    at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1582)
    at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1561)
    at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1533)
    at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1476)
    at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)
    at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
    at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)

My environment:

  • Java 1.8.0_60
  • Eclipse PDE Mars Release

Deadlock checker crashes on some examples


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 120, https://envisage.ifi.uio.no:8080/redmine/issues/120
Original Date: 2014-01-28
Original Assignee: Michael Lienhardt


According to https://envisage.ifi.uio.no:8080/jenkins/job/ABS-Bucky-Tests/lastCompletedBuild/testReport/, it crashes on some models like:

java.lang.AssertionError: Couldn't find class Comparator
    at abs.frontend.ast.Call.typeInference(Call.java:219)
    at abs.frontend.ast.VarDecl.typeInference(VarDecl.java:213)
    at abs.frontend.ast.VarDeclStmt.typeInference(VarDeclStmt.java:210)
    at abs.frontend.ast.Block.typeInference(Block.java:275)
    at abs.frontend.ast.MethodImpl.typeInference(MethodImpl.java:227)
    at abs.frontend.ast.ClassDecl.typeInference(ClassDecl.java:295)
    at abs.frontend.ast.ModuleDecl.typeInference(ModuleDecl.java:340)
    at abs.frontend.ast.CompilationUnit.typeInference(CompilationUnit.java:97)
    at abs.frontend.ast.Model.typeInference(Model.java:389)
    at deadlock.analyser.Analyser.deadlockAnalysis(Analyser.java:52)
    at deadlock.DeadlockCheckerTests.parse(DeadlockCheckerTests.java:27)
    at abs.frontend.parser.ParseSamplesTest.test(ParseSamplesTest.java:54)
    at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)

(Not all failures on Jenkins are relevant, though, sometimes the model is buggy)

Eclipse runtime error


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 116, https://envisage.ifi.uio.no:8080/redmine/issues/116
Original Date: 2014-01-24


This happened when the editor tripped over a case e:{..} stmt (note the :).
Again, the question is whether the editor should run rewrite rules or not (#85,#86) -- probably especially not on models that don't parse!

Caused by: java.lang.AssertionError: Should never happen for a well-typed model:UnknownType/<UNKNOWN>
    at abs.frontend.typechecker.Type.toUse(Type.java:264)
    at abs.frontend.ast.Stmt.rewriteRule0(Stmt.java:551)
    at abs.frontend.ast.Stmt.rewriteTo(Stmt.java:532)
    at abs.frontend.ast.ExpressionStmt.rewriteTo(ExpressionStmt.java:464)
    at abs.frontend.ast.ASTNode.getChild(ASTNode.java:607)
    at abs.frontend.ast.List.rewriteTo(List.java:288)
    at abs.frontend.ast.ASTNode.getChild(ASTNode.java:607)
    at abs.frontend.ast.Block.getStmtList(Block.java:601)
    at abs.frontend.ast.Block.getNumStmt(Block.java:541)
    at abs.frontend.ast.Block.hasRewriteBlockAt(Block.java:87)
    at abs.frontend.ast.Block.rewriteTo(Block.java:813)
    at abs.frontend.ast.ASTNode.getChild(ASTNode.java:607)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:43)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:43)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:43)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:43)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:43)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:43)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:43)
    at abs.frontend.parser.SourcePosition.findPosition(SourcePosition.java:34)
    at org.absmodels.abs.plugin.util.UtilityFunctions.getASTNodeOfOffset(UtilityFunctions.java:373)
    at org.absmodels.abs.plugin.editor.ABSCodeScanner.evalAST(ABSCodeScanner.java:307)
    at org.absmodels.abs.plugin.editor.ABSCodeScanner.internalNextToken(ABSCodeScanner.java:260)
    at org.absmodels.abs.plugin.editor.ABSCodeScanner.nextToken(ABSCodeScanner.java:231)
    at org.eclipse.jface.text.rules.DefaultDamagerRepairer.createPresentation(DefaultDamagerRepairer.java:175)

Typechecking error with ADT record-syntax


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 109, https://envisage.ifi.uio.no:8080/redmine/issues/109
Original Date: 2014-01-17


This data definition successfully typechecks (didn't try to run it though):

data AorB<A,B> = A(A) | B(B);

However, when using the record syntax it breaks:

data AorB<A,B> = A(A getA) | B(B getB);

The typecheck errors are:

Test.abs:7:20:Data constructor A cannot be resolved.
data AorB<A,B> = A(A getA) | B(B getB);
-------------------^
Test.abs:7:20:Name res cannot be resolved.
data AorB<A,B> = A(A getA) | B(B getB);
-------------------^
Test.abs:7:20:Case branches with incomparable types, and .
data AorB<A,B> = A(A getA) | B(B getB);
-------------------^
Test.abs:7:20:Cannot assign to type A.
data AorB<A,B> = A(A getA) | B(B getB);
-------------------^
Test.abs:7:32:Data constructor B cannot be resolved.
data AorB<A,B> = A(A getA) | B(B getB);
-------------------------------^
Test.abs:7:32:Name res cannot be resolved.
data AorB<A,B> = A(A getA) | B(B getB);
-------------------------------^
Test.abs:7:32:Case branches with incomparable types, and .
data AorB<A,B> = A(A getA) | B(B getB);
-------------------------------^
Test.abs:7:32:Cannot assign to type B.
data AorB<A,B> = A(A getA) | B(B getB);
-------------------------------^

almost duplicate methods getAnnotationsOfType and getAnnotationValue in different classes


Author Name: Rudolf Schlatte (Rudolf Schlatte)
Original Redmine Issue: 98, https://envisage.ifi.uio.no:8080/redmine/issues/98
Original Date: 2013-11-29
Original Assignee: Rudolf Schlatte


Overlap between abs.frontend.analyser.AnnotationHelper and abs.common.CompilerHelper

Also, one of them uses the qualified name and one the unqualified name. When fixing this, take care that the qualified annotation name doesn't get resolved completely - in case of type synonyms (type Deadline = Duration) we want to end with ABS.StdLib.Deadline, not ABS.StdLib.Duration.

Buggy Set implementation in ABS standard library


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 112, https://envisage.ifi.uio.no:8080/redmine/issues/112
Original Date: 2014-01-20
Original Assignee: Rudolf Schlatte


The size implementation of the Set datastructure in the ABS standard library is wrong.

Consider this code:

{
Set s = set[4,4,4];
assert (size(s) == 1);

}

This assertion fails. Where this assertion succeeds:

{
Set s = set[4,4,4];
assert (size(s) == 3);

}

The problem lies in abslang.abs .
The size function acts more like a list length function and does not pay respect to duplicate items.

Also, IMO both Set and Map datastructures should better be implemented for efficiency reasons as balanced binary trees,
and not as simple lists (Set) and association lists (Map).

Nikolaos

Runtime error in Eclipse


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 86, https://envisage.ifi.uio.no:8080/redmine/issues/86
Original Date: 2013-11-13
Original Assignee: Volker Stolz


There's another runtime error hidden in the Eclipse plugin. It doesn't seem to have any serious effect, though.

java.lang.RuntimeException: Circular definition of attr: getDecl in class: org.jastadd.ast.AST.SynDecl
    at abs.frontend.ast.VarUse.getDecl(VarUse.java:353)
    at abs.frontend.ast.VarUse.rewriteTo(VarUse.java:375)
    at abs.frontend.ast.ASTNode.getChild(ASTNode.java:606)
    at abs.frontend.ast.ASTNode.collect_contributors_Stmt_getAACs(ASTNode.java:1098)
    at abs.frontend.ast.ASTNode.collect_contributors_Stmt_getAACs(ASTNode.java:1098)
    at abs.frontend.ast.ASTNode.collect_contributors_Stmt_getAACs(ASTNode.java:1098)
    at abs.frontend.ast.ASTNode.collect_contributors_Stmt_getAACs(ASTNode.java:1098)
    at abs.frontend.ast.Stmt.collect_contributors_Stmt_getAACs(Stmt.java:351)
    at abs.frontend.ast.Stmt.getAACs_compute(Stmt.java:618)
    at abs.frontend.ast.Stmt.getAACs(Stmt.java:587)
    at abs.frontend.ast.Stmt.rewriteTo(Stmt.java:529)
    at abs.frontend.ast.VarDeclStmt.rewriteTo(VarDeclStmt.java:578)
    at abs.frontend.ast.ASTNode.getChild(ASTNode.java:606)
    at abs.frontend.ast.List.getNumChild(List.java:208)
    at abs.frontend.ast.Block.getStmtList(Block.java:601)
    at abs.frontend.ast.Block.getStmt(Block.java:558)
    at abs.frontend.ast.Block.Define_VarOrFieldDecl_lookupVarOrFieldName(Block.java:790)
    at abs.frontend.ast.ASTNode.Define_VarOrFieldDecl_lookupVarOrFieldName(ASTNode.java:1683)
    at abs.frontend.ast.ASTNode.Define_VarOrFieldDecl_lookupVarOrFieldName(ASTNode.java:1683)
    at abs.frontend.ast.ASTNode.Define_VarOrFieldDecl_lookupVarOrFieldName(ASTNode.java:1683)
    at abs.frontend.ast.ASTNode.Define_VarOrFieldDecl_lookupVarOrFieldName(ASTNode.java:1683)
    at abs.frontend.ast.ASTNode.Define_VarOrFieldDecl_lookupVarOrFieldName(ASTNode.java:1683)
    at abs.frontend.ast.Exp.lookupVarOrFieldName(Exp.java:415)
    at abs.frontend.ast.VarUse.getDecl_compute(VarUse.java:370)
    at abs.frontend.ast.VarUse.getDecl(VarUse.java:358)
    at org.absmodels.abs.plugin.editor.ABSCodeScanner.evalAST(ABSCodeScanner.java:321)
    at org.absmodels.abs.plugin.editor.ABSCodeScanner.internalNextToken(ABSCodeScanner.java:259)
    at org.absmodels.abs.plugin.editor.ABSCodeScanner.nextToken(ABSCodeScanner.java:230)
    at org.eclipse.jface.text.rules.DefaultDamagerRepairer.createPresentation(DefaultDamagerRepairer.java:175)

Refactor annotation processing


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 95, https://envisage.ifi.uio.no:8080/redmine/issues/95
Original Date: 2013-11-25
Original Assignee: Volker Stolz


There's

  • abs.frontend.analyser.AnnotationHelper, and
  • abs.common.CompilerUtils.

I guess one of them can simply be merged into the other.

Plus, those static helper are often called as m(s.getAnnotations(),…), so a bit more OO could probably applied as well.

White-list expected failures in tool checks


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 123, https://envisage.ifi.uio.no:8080/redmine/issues/123
Original Date: 2014-01-29
Original Assignee: Volker Stolz


Right now, we run e.g. the deadlock checker on models where it doesn't actually make sense, like an open system or one without main block.

Can we capture these preconditions in the unit tests somehow, so that they do not show up as failed? I guess it will come up more frequently.

So either we return to individual tests, or we somehow add this to the parametrised test runner...

Missing documentation about the ADT record syntax


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 111, https://envisage.ifi.uio.no:8080/redmine/issues/111
Original Date: 2014-01-20
Original Assignee: Nikolaos Bezirgiannis


In ABS language specification:

April 22, 2013
Document Version 19890

I think there is no documentation for support of the record syntax in ADTs,
where you can name fields of the data constructors, as in the example:

data Either<A,B> = Left(A left) | Right(B right);

here left and right are the names of the fields.

I assign it to myself to add this to the documentation.

Provide Maven 3+ on Jenkins


Author Name: Behrooz Nobakht (Behrooz Nobakht)
Original Redmine Issue: 127, https://envisage.ifi.uio.no:8080/redmine/issues/127
Original Date: 2014-02-05
Original Assignee: Volker Stolz


If a project based on Maven needs to built on Jenkins server, it needs to select a Maven as part of job configuration. This seems to be not available in this moment.

Please provide an installation of Maven on the CI server to be used preferably Maven 3+.

Request for a few Jenkins plugins


Author Name: Behrooz Nobakht (Behrooz Nobakht)
Original Redmine Issue: 128, https://envisage.ifi.uio.no:8080/redmine/issues/128
Original Date: 2014-02-06
Original Assignee: Volker Stolz


Related to #126 and #127, please install the following plugins for Jenkins instance:

COGs as first-class citizens of the language


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 104, https://envisage.ifi.uio.no:8080/redmine/issues/104
Original Date: 2014-01-06


I would like to discuss about adding the following to the ABS standard library:

data COG; // as an abstract data type, the implementation is hidden

def COG whereis(A obj) = builtin;

I see 2 reasons why this can be a benefit for the user:

  1. The user can check at run-time if an incoming object belongs to the same cog
    and figure out if she wants to make a synchronous call (same-COG object) or asynchronous call (other-COG object) as in the example:

class Class2 {
Unit method2(Class1 obj1) {
COG location1 = whereis(obj1);
COG my_location = whereis(this);
if (my_location == location) {
// safe to make synchronous call
obj1.method1();
}
else {
obj1 ! method();
}
}
}

  1. The user can check if she is running in the main top COG.
    That would also require
    def COG thisCOG() = builtin;
    builtin procedure.

I already went ahead and implemented those in my experimental Haskell backend. I assume these are implementable in the Erlang backend and perhaps also in the Java backend.

I saw some reflection stuff inside the abslang.abs standard library but I am not sure if they support the same thing.

This idea can be possibly be extended for DeploymentComponents?

ABS frontend cannot build with latest Apache Ant version


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 81, https://envisage.ifi.uio.no:8080/redmine/issues/81
Original Date: 2013-11-08


System: Archlinux 64bit
Java: Tested both on Java 6 and Java 7
Ant version: Test both on 1.9.2 and 1.9.0

Running ant under frontend/ fails with:

Buildfile: /home/bezirg/Dropbox/Repos/abs/frontend/build.xml

prepare:

genshell:

genflex:
[echo] Running jflex

BUILD FAILED
/home/bezirg/Dropbox/Repos/abs/frontend/build.xml:235: java.lang.NoSuchMethodError: java_cup.runtime.lr_parser.getSymbolFactory()Ljava_cup/runtime/SymbolFactory;
at JFlex.CUP$LexParse$actions.CUP$LexParse$do_action(LexParse.java:1703)
at JFlex.LexParse.do_action(LexParse.java:408)
at java_cup.runtime.lr_parser.parse(lr_parser.java:569)
at JFlex.Main.generate(Main.java:73)
at JFlex.anttask.JFlexTask.execute(JFlexTask.java:71)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:435)
at org.apache.tools.ant.Target.performTasks(Target.java:456)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
at org.apache.tools.ant.Main.runBuild(Main.java:851)
at org.apache.tools.ant.Main.startAnt(Main.java:235)
at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)

Total time: 0 seconds

The build is though successful with Ant 1.8.4.

This literal in Documentation


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 135, https://envisage.ifi.uio.no:8080/redmine/issues/135
Original Date: 2014-02-27
Original Assignee: Nikolaos Bezirgiannis


The latest specification manual does not list 'this' as a literal of the ABS language.

At section 2.5 , page 7.

Is 'this' a literal of the language?

If so, I will fix the documentation

Conflicting names in abslang.abs


Author Name: Vlad Serbanescu (Vlad Serbanescu)
Original Redmine Issue: 113, https://envisage.ifi.uio.no:8080/redmine/issues/113
Original Date: 2014-01-20


There are some definitions of data in the abslang.abs that can be a bit confusing to a new user of ABS:

data Pair<A, B> = Pair(A fst, B snd);

data Triple<A, B, C> = Triple(A fstT, B sndT, C trd);

data Time = Time(Rat timeValue);
data Duration = Duration(Rat durationValue) | InfDuration;

I feel it might be a bit easier to differentiate between the data name and its possible values/predicates.

Grammar error on LET


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 134, https://envisage.ifi.uio.no:8080/redmine/issues/134
Original Date: 2014-02-27


Affected code:

module Testing;

interface Interf1 {
  Unit m1();
}

class Cls1 implements Interf1 {
  Unit m1() {

  }
}

{
  Interf1 o1 = new local Cls1();
  Unit z = (let (Bool b) = True in o1).m1();
}

The raised syntactic errors are:

Syntactic errors: 3
Test.abs:15:39:Syntactic error: unexpected token DOT
  Unit z = (let (Bool b) = True in o1).m1();
--------------------------------------^
Test.abs:15:44:Syntactic error: unexpected token SEMICOLON
  Unit z = (let (Bool b) = True in o1).m1();
-------------------------------------------^
Test.abs:15:40:Missing ((String)method.value) call.
  Unit z = (let (Bool b) = True in o1).m1();
---------------------------------------^

The problem is the surrounding of LET exp with parentheses.
The code compiles without them.

Update documentation for Return statements


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 103, https://envisage.ifi.uio.no:8080/redmine/issues/103
Original Date: 2014-01-03


Via Nikolaos:

In The ABS Language Specification
For ABS Version 1.2.0
April 22, 2013
Document Version 19890

Page 26:
the grammar rule

ReturnStmt ::= return PureExp ;

means that we can only return Pure Expressions.

Yet ABS.ast states:

ReturnStmt: Stmt ::= RetExp:Exp;

permitting any expression.

Redundant argument name declarations in Interfaces


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 110, https://envisage.ifi.uio.no:8080/redmine/issues/110
Original Date: 2014-01-18


An example of an Interface:

interface Interf1 {
Int method1(Int n, Int m);
}

Why declare n and m there? There is no point since they don't add anything to the type signature.

The type signature in C would be (int) (int, int) and in Haskell method1 :: (Int, Int) -> Int

Is it because it makes it easier to the user?
Could the argument names in Interface be instead optional in the ABS syntax? So, possibly the next definition will also be accepted:

interface Interf1 {
Int method1(Int, Int);
}

Provide an installation of Java 8 on Jenkins server


Author Name: Behrooz Nobakht (Behrooz Nobakht)
Original Redmine Issue: 126, https://envisage.ifi.uio.no:8080/redmine/issues/126
Original Date: 2014-02-05
Original Assignee: Volker Stolz


We're planning to publish ABS API in Java 8 and we're interested to take advantage of the CI server that is available.

Please provide an installation of Java 8 in Jenkins server to be used. A last version can be obtained from: https://jdk8.java.net/download.html

Polymorphic type-synonyms


Author Name: Nikolaos Bezirgiannis (Nikolaos Bezirgiannis)
Original Redmine Issue: 108, https://envisage.ifi.uio.no:8080/redmine/issues/108
Original Date: 2014-01-17


I just found out that the ABS language lacks support (both in syntax and code generation)
for polymorphic type synonyms, such as:

type Option = Maybe;

Is this omission intentional? Because, I am planning to support this in my Haskell backend (and the translation is straight-forward).

Please let me know any reasons of why I should not do that.

Jenkins polling too eager


Author Name: Volker Stolz (Volker Stolz)
Original Redmine Issue: 87, https://envisage.ifi.uio.no:8080/redmine/issues/87
Original Date: 2013-11-14


Currently Jenkins will start a build of everything if someone only looks funnily at the GIT repo.

Either find out how to limit polling to sub-directories, or switch to post-commit-hooks (probably the latter).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.