Taine Zhao
Taine Zhao
这儿插句话。 你们有看过布鲁兔子在知乎上的文章吗?我认为那个非常有意思,但不知这里各位是什么观点。建议各位去看一下,尤其是打算设计语法的那些人。 个人认为中文编程,若非走极简洁路线(J语言),不太有竞争力。 关键字替换还是免了。 vczh那个无空格方案,是需要括号的,这个不舒服。所以个人觉得他那里最有意思的观点还是token, unicode码的单字符token,然后多字符的标识符用一个特殊记号括起来,比如[...],`...`。 2017年10月15日 下午11:26,farteryhr 写道: 发声在这里发就好,不建议在那里吼,那儿已经没啥讨论环境了。 多做,而且把一步做完整,不管这一步多小。 盯死一个语言的核心语法bnf,掏出antlr做一个完全对应中文版,中文parse ast生成对应语言代码,我觉得都是很好的成果。 关键字完了就是库,这更是要耗时耗力做的,再怎么bb都没用。 觉得可行的方法还是,尽快脑补确立一个标识符多语言标注语法(带输入hint的)来吧,就先扔到注释里,不管ide、输入怎么做,让有志于翻译而没那么强程序能力的人可以有个标准,去开始翻译。 — You are receiving this because you were mentioned. Reply to this email directly, view...
Your explanation is pretty neat, and I think `jl._jl_raw()` is extractly what I need. Actually, I'm always thinking about such a thing when using juliacall. Checking the functionality of `jl._jl_raw`,...
Okay, considering this feature. It's not difficult to add, but I hope to see some use cases. Tuples are after all heterogeneous data, if you want to dynamically slice a...
Yes, using generated functions can enable many advanced things without a performance cost, however it seems impossible for MLStyle to generate generated functions... I hope the generated code from MLStyle...
This is really impressive. I think I can do this in MLStyle. I'll implement it before the next patch release.
Some hints if you want to implement it before I make actions. Feel free to ask me anything on slack if you have questions/problems.. https://github.com/thautwarm/MLStyle.jl/blob/8bba7028879a2f37774af1d919859dfb4bda83a5/src/MatchImpl.jl#L196 tuple pattern: https://github.com/thautwarm/MLStyle.jl/blob/8bba7028879a2f37774af1d919859dfb4bda83a5/src/AbstractPatterns/impl/BasicPatterns.jl#L102 vector slurping...
documentation for active patterns (`@active`) is out-of-date while deprecation warning is up-to-date
```julia julia> @active F(x) begin if x > 0 nothing else :ok end end julia> julia> @match -1 begin F(:ok) => false _ => true end # true ERROR: invalid...
Hello! My style of ast manipulation comes from such a point of view: macros are just functions, each of which map an AST to another AST. > For things like...
I'll give you some examples later. These days my schedule just gets burned(I mean quite busy and urgent), and sorry for my late reply.
I think `@λ` is similar to what you want: https://thautwarm.github.io/MLStyle.jl/latest/syntax/pattern-function.html It does not have an easier-to-type shortcut if you do not use julia REPL or julia editor plugins.