没有合适的资源?快使用搜索试试~ 我知道了~
rubyspeed:将ruby函数编译为C
共15个文件
rb:6个
c:4个
gitignore:1个
需积分: 15 0 下载量 46 浏览量
2021-01-30
12:46:01
上传
评论
收藏 16KB ZIP 举报
温馨提示
Rubyspeed 工作正在进行中。 欢迎使用Rubyspeed。 现在,Rubyspeed是概念的基本证明(可怕地被一起使用),它允许注释方法声明自动进行专门化并编译为C。这是一个示例: require 'rubyspeed' class TestClass extend ( Rubyspeed :: Compiles ) compile! ( params : [ Rubyspeed :: T . array ( Rubyspeed :: T . int ) , Rubyspeed :: T . array ( Rubyspeed :: T . int ) ] , return_type : Rubyspeed :: T . int ) def self . dot ( a , b ) c = Rubyspeed :: Let . int ( 0 ) a . each_with_index do | a_val , idx | c += a_val * b [ idx ] end c end end 这将
资源推荐
资源详情
资源评论
收起资源包目录
rubyspeed-master.zip (15个子文件)
rubyspeed-master
fixtures
example_branch.c 737B
example_dot.c 859B
example_loop.c 776B
example_add.c 583B
bench
rubyspeed_bench.rb 874B
lib
rubyspeed
c.rb 9KB
inline.rb 11KB
rubyspeed.rb 2KB
.gitignore 66B
Gemfile 90B
Rakefile 536B
test
rubyspeed_test.rb 2KB
rubyspeed
c_test.rb 2KB
README.md 2KB
Gemfile.lock 727B
共 15 条
- 1
资源评论
weixin_42097189
- 粉丝: 38
- 资源: 4567
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功