Rafal Kupiec
9884f8288b
Do not allow typecasting to unset a variable.
4 years ago
Rafal Kupiec
0a9cfce672
Group and add missing keywords.
4 years ago
Rafal Kupiec
fbc725c935
We are tokenizing Aer.
4 years ago
Rafal Kupiec
9100bf0696
Treat 'import' as a special keyword.
4 years ago
Rafal Kupiec
b5fe36c14b
There is no need for include_once() and require_once()
Aer is object-oriented language and the code it includes is executed in the global scope. Global scope can contain only classes and namespaces and they cannot be re-declared. Thus every file can be included just once. We can
leave this to programmer, or take care about it on interpreter side. With this commit, include() and require() builtin functions allows to load file just once. Thanks to that, there is no need for include_once() and
require_once(). Done in scope of #30 .
4 years ago
Rafal Kupiec
7e3c79d3c5
Functions naming cleanup
4 years ago
Rafal Kupiec
d7f9d8e157
Add missing 'finally' keyword.
4 years ago
Rafal Kupiec
59c15caf4e
Use something more human readable
4 years ago
Rafal Kupiec
a4e6962a67
Free dot operator for further usage
4 years ago
Rafal Kupiec
4bbdc20174
This commit contains several changes:
* print() is now treated as standard function
* get rid of echo() function
* fix test suite
and it fixes #26 .
4 years ago
Rafal Kupiec
e0b939d9a2
In general it is a bad idea to compare memory. We should compare strings and check its length. Fixes #34 .
4 years ago
Rafal Kupiec
2c37807370
Get rid of global keyword, fixes #29
4 years ago
Rafal Kupiec
7b3e6c5b76
P# introduces virtual classes and virtual methods
4 years ago
Rafal Kupiec
b7792dfc3d
P# is not going to derive namespace syntax from PHP, but from C++.
4 years ago
Rafal Kupiec
5cb19f63a5
Get rid of alternative syntax for control structures (endif, endwhile, endfor, endforeach). Only curly brackets are allowed.
4 years ago
Rafal Kupiec
159cd76020
No need to duplicate exit()
4 years ago
Rafal Kupiec
3f1397ed93
Get rid of switch: endswitch construct
4 years ago
Rafal Kupiec
ef2ea60a60
Treat whole file as P# source code. Fixes #24 .
4 years ago
Rafal Kupiec
d3ff86f692
Correct some typos
4 years ago
Rafal Kupiec
abb91a9874
Reorganize the repository for new build system
4 years ago
Rafal Kupiec
6abb65a04c
declare() is a stupid and useless construct. It will not be supported in P#.
4 years ago
Rafal Kupiec
4eb2e76498
Borrowed from Bash, but unnecessary
4 years ago
Rafal Kupiec
caedd1a9f8
Only bool, float, int. They dont need synonyms.
4 years ago
Rafal Kupiec
8b59a01198
There is no need to use 'and' & 'or' keywords, as P# supports also '&&' and '||' to use respectively
4 years ago
Rafal Kupiec
4071f0b8ee
P# supports only ^^ keyword as a logical XOR. There is no need to have 'xor'.
4 years ago
Rafal Kupiec
d898cd1e36
Code formatting
4 years ago
Rafal Kupiec
03bfd2203c
Reorganisation
4 years ago
Rafal Kupiec
5ad57f6740
Implement logical XOR operator (^^)
4 years ago
Rafal Kupiec
f212588ab1
Removing unnecessary operators (eq, ne). Some special strings comparison should be implemented as a function like strcmp().
4 years ago
Rafal Kupiec
dce1b38e79
P# allows to use multiline string block, thus heredoc/newdoc syntax is not needed
4 years ago
Rafal Kupiec
c7feffc43f
GOTO is an evil statement and should be avoid. Its not available in P#
4 years ago
Rafal Kupiec
dff0a5c968
Replace automatically generated code with a more friendly equivalent
4 years ago
Rafal Kupiec
520e2280e4
No amalgamation
4 years ago
Rafal Kupiec
5b10ea3b41
de-amalgamation of code for easier maintenance
4 years ago