Commit Graph

27 Commits

Author SHA1 Message Date
Vladislav Navrocky
384a6bef3f Fix: Remove circular dependencies in headers (#295)
* Remove circular dependencies in headers

* Fix unit test includes and test data directory location
2025-02-11 09:03:42 +01:00
Matheus Werny
92994bec0a clang-tidy applied and CMake installation of the single header added (#287)
* Fixed headers and linter marks applied

Headers were wrong.
Applied some linter suggestions. There are still many left.

* CMake adjusted for single header

CMake can now install the single header.
Removed an unneeded header.

---------

Co-authored-by: Berscheid <1885260+pantor@users.noreply.github.com>
2024-10-05 09:36:11 +02:00
ascii
c360b19855 Add capitalize function (#282)
* Add capitalize function

* Remove msvc warning
2024-09-19 06:03:33 -07:00
pantor
ea47bb14dc improve meson build 2023-01-28 13:15:58 +01:00
Kubo Takehiro
d462b9f829 Fix issue 246 (#247)
* Add `parse_expression` with one argument in preparation to fix #246.

* Fix issue #246: `func(n1 + n2, n3)` runs as if `func(n1, n2 + n3)`

* Simplify parser for an expression enclosed by parentheses.
2022-12-04 11:28:04 +01:00
pantor
9f923b3677 add check for too few arguments in operator parser 2022-07-10 13:46:33 +02:00
pantor
88bd611257 fix tests 2021-11-17 12:15:35 +01:00
pantor
b2c0dddafe improve lexing of numbers 2021-11-17 12:13:22 +01:00
pantor
eb04bfc7d3 clang-format 2021-11-12 08:35:56 +01:00
pantor
9b9dd96a46 introduce INJA_DATA_TYPE 2021-09-06 09:15:48 +02:00
pantor
4505fd0508 add tests for assignments 2021-09-01 10:29:52 +02:00
逐雁南飛
14f0d38cac Fixed an issue with round (#207)
* Fix the problem that the result has a decimal point when the round function, when the precision is 0.

* fix tests/test-functions.cpp:91 for round check
2021-07-01 07:59:00 +02:00
Wim Leflere
91c93bfb77 add join function (#204)
* add join function

* fix formatting to match single include

* add join test

* add join to documentation

* fix MSVC warning: signed/unsigned mismatch

Co-authored-by: Wim Leflere <wleflere@cochlear.com>
2021-06-17 20:54:22 +02:00
pantor
8d65633b6a add warnings for clang and fix them 2021-06-17 19:48:28 +02:00
pantor
4e909475ea at function for objects 2021-06-09 22:26:07 +02:00
pantor
eac2162629 fix include of in-memory templates 2021-05-17 20:44:32 +02:00
pantor
ca3c7a0cd6 add test for short circuit evaluation 2021-05-17 20:03:17 +02:00
pantor
9d59943220 add INJA_NOEXCEPTION 2021-01-16 18:06:43 +01:00
pantor
a3b0b41d48 allow variables starting with $ and @ 2021-01-16 16:40:03 +01:00
pantor
5f9d429a6a add void callbacks 2020-08-10 19:38:12 +02:00
pantor
a570837703 remove iostream header, update year 2020-08-08 11:14:49 +02:00
pantor
23e768403e add test for nested functions 2020-08-04 23:27:46 +02:00
DeiRex75
44c473538b Switched order in token::kind::id of function and operator behavior (#155)
* switched order in token::kind::id of function and operator behavior

* add tests

Co-authored-by: pantor <lars.berscheid@online.de>
2020-08-02 19:01:38 +02:00
pantor
7529f21e63 dont copy strings into textnodes 2020-07-26 13:13:05 +02:00
pantor
c56cbd63e9 add atid operation 2020-07-26 12:52:36 +02:00
pantor
f31378edaa slight changes 2020-07-13 21:17:59 +02:00
pantor
6eb71dd3ea Rewarite core with an AST for statements and RPN for expressions (#149)
* test

* improve ast

* add if statement

* shunting-yard start

* renderer as node visitor

* improve ast

* improve ast further

* first functions

* improve ast v3

* improve ast v4

* fix parser error location

* nested ifs

* fix comma, activate more tests

* fix line statements

* fix some more tests

* fix callbacks without arguments

* add json literal array and object

* use switch in expression

* fix default function

* fix loop data

* improved tests and benchmark

* fix minus numbers

* improve all

* fix warnings, optimizations

* fix callbacks argument order

* dont move loop parent

* a few more test

* fix clang-3

* fix pointers

* clean

* update single include
2020-07-13 15:20:04 +02:00