Need a unique gift idea?
A Pastebin account makes a great Christmas gift
SHARE
TWEET

Untitled

a guest Nov 21st, 2018 92 Never
Upgrade to PRO!
ENDING IN00days00hours00mins00secs
 
  1. MIT License
  2.  
  3. Copyright (c) 2018 Computing and Engineering Department, Technical University of Varna
  4.  
  5. Permission is hereby granted, free of charge, to any person obtaining a copy
  6. of this software and associated documentation files (the "Software"), to deal
  7. in the Software without restriction, including without limitation the rights
  8. to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  9. copies of the Software, and to permit persons to whom the Software is
  10. furnished to do so, subject to the following conditions:
  11.  
  12. The above copyright notice and this permission notice shall be included in all
  13. copies or substantial portions of the Software.
  14.  
  15. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  16. IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  17. FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  18. AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  19. LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  20. OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  21. SOFTWARE.
  22.  
  23.  
  24.  
  25. //Keywords
  26. INT                     :   'int'
  27. CHAR                    :   'char'
  28. VOID                    :   'void'
  29. BOOLEAN                 :   'boolean'
  30. WHILE                   :   'while'
  31. RETURN                  :   'return'
  32. IF                      :   'if'
  33. ELSE                    :   'else'
  34. TRUE                    :   'true'
  35. FALSE                   :   'false'
  36. LENGTH                  :   'length'
  37. PROGRAM                 :   'program'
  38.  
  39. //Operators
  40. PLUS                    :   '+'
  41. MINUS                   :   '-'
  42. MUL                     :   '*'
  43. DIV                     :   '/'
  44. MOD                     :   '%'
  45. ASSIGNMENT              :   '='
  46.  
  47. NOT                     :   '!'
  48. EQUAL                   :   '=='
  49. NOT_EQUAL               :   '!='
  50. GREATER_THAN            :   '>'
  51. LESS_THAN               :   '<'
  52. GREATER_THAN_OR_EQUAL   :   '>='
  53. LESS_THAN_OR_EQUAL      :   '<='
  54.  
  55. AND                     :   '&&'
  56. OR                      :   '||'
  57.  
  58. LSQUARE                 :   '['
  59. RSQUARE                 :   ']'
  60. LBRACKET                :   '{'
  61. RBRACKET                :   '}'
  62. LPAREN                  :   '('
  63. RPAREN                  :   ')'
  64. SEMICOLON               :   ';'
  65. COMMA                   :   ','
  66. SINGLE_QUOTE            :   '\''
  67. DOUBLE_QUOTES           :   '"'
  68. ARROW                   :   '->'
  69. AT                      :   '@'
  70.  
  71. //Literals
  72. INT LITERAL             :   '0' | [1-9]{1}[0-9]*
  73. CHAR_LITERAL            :   any ascii character
  74. BOOLEAN_LITERAL         :   'true' | 'false'
  75.  
  76. //Identifiers
  77. IDENTIFIER              :   [A-Za-z]{1}[A-Za-z0-9]*
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top