-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Goals for v0.1 #12
Comments
Yeah, once we have a list of things to complete before
Yeah, although I think we should try and support at least one lower level language before Here are a few things to consider
We will have to also come up with an installer of sorts. |
That might be a good idea to actually show of what the point of this programming language is :)
I'm not sure how
I think we should start with publishing this on crates.io so people can just install this by running: cargo install talpalang
# or
cargo install talpa (cargo install compiles a binary from source to |
Also i think we should start thinking about how a "talpa" project should look like. If we want to keep things simple i think we should have something like a talpa project folder with the talpa files and a target folder we compile to using something like Because we compile into many languages i think most people would like to separate this code base from the rest of the code so most people will put talpa code in a separate git folder.
but again this is a really long command. Like many other languages we could maybe also add some sort of config to the target like: # Talpa.toml
[package]
location = "github.com/talpalang/talpa"
lang = "js"
version = "v2.1.0" This way we can just do something like |
Go could work for a second language as it does compile into a binary. As we are going to eventually need support for C/C++ I am going to try and learn a bit in my spare time.
I imagine that in the language support library, we would include an option for extra-build commands (such as
Yeah, I guess it provides a nice installation. I would want to look for other options in the future to remove
There are a few ways of doing this. You could go with a loose layout where it just compiles
I think something like
I like this idea a lot. It would also help us when we start building Talpa example libraries.
Like I state above, something like a Something like this could work: [package]
name = "hello-world" # package name
version = "0.1.0" # version of package
target = "src/" # target file defaults to main.tp but "src/start.tp" could also be a valid argument
output = "debug/js/" # output folder
lang = "js" # target language
[dependancies]
math = "https://github.com/talpalang/mathlib" # could maybe target .git file instead? You would then run If we used |
Quick note. EDIT: Actually I noticed this. It seems you've closed it, but I think that it could be a good alternative to the task list. What do you think? |
Ya i was trying some things out but closed it because we already had the todo list in the readme. |
I've filled the tasks list with things we need to do for About the configuration file..
For the repo with talpa code i prefer not to have a configuration file but i think we eventually probably need to if we want to do dependencies properly. In npm the Talking about things that are designed to be used this way, Cargo.. rusts it's package manager. # Talpa.toml
[dependancies]
math = "talpalang/mathlib" # shotcut for: github.com/talpalang/mathlib
math = "github.com/talpalang/mathlib" # Imports from a specific repo Now about the target. # Talpa.toml
[package]
location = "github.com/talpalang/talpa"
lang = "js"
version = "v2.1.0" Using this config it's very clear to an user what talpa does when you run |
Yeah, I think a Also, we may want to consider the ability to compile into multiple languages from the start. Even though we only support one so far, in the future people may wish to compile into several languages. |
Wired.. it works perfectly everywhere where i've installed rust via https://www.rust-lang.org/tools/install
Yes true.
and it can be all these using something like: talpa build ./* |
Yeah, I keep getting errors when it updates the index, I've tried half a dozen solutions but nothing works. I even tried a fresh install on another computer and that also failed.
Yeah, that looks good. |
Maybe we should create an example repository that contains a working talpa project? |
We should probably have that! |
Yeah, that makes sense |
By the way, I was about to start adding support for Go, but I can't access a return type. Has this been implemented yet or am I getting ahead? |
Return type should be implemented it might be though that the struct / fields are private. |
Ok, thanks. I’ll have a look :-) |
Looking at lines 8: pub struct Function {
9: pub name: Option<String>,
10: pub args: Vec<(String, Type)>,
11: pub body: Actions,
12: } |
This return type you mean right? For the struct itself it's located here: |
Not quite. I mean the type of the data returned by a function. The bit between the arguments and the scope. fn do_something() RETURN_TYPE {
} |
Oh you mean that.. |
Great. I've began work on Go support in the golang branch. I figure it's best to keep it seperate until it has a good enough support and passes all checks. |
Now we are making some good progress it might be a good idea to add checkboxes to the readme for all the things we want for the v0.1 release.
I guess we should start with a v0.1 because we only have support for 1 target language.
Some things i think we should definitely have:
The text was updated successfully, but these errors were encountered: