Giter Site home page Giter Site logo

wa-lang / wa Goto Github PK

View Code? Open in Web Editor NEW
730.0 21.0 51.0 10.83 MB

The Wa Programming Language: Simple, maintainable, compiled language for developing WebAssembly software

Home Page: https://wa-lang.github.io

License: GNU Affero General Public License v3.0

Go 78.88% Makefile 0.19% HTML 0.38% JavaScript 17.90% CSS 2.08% Yacc 0.06% Batchfile 0.01% Dockerfile 0.01% Witcher Script 0.35% AMPL 0.15%
programming-language wa language wa-lang wasm webassembly compiler

wa's People

Contributors

3dgen avatar benshi001 avatar chai2010 avatar codefromthecrypt avatar nobodxbodon avatar ohxxx avatar trueabc avatar wanglong001 avatar xiaochangbai avatar yanxingjushi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

wa's Issues

known bugs of the LLVM-IR backend

\" can not be printed, for example,

fn main() {
        print("ab\"c")
}

will lead to compile error like

@printfmt0 = private constant [5 x i8] c"ab"c\00"
                                       ^
**** failed to invoke LLVM ****
exit status 1

开发流程建议:是否采用PEP 文档驱动

开发流程建议:是否采用PEP 文档驱动

  1. 先提一个issue,
  2. 针对这个issue,写一个改进PEP文档
  3. 投票决定是否接受
  4. 对接受的文档,进行开发
  5. 提交代码审核
  6. 代码合并
  7. 文档标记完成

参见python的开发流程

年轻人,大有可为,加油干

发明编程语言绝非易事。
指望不上中科院那帮秀才了。

这几位年轻人,勇气可嘉。
希望你们不忘初心牢记使命,造出最好的编程语言。
不要怕,不要怂,就是干。
在茫茫编程语言的海洋里,杀出一条自己的路。

先是学习和模仿别人。然后再发明创造。

【占坑】pkg 管理工具

目前还没有参与过 pkg 管理工具的开发,有兴趣想尝试一下。
POC 有 roadmap/object 的话,请分享一下。

Known bugs of the LLVM-IR backend

Can not print strings with " . For example,

fn main {
        println("ab\"c")
}

leads to compile error

llc: error: llc: a.wa.ll:9:40: error: constant expression type mismatch
@printfmt0 = private constant [6 x i8] c"ab"c\0A\00"
                                       ^
**** failed to invoke LLVM ****
exit status 1

泛型?

未来是否有支持泛型的计划?

llvm 后端缺失的大特性列表

  1. string/slice/map 类型变量及相关运算(涉及堆管理);
  2. complex 类型变量及相关运算;
  3. 方法定义和调用;
  4. 接口类型定义;
  5. lambda 函数;
  6. print/println 只能打印部分标量类型,不能打印结构体/数组,不能打印 rune 类型(涉及字符编码问题);

类yaml语法风格能否加入?

纵观现代编程,类yaml格式的编程最符合人脑阅读习惯,比如前端用于编写html的pug语法、写css用的stylus、以及python语言,这些都是非常高效的编程风格。假如能在go语言这种简单关键字基础上融入yaml风格的编程,无疑会成为最受关注的语言。目前很多个括号{}看着不舒服,编写也一样

当然以上只是个人观点,也是对未来编程语言发展的个人看法。特别喜欢go,要是能去掉各种花括号,改为yaml格式,无疑是未来编程必走之路

官网评论区bug

没登录时,能显示评论框,但不能评论.

登录后,评论框变成了一组 json

image

二进制码中文版建议

[占坑]我建议凹语言的二进制码可以加个中文版,如:
1010011010
凸凹凸凹凹凸凸凹凸凹

MacOS无法安装

go install github.com/wa-lang/wa@latest

output

go/pkg/mod/github.com/wa-lang/[email protected]/internal/app/wabt_wat2wasm.go:15:2: //go:build comment without // +build comment
go/pkg/mod/github.com/tetratelabs/[email protected]/internal/engine/compiler/engine.go:12:2: //go:build comment without // +build comment
go/pkg/mod/github.com/tetratelabs/[email protected]/config.go:13:2: //go:build comment without // +build comment
go/pkg/mod/github.com/tetratelabs/[email protected]/internal/sys/sys.go:11:2: //go:build comment without // +build comment
go/pkg/mod/github.com/wa-lang/[email protected]/internal/backends/compiler_c/compile_const.go:8:2: //go:build comment without // +build comment

中文辅助插件

看到 补全辅助插件 ,个人之前打过一点下手。此插件的好处是,即便尚无vsc下的语言支持插件,此插件仍会按照纯字符串进行补全,关键词或标识符都是:
Screen Shot 2022-08-06 at 11 57 25 AM
Screen Shot 2022-08-06 at 11 57 45 AM

且此插件支持全拼之外的五笔等输入法。

另外,还有IntelliJ下类似插件: https://github.com/tuchg/ChinesePinyin-CodeCompletionHelper 。对了,IntelliJ系列IDE从2022版开始就已默认支持拼音缩写补全,无上面插件的效果如下:
Screen Shot 2022-08-06 at 12 02 16 PM

就我了解此补全插件需依赖ide的语言支持插件。

VS也有 类似插件

使用凹语言™创建一个网页应用

我看到你们的目标之一:使用凹语言™创建一个网页应用
是前端语言还是后端语言?还是前端语言都是?
现在后端语言琳琅满目,不过个人觉得要是做出前端语言来自然是更好

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.