Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
hzhou321
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
17 ms
·
121.
▲
by
hzhou321
8y ago
Your mind is shrouded by your zealous emotion that you are handicapped in your perception. > What exactly is so confusing ... I can see you how you don't understand; unfortunately, you are having trouble understand the other way. &g
122.
▲
by
hzhou321
8y ago
> That ship already sailed ... That doesn't prevent launching a new ship. > and changing it now would just massively add to the confusion ... There are two types folks who care about Perl - both are in dwindling numbers. The old-
123.
▲
by
hzhou321
8y ago
> the point of a transpiled language isn’t for its output to necessarily be readable but first and foremost fast. You wouldnt expect c to produce understandable assembly in all cases, would you? I would like to argue about this philosoph
124.
▲
by
hzhou321
8y ago
I use my own simple email scripts with simple rules and it also works! Over the time, my system has become even simpler. I used to have Procmail as mda, now simply a 5 line Perl script. I used to have spamassissin as pre-filter, now I skipp
125.
▲
by
hzhou321
8y ago
It is a system that results in rich and poor, where rich are holding stakes and incentivized to maintain and grow their status and the poor are insignificant to do anything. Then there is the vast middle class who don't see the poor bu
126.
▲
by
hzhou321
8y ago
What I meant is more like: #define BUFSIZE 100 char buf[BUFSIZE+1] buf[BUFSIZE]=0 // for global var, it is already zeroed, right? Then one can call strncpy(buf, BUFSIZE, ...) without worrying about null-terminatio
127.
▲
by
hzhou321
8y ago
So you need a data structure (or language) that have size embedded in, and the knowledge (and restrictions) of that data structure need to spread to every libraries or function that one use (we are talking about string handling here). It ap
128.
▲
by
hzhou321
8y ago
I am not sure I follow the extent of the problem. With `strncpy`, the caller assumes the responsibility of buffer size (by specify that size explicitly every single time. I thought that responsibility is not being debated within the current
129.
▲
by
hzhou321
8y ago
If we preset the end of buffer with '\0' and then assume the buffer having 1-less capacity, wouldn't it address the strncpy issue?
130.
▲
by
hzhou321
8y ago
M4 is a general-purpose preprocessor. Its preprocessing ability focuses on the word level and it blends macros in appearance to the look of the target language on purpose. I especially having trouble with the latter. In editing, I would lik
131.
▲
by
hzhou321
8y ago
Just share with coworkers the C (or whichever) code that MyDef translated. MyDef is not a language, it only dresses the code. So if coworkers don't like to work with the dresses, simply remove the dress.
132.
▲
by
hzhou321
8y ago
Because when using MyDef, you are still thinking in the end language -- how the function, variable, type, stack works are all defined by the end language. With MyDef, you are just changing the way of expressing them -- just like giving crea
133.
▲
by
hzhou321
8y ago
Here is a direction if you are all ears : instead of a new language, add a new layer. I tried creating my own languages before, some 15 years ago. While I had fun writing compilers, I missed a lot more writing actual programs. One day I su
134.
▲
by
hzhou321
8y ago
While other comments suggest the solution is to implement the hash function based on field values, it throws away the simple, efficient, and general implementations of original memory based hash function. But if we understand the true sourc
135.
▲
by
hzhou321
8y ago
I would agree that "no paper is that good" -- on the first try or even the second try. Just as we need constantly refactor code, just as we need constantly re-edit a book, a paper that explains a scientific idea also needs constan
136.
▲
by
hzhou321
8y ago
The problem is in the semantics
137.
▲
by
hzhou321
8y ago
I have been noticing this effect as well, and I was thinking that there needs to be a change in how we design programming languages. The old programming languages are treating characters or words as atomic units, but human mind does not rea
138.
▲
by
hzhou321
8y ago
First, you can't go back to your twenties and you shouldn't try. When you are still in a school environment, there's an environment that for doing problems for problem's sake. For all you have trained so far, be able to
139.
▲
by
hzhou321
8y ago
Creating and maintain type system is also leg walk (and I was arguing it is a bigger burden of leg walk). And a Turing complete type system can have Turing complete errors. Let's not pretend we have silver bullet and have a fair discus
140.
▲
by
hzhou321
8y ago
The suggested type system adds a lot of code and complexity. For the specific case, I suggest we can try a convention-based solution. Let's, eg. establish a convention that all product id variable named with `prod_` prefix and customer
141.
▲
by
hzhou321
8y ago
> My uses of goto can be replaced with nested functions I guess you are not using goto as flow-control then.
142.
▲
by
hzhou321
8y ago
Rightly so. At this point seems China has all the condition but a necessary kick in the butt.
143.
▲
by
hzhou321
8y ago
Will I be able to find an exe download and fix my old PC?
144.
▲
by
hzhou321
8y ago
I lately do realize that to be comfortable with MyDef, one need be versed in three languages -- the language you are writing, MyDef, and Perl. People seem more welcome to the idea of having new language replacing the old rather than a solut
145.
▲
by
hzhou321
8y ago
Within a local context (where corner cases can be excluded) large parts of C/C++ can be simplified. Expand to a general context, I think too it is a fallacy. Even when in theory the compile time can determine all the types and ambiguit
146.
▲
by
hzhou321
8y ago
I use MyDef to achieve most of features `cpy` is trying to introduce: # t.def page: t, basic_frame module: c a=10 b=a $dump a, b $ mydef_run t.def PAGE: t --> [./t.c] gcc
147.
▲
by
hzhou321
8y ago
The number one reason for me to use vim is also to be able to use it in a terminal. The number one reason for a terminal is to have a consistent current directory. When I double click gvim, I immediately lost. I guess you could launch edito
148.
▲
by
hzhou321
9y ago
According to the article, xz minus extensibility.
149.
▲
by
hzhou321
9y ago
I was thinking the same thing (I guess) as I read that comment: If one is going to worry about the limited choice of books for the rest of his lifetime, he should simply just read. Similarly, if one is worrying about limited time with their
150.
▲
MyDef, a general preprocessor
(hz2.org)
1 points
by
hzhou321
9y ago
|
0 comments
More ›