Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/org/aavso/tools/vstar/ui/vela/VeLaDialog.java
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,10 @@ public void keyTyped(KeyEvent e) {

if (escapeMode) {
switch (ch) {
case 'b':
// Boolean set
newCh = "\uD835\uDD39";
break;
case 'l':
// lambda
newCh = "\u03BB";
Expand Down
1 change: 1 addition & 0 deletions src/org/aavso/tools/vstar/vela/VeLa.g4
Original file line number Diff line number Diff line change
Expand Up @@ -371,6 +371,7 @@ BOOL_T
:
[Bb] [Oo] [Oo] [Ll] [Ee] [Aa] [Nn]
| [Bb] [Oo] [Oo] [Ll]
| '𝔹'
;

STR_T
Expand Down
10 changes: 10 additions & 0 deletions test/org/aavso/tools/vstar/vela/VeLaTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -1797,6 +1797,16 @@ public void testIntegerTypeNameInt() {
assertEquals(16.0, result.get().doubleVal());
}

public void testBooleanTypeName𝔹() {
String prog = "";
prog += "f(b : 𝔹) : 𝔹 {not b}";
prog += "f(false)";

Optional<Operand> result = vela.program(prog);
assertTrue(result.isPresent());
assertTrue(result.get().booleanVal());
}

public void testBooleanTypeNameBool() {
String prog = "";
prog += "f(b : bool) : bool {not b}";
Expand Down