I had a 2am idea and when I looked it up I couldn't find any mention of someone else thinking of it. Here it is:
Function currying is a method for saving arguments on the callstack so they don't have to be copied in memory between calls. Here's a javascript example of currying:
```js const add = (leftOp) => (rightOp) => leftOp + rightOp; const addThree = add(3); console.log(addThree(4)); // 7 console.log(addThree(-2)); // 1 ```
I think all PL that support the "putting-functions-in-variables" paradime can do this. BUT. If you try to call a normal function that requires all of its arguments up front without all the arguments it will throw an error. So what if it didn't? What if instead of throwing an error, the function call returns a curried function with the first arguments filled and the unfilled arguments left to be inputted.
```js // with autocurrying const add = (leftOp, rightOp) => leftOp + rightOp; const addFive = add(5); // addFive is defined like addFive = (rightOp) => 5 + rightOp console.log(addFive(3)); // 8 ```
This could work in Javascript(/Typescript), Python, Go and similar languages. By encouraging currying you could potentaily get memory saving, readibility, and performance. But I won't ever try to sell you a stack of pros without a foundation of cons: any syntax sugar has the potential to cause logic bugs, reference bugs, and missuse.
What do you guys think?
1. Each user can login with a username and pass
2. User can see all the tables in the database
3. User can edit each column of each row
4. Basic searching&filtering would be nice
It doesn't need to be pretty, but it's gotta be intuitive. Also I don't want to have to configure anything, just the username and password for postgres and it works.
I've already explored pgAdmin and pgweb but they were both too technical. I'm also kinda new to the corporate world so google isn't showing me ads for these kinds of things yet.
Thoughts?
The correct solution for me is to get my eyes lasered, but thats expensive, dangerous, and involves a recovery period.
I don't mind wearing my glasses all day. I just wanted to ask if someone knew a better way?