Skip to content

Comments

[Feat] Parse functions#18

Merged
anhgelus merged 5 commits intomainfrom
feat/parse-functions
Jul 27, 2025
Merged

[Feat] Parse functions#18
anhgelus merged 5 commits intomainfrom
feat/parse-functions

Conversation

@anhgelus
Copy link
Member

Very naive simple implementation of parsing custom functions.

Create a new function with gomath.NewFunction(expr string) where expr follows this syntax:

arg1, arg2, arg3... -> expression

where expression is a valid math expression. It returns a new gomath.Function which can be valuated with a map describing every arg value to return a gomath.Result. It also returns the number of arguments.

@anhgelus anhgelus self-assigned this Jul 23, 2025
@anhgelus anhgelus added the enhancement New feature or request label Jul 23, 2025
@anhgelus anhgelus requested a review from leo-210 July 23, 2025 14:02
@anhgelus anhgelus moved this to In review in Nerdkord Jul 23, 2025
@anhgelus anhgelus merged commit 126b382 into main Jul 27, 2025
1 check passed
@anhgelus anhgelus deleted the feat/parse-functions branch July 27, 2025 16:27
@github-project-automation github-project-automation bot moved this from In review to Done in Nerdkord Jul 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants