-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #189 from uqbar-project/printer
Primera version printer
- Loading branch information
Showing
12 changed files
with
3,252 additions
and
56 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,62 @@ | ||
import { Name } from './model' | ||
|
||
export const WOLLOK_EXTRA_STACK_TRACE_HEADER = 'Derived from TypeScript stack' | ||
|
||
export const WOLLOK_BASE_PACKAGE = 'wollok.' | ||
export const WOLLOK_BASE_PACKAGE = 'wollok.' | ||
|
||
export const PREFIX_OPERATORS: Record<Name, Name> = { | ||
'!': 'negate', | ||
'-': 'invert', | ||
'+': 'plus', | ||
'not': 'negate', | ||
} | ||
|
||
export const ASSIGNATION_OPERATORS = ['=', '||=', '/=', '-=', '+=', '*=', '&&=', '%='] | ||
|
||
export const INFIX_OPERATORS = [ | ||
['||', 'or'], | ||
['&&', 'and'], | ||
['===', '==', '!==', '!='], | ||
['>=', '>', '<=', '<'], | ||
['?:', '>>>', '>>', '>..', '<>', '<=>', '<<<', '<<', '..<', '..', '->'], | ||
['-', '+'], | ||
['/', '*'], | ||
['**', '%'], | ||
] | ||
|
||
export const LIST_MODULE= 'wollok.lang.List' | ||
export const SET_MODULE= 'wollok.lang.Set' | ||
export const OBJECT_MODULE= 'wollok.lang.Object' | ||
|
||
export const KEYWORDS = { | ||
IF: 'if', | ||
ELSE: 'else', | ||
NEW: 'new', | ||
SELF: 'self', | ||
SUPER: 'super', | ||
NULL: 'null', | ||
METHOD: 'method', | ||
VAR: 'var', | ||
THROW: 'throw', | ||
TRY: 'try', | ||
CATCH: 'catch', | ||
THEN: 'then', | ||
ALWAYS: 'always', | ||
PROPERTY: 'property', | ||
CONST: 'const', | ||
OVERRIDE: 'override', | ||
NATIVE: 'native', | ||
RETURN: 'return', | ||
IMPORT: 'import', | ||
SUITE: 'describe', | ||
TEST: 'test', | ||
MIXIN: 'mixin', | ||
CLASS: 'class', | ||
INHERITS: 'inherits', | ||
DERIVED: 'derived', | ||
MIXED_AND: 'and', | ||
WKO: 'object', | ||
FIXTURE: 'fixture', | ||
PROGRAM: 'program', | ||
PACKAGE: 'package', | ||
} as const |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.