Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Predefined unit variables #348

Merged
merged 31 commits into from
May 23, 2017

Commits on Apr 16, 2017

  1. Remove prefixes of d,c,da,h and fix typo

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 16, 2017
    Configuration menu
    Copy the full SHA
    89b4b17 View commit details
    Browse the repository at this point in the history
  2. Add predefined variables for each possible SI unit

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 16, 2017
    Configuration menu
    Copy the full SHA
    de12e9d View commit details
    Browse the repository at this point in the history
  3. Drop NESTMLNumericLiteral from grammar

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 16, 2017
    Configuration menu
    Copy the full SHA
    8aa9053 View commit details
    Browse the repository at this point in the history

Commits on Apr 17, 2017

  1. Fix issues arising from removing NESTMLNumericLiteral

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 17, 2017
    Configuration menu
    Copy the full SHA
    de4cce3 View commit details
    Browse the repository at this point in the history
  2. Adapt /models to changes:

    replace "n * unit" with "n unit"
    replace "1 * unit" with "unit"
    replace "[complexRhsUnit]" with "complexRhsUnit"
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 17, 2017
    Configuration menu
    Copy the full SHA
    f83c3a0 View commit details
    Browse the repository at this point in the history
  3. Change expressionvisitor system to deal with "literal unit" instead o…

    …f "literal*unit"
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 17, 2017
    Configuration menu
    Copy the full SHA
    037f8ca View commit details
    Browse the repository at this point in the history
  4. Fix some tests

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 17, 2017
    Configuration menu
    Copy the full SHA
    01d33ba View commit details
    Browse the repository at this point in the history

Commits on Apr 19, 2017

  1. Check that "Literal Variable" expressions use only SI-unit variables

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 19, 2017
    Configuration menu
    Copy the full SHA
    7d4bc16 View commit details
    Browse the repository at this point in the history
  2. Change for loop from:

    for n ... m step k
    
    to
    for n ... m : k
    
    To resolve clash with changed expression grammar
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 19, 2017
    Configuration menu
    Copy the full SHA
    84433bc View commit details
    Browse the repository at this point in the history
  3. Adapt test case to grammar change.

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 19, 2017
    Configuration menu
    Copy the full SHA
    c84171f View commit details
    Browse the repository at this point in the history
  4. Add "isPredefined" to VariableSymbol to indicate if it is a predefine…

    …d Variable.
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 19, 2017
    Configuration menu
    Copy the full SHA
    5d331e6 View commit details
    Browse the repository at this point in the history
  5. Drop predefined VariableSymbols from resolved List before testing Var…

    …iableNotDefinedBeforeUse.
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 19, 2017
    Configuration menu
    Copy the full SHA
    e648429 View commit details
    Browse the repository at this point in the history
  6. Adapt test case.

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 19, 2017
    Configuration menu
    Copy the full SHA
    96d98f9 View commit details
    Browse the repository at this point in the history
  7. Change for_stmt step notation again.

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 19, 2017
    Configuration menu
    Copy the full SHA
    c2a4085 View commit details
    Browse the repository at this point in the history
  8. Fix step notation in models

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 19, 2017
    Configuration menu
    Copy the full SHA
    434b72d View commit details
    Browse the repository at this point in the history
  9. Fix variable name.

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 19, 2017
    Configuration menu
    Copy the full SHA
    58f07af View commit details
    Browse the repository at this point in the history
  10. fix iteration over symbols

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 19, 2017
    Configuration menu
    Copy the full SHA
    8e41d58 View commit details
    Browse the repository at this point in the history

Commits on Apr 20, 2017

  1. Implement helper funciton to convert a unit into the literal represen…

    …tation of its magnitude
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 20, 2017
    Configuration menu
    Copy the full SHA
    b9a5d74 View commit details
    Browse the repository at this point in the history
  2. Teach various ReferenceConverters to print units as their literal rep…

    …resentation
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 20, 2017
    Configuration menu
    Copy the full SHA
    a62ae60 View commit details
    Browse the repository at this point in the history
  3. Getter for magnitude

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 20, 2017
    Configuration menu
    Copy the full SHA
    6dfdca0 View commit details
    Browse the repository at this point in the history
  4. Teach expressionprinter to print "literal variable" pairs as "literal…

    … * convertedVariable"
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 20, 2017
    Configuration menu
    Copy the full SHA
    81fa348 View commit details
    Browse the repository at this point in the history
  5. Remove debug output

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 20, 2017
    Configuration menu
    Copy the full SHA
    bf4dd1b View commit details
    Browse the repository at this point in the history
  6. Reinstate "step" notation for for loops. Make step mandatory to avoid…

    … matching as variable
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 20, 2017
    Configuration menu
    Copy the full SHA
    6e84db7 View commit details
    Browse the repository at this point in the history
  7. Adapt models to mandatory step notation in for loops

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed Apr 20, 2017
    Configuration menu
    Copy the full SHA
    8d03233 View commit details
    Browse the repository at this point in the history

Commits on May 10, 2017

  1. fix variable names

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed May 10, 2017
    Configuration menu
    Copy the full SHA
    3d35b86 View commit details
    Browse the repository at this point in the history
  2. add unit-variable conversion code to one more ReferenceConverter

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed May 10, 2017
    Configuration menu
    Copy the full SHA
    cb24016 View commit details
    Browse the repository at this point in the history
  3. Install infrastructure and a NESTML specific filter for units.

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed May 10, 2017
    Configuration menu
    Copy the full SHA
    b2281a8 View commit details
    Browse the repository at this point in the history
  4. Use NESTMLUnitFilter to calculate the modification factors for c++ code.

    This will add a factor != 1.0 iff the variable is not one of the NEST specific units.
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed May 10, 2017
    Configuration menu
    Copy the full SHA
    aa7b2f3 View commit details
    Browse the repository at this point in the history

Commits on May 19, 2017

  1. Merge branch 'master' of https://github.com/nest/nestml into predefin…

    …ed-unit-variables
    
    # Conflicts:
    #	src/main/java/org/nest/codegeneration/converters/NESTReferenceConverter.java
    #	src/main/java/org/nest/spl/prettyprinter/LegacyExpressionPrinter.java
    #	src/main/java/org/nest/spl/prettyprinter/SPLPrettyPrinter.java
    #	src/main/java/org/nest/symboltable/symbols/VariableSymbol.java
    #	src/main/java/org/nest/utils/AstUtils.java
    
    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed May 19, 2017
    Configuration menu
    Copy the full SHA
    ecab368 View commit details
    Browse the repository at this point in the history
  2. Fix indentation

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed May 19, 2017
    Configuration menu
    Copy the full SHA
    409a6c4 View commit details
    Browse the repository at this point in the history

Commits on May 20, 2017

  1. Fixed spacing again

    Signed-off-by: Philip Traeder <philip.traeder@rwth-aachen.de>
    PTraeder committed May 20, 2017
    Configuration menu
    Copy the full SHA
    189dd14 View commit details
    Browse the repository at this point in the history