Changeset 14777 for branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/IntegerExpressions.cs
- Timestamp:
- 03/23/17 01:11:18 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/IntegerExpressions.cs
r14744 r14777 10 10 /// Pushes the sum of the top two items. 11 11 /// </summary> 12 [PushExpression(StackType .Integer, "INTEGER.+")]12 [PushExpression(StackTypes.Integer, "INTEGER.+")] 13 13 public class IntegerAddExpression : PushResultExpression<long> { 14 14 public override bool Eval(IPushInterpreter interpreter) { … … 20 20 /// Pushes the difference of the top two items; that is, the second item minus the top item. 21 21 /// </summary> 22 [PushExpression(StackType .Integer, "INTEGER.-")]22 [PushExpression(StackTypes.Integer, "INTEGER.-")] 23 23 public class IntegerSubtractExpression : PushResultExpression<long> { 24 24 public override bool Eval(IPushInterpreter interpreter) { … … 30 30 /// Pushes the product of the top two items. 31 31 /// </summary> 32 [PushExpression(StackType .Integer, "INTEGER.*")]32 [PushExpression(StackTypes.Integer, "INTEGER.*")] 33 33 public class IntegerMultiplyExpression : PushResultExpression<long> { 34 34 public override bool Eval(IPushInterpreter interpreter) { … … 41 41 /// If the top item is zero this acts as a NOOP. 42 42 /// </summary> 43 [PushExpression(StackType .Integer, "INTEGER./")]43 [PushExpression(StackTypes.Integer, "INTEGER./")] 44 44 public class IntegerDivideExpression : PushResultExpression<long> { 45 45 public override bool Eval(IPushInterpreter interpreter) { … … 56 56 /// http://www.lispworks.com/reference/HyperSpec/Body/f_mod_r.htm.) 57 57 /// </summary> 58 [PushExpression(StackType .Integer, "INTEGER.%")]58 [PushExpression(StackTypes.Integer, "INTEGER.%")] 59 59 public class IntegerModuloExpression : PushResultExpression<long> { 60 60 public override bool Eval(IPushInterpreter interpreter) { … … 66 66 /// Pushes the minimum of the top two items. 67 67 /// </summary> 68 [PushExpression(StackType .Integer, "INTEGER.MIN")]68 [PushExpression(StackTypes.Integer, "INTEGER.MIN")] 69 69 public class IntegerMinExpression : PushResultExpression<long> { 70 70 public override bool Eval(IPushInterpreter interpreter) { … … 76 76 /// Pushes the maximum of the top two items. 77 77 /// </summary> 78 [PushExpression(StackType .Integer, "INTEGER.MAX")]78 [PushExpression(StackTypes.Integer, "INTEGER.MAX")] 79 79 public class IntegerMaxExpression : PushResultExpression<long> { 80 80 public override bool Eval(IPushInterpreter interpreter) { … … 86 86 /// Pushes TRUE onto the BOOLEAN stack if the second item is less than the top item, or FALSE otherwise. 87 87 /// </summary> 88 [PushExpression(StackType .Integer, "INTEGER.<")]88 [PushExpression(StackTypes.Integer, "INTEGER.<", StackTypes.Boolean)] 89 89 public class IntegerSmallerThanExpression : PushResultExpression<long> { 90 90 public override bool Eval(IPushInterpreter interpreter) { … … 96 96 /// Pushes TRUE onto the BOOLEAN stack if the second item is greater than the top item, or FALSE otherwise. 97 97 /// </summary> 98 [PushExpression(StackType .Integer, "INTEGER.>")]98 [PushExpression(StackTypes.Integer, "INTEGER.>", StackTypes.Boolean)] 99 99 public class IntegerGreaterThanExpression : PushResultExpression<long> { 100 100 public override bool Eval(IPushInterpreter interpreter) { … … 106 106 /// Pushes 1 if the top BOOLEAN is TRUE, or 0 if the top BOOLEAN is FALSE. 107 107 /// </summary> 108 [PushExpression(StackType .Integer, "INTEGER.FROMBOOLEAN")]108 [PushExpression(StackTypes.Integer, "INTEGER.FROMBOOLEAN", StackTypes.Boolean)] 109 109 public class IntegerFromBooleanExpression : StatelessExpression { 110 110 public override bool Eval(IPushInterpreter interpreter) { … … 123 123 /// Pushes the result of truncating the top FLOAT. 124 124 /// </summary> 125 [PushExpression(StackType .Integer, "INTEGER.FROMFLOAT")]125 [PushExpression(StackTypes.Integer, "INTEGER.FROMFLOAT", StackTypes.Float)] 126 126 public class IntegerFromFloatExpression : StatelessExpression { 127 127 public override bool Eval(IPushInterpreter interpreter) {
Note: See TracChangeset
for help on using the changeset viewer.