3 ms·
I like the premise of embedded generating inline c. Kinda like php for c, rather than html I'm not sure of custom BNF per generating command. I notice they're
by tsegratis 4y ago
I like the premise of embedded generating inline c. Kinda like php for c, rather than html
I'm not sure of custom BNF per generating command. I notice they're mostly order independent, which makes it a little easier to learn, but what's the advantage over c syntax? Is it roughly that pointers etc are impossible. Maybe a c-esque syntax would be more learnable
How does the existing syntax compose, i.e. can the user run away with writing tcl-style scripts
If you don't get a lot of feedback, I would guess it is inpart due to custom syntax being an entry barrier to understanding
I don't know, I think html is easy, so people want power with php. On the other hand for an audience that is using c, by the time I'm doing that, does Vely's custom syntax give me more than a set of convenient c library calls... such as https://kristaps.bsd.lv/kcgi/ https://kristaps.bsd.lv/kcgi/
In any case, I like the apis, and aim, and I think the premise has legs
- tsegratis 4y agoMaybe, rather than php, a "reactjs for c" is the direction you're heading
- dsvr 4y agoInteresting thought. Yes, it makes writing applications, easier, it inherits the top performance of C, it's got a lot of rich functionality. Vely is also a thin framework that mostly helps with building apps by not having to write Makefile, it will pickup any .v files you got. And it will generate a dispatcher for requests. But the framework doesn't do much, only the essentials, and that's by design. After all, C is all about flexibility, and that stays.
- dsvr 4y agoThanks for the feedback. The clauses in statements are not order dependent, so they can be specified in any order. No need to remember what goes where, just splatter your thoughts out. Vely is meant to be more human-readable than APIs; it leans more declarative than API. Each statement typically does what a number of C API calls would do, so the idea is to save time by saying what you need done rather than placing a number of API calls. At the same time, it's safer because it handles all the details and has a memory garbage collector. For instance, web-call does all kinds of GET and POST calls. run-query does SQL queries. write-string composes complex strings. Etc. Vely is also a thin framework. You can fire up FastCGI application server in minutes, and use the same program to run a command-line program.
- dsvr 4y agoI looked at kcgi and it's pretty cool for CGI/FastCGI if you want a-la-carte and then you use separate libraries for everything else. Vely has FastCGI built in by default (you can start FastCGI server in seconds with vv/vf), and the output statements (such as @ or p-out) do output to the web (i.e. to the Apache or Nginx reverse proxy) by default. So you could say in terms of functionality, kcgi is built into Vely transparently. In terms of additional functionality beyond kcgi, Vely offers - web constructs (getting input parameters from GET/POST, uploading files, sending files to client with send-file, cookie handling, output to web etc.), - safer and easier string manipulation, - database access (mariadb, mysql, postgresql, sqlite) with prepared statements and persistent connections, - regex (match-pattern), - exec-program for executing programs, - file operations, - encryption/encoding/hashing. I agree there's a learning curve. I can't say how would people see that, though the idea is to be easier than a traditional API, simply on the account of writing a single statement instead of say 5-10 C API calls.