Skip to content
This repository was archived by the owner on Apr 25, 2023. It is now read-only.

Commit d0a6451

Browse files
authored
Merge branch 'main' into dev
2 parents b3bb284 + c661311 commit d0a6451

File tree

5 files changed

+8
-12
lines changed

5 files changed

+8
-12
lines changed

Main/lexer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050
Final,
5151
)
5252

53+
import Main._types
5354

5455
#############
5556
# CONSTANTS #
@@ -435,7 +436,6 @@ def lex(self, text: Optional[str] = None) -> Optional[List[LexerToken]]:
435436

436437
return self.tokens
437438

438-
439439
if __name__ == "__main__":
440440
options: Dict[str, bool] = {
441441
"types": False,

Modules/Math.ilang

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,9 @@ import _core
3535
// CONSTANTS //
3636
///////////////
3737

38-
const float Pi = 3.141592653589793238462643383279502884197
39-
const float E = 2.718281828459045235360287471352662497757
40-
const float Infinite = _core.Math.Infinite
38+
const float pi = 3.141592653589793238462643383279502884197
39+
const float e = 2.718281828459045235360287471352662497757
40+
const float infinite = _core.Math.Infinite
4141

4242

4343
///////////
@@ -54,7 +54,7 @@ const float Infinite = _core.Math.Infinite
5454
* int: Rounded number.
5555
*/
5656
int round(float number) {
57-
return _core.Math.round(number)
57+
return _core.Math._round(number)
5858
}
5959

6060
// Todo (ElBe): Add floor and ceil

Modules/Random.ilang

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,10 @@ int randint(int minimum, int maximum) {
6969
*
7070
* @params
7171
* iterable (list): List to return a random choice from.
72-
* choices (list): Choices to return form the iterable. If choices is bigger than the iterable, the remaining values will be skipped.
72+
* choices (list): Number of choices to return form the iterable. If choices is bigger than the iterable, the remaining values will be skipped.
7373
*
7474
* @return
75-
* Any: Chosen object(s) from the iterable.
75+
* Any: Random value(s) from the iterable.
7676
*/
7777
function choices(list iterable, int choices = 1) {
7878
return _core.Random.choices(iterable, choices)

Modules/_core/Math.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,13 @@
3636
# CONSTANTS #
3737
#############
3838

39-
Infinite: Final[float] = float("inf") # Should be 1/0
39+
Infinite: Final[float] = float("inf")
4040

4141

4242
#########
4343
# ROUND #
4444
#########
4545

46-
4746
def _round(number: float) -> int:
4847
"""Rounds a number.
4948

Modules/_core/Random.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@
4141
# RANDINT #
4242
###########
4343

44-
4544
def randint(minimum: int, maximum: int) -> int:
4645
"""Generates a random number.
4746
@@ -64,7 +63,6 @@ def randint(minimum: int, maximum: int) -> int:
6463
# CHOICES #
6564
###########
6665

67-
6866
def choices(iterable: List, choices: int = 1) -> Any:
6967
"""Returns a random value from a given list.
7068
@@ -90,7 +88,6 @@ def choices(iterable: List, choices: int = 1) -> Any:
9088
# SHUFFLE #
9189
###########
9290

93-
9491
def shuffle(iterable: List) -> List:
9592
"""Shuffles a list and returns it.
9693

0 commit comments

Comments
 (0)