並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 30 件 / 30件

新着順 人気順

Rustの検索結果1 - 30 件 / 30件

  • プライベートでMac使うのやめた

    最近、自分のプライベートの開発環境を大きく変えたので紹介する。 先にまとめ プライベートではMacを使わなくなった 家にUbuntuが入ったミニPCを置いた 外からはThinkPad X1 CarbonからTailscale経由のSSHで家のミニPCに接続 購入まで まず、自分にとって最も大きな変化はプライベートでMacを使わなくなったことだ。2013年くらいにプログラミングを始めてからずっとメインのOSはMacだったので、約10年ぶり、ほぼ初めての非Mac環境である。 自分の普段の開発のユースケースは、Webアプリケーション開発とNode.js上で動くソフトウェアの開発、WebKitへのコントリビューション、たまにRustやGoやC/C++で自分専用ツールの開発、くらいなので別にMacで困っているわけではなかった。Web開発やNode.js上のソフトウェアの開発はまあ普通にMacで困らな

      プライベートでMac使うのやめた
    • pyenvを初心者に薦めるのはもうやめよう - methaneのブログ

      Pythonのパッケージ・プロジェクト管理ツールはまだ乱立状態にあって、どれを使えばいいのかわからないから慣れたpyenv+pipを使おうという判断をする人がいるかもしれない。その判断自体は別に否定しないけれども、初心者に教える時にpyenvを教えるのはもうそろそろやめてほしい。 Pythonをソースからビルドするので、コンパイラや依存ライブラリを事前に揃えないといけない。依存ライブラリが足りないと中途半端なPython環境もできうる。 デフォルトで最適化オプション(PGO+LTO)が付いてないので、最適化ビルドしたPythonより~5%程度遅い Windowsで使えない Rye, pdm, Hatch などは python-build-standalone と呼ばれるビルド済みPythonをインストールする機能があるので、これらの欠点が存在しない。 Pythonをインストールするところま

        pyenvを初心者に薦めるのはもうやめよう - methaneのブログ
      • RustでAPIサーバーを書くのが思ったより良い

        最近いろんなところで採用事例が増えてきたRustですが、Webサービス開発でのAPIサーバーを書くのにRustは向いてないと言われたりします。Rustの第一のターゲットはシステムプログラミングでありGCがないためAPIサーバー開発でシビアなメモリ管理はしたくないというのは一理あるのですが、RustでAPIサーバーの開発を実際にやってみるとむしろ開発体験が結構いいなと感じます。パフォーマンスのために難しい所有権を無理にがんばるみたいなマイナスのイメージはほとんど当てはまらなかったです。 Rustの難しいライフタイム、所有権があまり出てこない Rustにおいて難しいとされるライフタイム、所有権といった概念があり私も書く前はかなり身構えていたのですが、これに苦しむことは思ったよりも少ないです。その要因はWebサーバーで扱う処理のほとんどがリクエスト・レスポンスモデルでデータの流れが一方向でシンプ

          RustでAPIサーバーを書くのが思ったより良い
        • 個人開発OSSが世界に勝てなかった話

          ゆーすけべー氏の「OSSで世界と戦うために」にインスパイアされました。5年間pyserdeというOSSのライブラリを開発・メンテしてきた筆者が、ちょっとだけ世界と戦ってみたけど全然勝てなかったという話です。Honoとはプロダクトの規模も開発にかける情熱も全然違うけど、単純にポストモーテムは読み物として面白いかなと思ったので書いてみます。また、5年間の開発で学んだやってよかったことや失敗などもシェアできればと思います。 pyserde pyserdeは筆者が2019年から開発メンテナンスしているOSSで、RustのserdeというライブラリにインスパイアされたPython用のシリアライゼーションフレームワークです。 以下のようにクラスを定義すると、型アノテーションに基づいたデータ変換やバリデーションのコードが内部的に生成され、強い型付けのクラスを生成することができます。強い型付けのクラスはラ

            個人開発OSSが世界に勝てなかった話
          • Rust言語のための統合開発環境「RustRover」正式リリース、JetBrains。個人の非商用利用は無料

            Rust言語のための統合開発環境「RustRover」正式リリース、JetBrains。個人の非商用利用は無料 Kotlin言語や統合開発ツールIntelliJ IDEAなどの開発を行っているJetBrainsは、Rust言語用の統合開発環境「RustRover」の正式リリースを発表しました。 All systems are GO! We’re over the moon to see RustRover finally land! Read all about the release and the new free non-commercial license in our blog post https://t.co/s3MnqfiTrs, and see how we can help you stay focused on what matters pic.twitter.com

              Rust言語のための統合開発環境「RustRover」正式リリース、JetBrains。個人の非商用利用は無料
            • Rustのデータ可視化ライブラリCharmingに入門した

              Charmingとは Charmingは、Rustの強力なチャートレンダリングライブラリです.美しく高品質なデータ可視化します.GitHub上で以下のようなグラフが紹介されています. 後述しますが,このCrateは適切にStructが分割されているので,可読性の高い可視化用のコードを作ることができます. 簡単に散布図を作成する Datasaurusのデータを使います.ここでは,csvファイルをダウンロードして使っています. もちろん表示するのはdinoです. この記事では,cargo new project_nameした後に,data dirとoutput dirを作っていることを想定します.

                Rustのデータ可視化ライブラリCharmingに入門した
              • Rust製JavaScriptエンジン『Boa JS』を試してみた

                主要なJavaScriptエンジンのTest262を毎日実行して結果を載せているtest262.fyiというサイトがあります。 (Test262とは最新のECMAScriptを実装できているかどうかのテストです。) このサイトの、2024/6/5現在の実装率ランキングはこちらです。 test262.fyiの画面キャプチャ(2024/6/5) V8(ChromeやNode.js、Deno等)、JavaScriptCore(SafariやBun等)、SpiderMonkey(Firefox等)という、大手エンジンとほぼ横並びで4位に食い込んでいるBoaとは何者でしょうか。 Boaは公式曰く『Rustで書かれた実験的なJavascriptのレキサー、パーサー、コンパイラー』です。これだけ揃えば、JavaScriptエンジンと言って差し支えないと思います。RustアプリケーションにJavaScri

                  Rust製JavaScriptエンジン『Boa JS』を試してみた
                • 【v6プラス/OCNバーチャルコネクトでもNATタイプA】LinuxでポートセービングIPマスカレード付きの制限コーン風NAT(EIM/ADF)を動かす - turgenev’s blog

                  概要 NAT動作をめぐる誤解まとめ - turgenev’s blogでは、UDPホールパンチングのしやすさとポートの節約を両立するには「Address Dependentなマッピングを保持しつつEIM風に動作するADFなNAT」が一番いいという話を書きました。これだとv6プラスやOCNバーチャルコネクトでもNintendo SwitchのNAT判定が「タイプA」になります。 この記事では、Symmetric NAT/Full Cone NATをサポートするruby製NATであるrat(GitHub - kazuho/rat: NAT written in pure ruby)を手元で動かし、またコードを少しだけ変更することで上記のようなNATを実際に動作させるところまでを紹介します。変更後のコードはGitHub - ge9/rat: NAT written in pure rubyに公開

                    【v6プラス/OCNバーチャルコネクトでもNATタイプA】LinuxでポートセービングIPマスカレード付きの制限コーン風NAT(EIM/ADF)を動かす - turgenev’s blog
                  • Taming Floating-Point Sums | orlp.net

                    Suppose you have an array of floating-point numbers, and wish to sum them. You might naively think you can simply add them, e.g. in Rust: fn naive_sum(arr: &[f32]) -> f32 { let mut out = 0.0; for x in arr { out += *x; } out } This however can easily result in an arbitrarily large accumulated error. Let’s try it out: naive_sum(&vec![1.0; 1_000_000]) = 1000000.0 naive_sum(&vec![1.0; 10_000_000]) = 1

                    • Writing an OS in 1,000 Lines を Rust でやってみた

                      1000行でOSをつくってみる Writing an OS in 1,000 Lines という1000行前後でOSをつくれるコンテンツがあります。 このコンテンツ自体はC言語を前提としているのですが、Rustでもシステムプログラミングが可能なので、今回はRustで挑戦してみました。 Rust で Writing an OS in 1,000 Lines をやってみるときのポイントをまとめておきます。 RISC-V このコンテンツでは RISC-V をターゲットアーキテクチャとしていて、RISC-V のOSを開発します。 RISC-V はオープンソースのRISC (Reduced Instruction Set Computer) のISA (命令セットアーキテクチャ) です。 詳しい説明は、RISC-V で検索すれば数多くヒットします。 この RISC-V 関連で、参考にした主な情報源は

                        Writing an OS in 1,000 Lines を Rust でやってみた
                      • Exploring Seamless Rust Interop for Newer Languages, Part 1

                        Exploring Seamless Rust Interop for Newer Languages, Part 1 Languages like C++, Typescript, Kotlin, and Swift had a brilliant approach: they were created to harness an existing ecosystem of libraries from another pre-existing language. But that's easier said than done! Especially for newer languages focusing on memory safety and speed. 0 Luckily, newer languages can tap into C's ecosystem by addin

                        • Linux 6.10‐rc1リリース、RustやMilk-V MarsなどRISC-Vサポートが拡大 | gihyo.jp

                          Linux Daily Topics Linux 6.10‐rc1リリース⁠⁠、RustやMilk-V MarsなどRISC-Vサポートが拡大 Linus Torvaldsは5月26日(米国時間⁠)⁠、次期Linuxカーネル「Linux 6.10」の最初のリリース候補版となる「Linux 6.10-rc1」を公開した。Linusは「通常サイズのカーネルリリースに見えるが、少し小さいかもしれない。(⁠Linux 6.10には)新しいファイルシステムはなく、xfsのオンライン修正により、bcachefsの修正はもはや最大のファイルシステム変更ではない」とコメントしている。 Linux 6.10-rc1 -Linus Torvalds Linux 6.10では多くのアップデートが予定されているが、その中でも注目されるのがRISC-Vに関連したサポートの拡張だ。5月22日付けで行われたマージでは、

                            Linux 6.10‐rc1リリース、RustやMilk-V MarsなどRISC-Vサポートが拡大 | gihyo.jp
                          • GitHub - letmutex/htmd: A turndown.js inspired HTML to Markdown converter for Rust

                            You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert

                              GitHub - letmutex/htmd: A turndown.js inspired HTML to Markdown converter for Rust
                            • 【今週水曜開催】Rust / WebAssemblyの最新動向をエキスパートが語る!TechFeed Experts Night#30 〜 Rust / WebAssembly最前線

                              日本有数のエキスパートエンジニアとともに、最先端技術を掘り下げる「TechFeed Experts Night」、今回のテーマは「<strong>Rust / WebAssembly最前線</strong>」です。 こんにちは、テックフィード白石です。 日本有数のエキスパートエンジニアとともに、最先端技術を掘り下げる「TechFeed Experts Night」、今回のテーマは「Rust / WebAssembly最前線」です。 高速性と安全性、そしてモダンな言語仕様を兼ね備えるプログラミング言語「Rust」。Webブラウザのみならずサーバーサイドや仮想化/コンテナ技術、エッジコンピューティングに至るまで、活用事例が広がりつつあるWebAssembly。そしてRustは、WebAssembly開発における主要な言語としても注目されています。今回はそんなRust / WebAssembly

                                【今週水曜開催】Rust / WebAssemblyの最新動向をエキスパートが語る!TechFeed Experts Night#30 〜 Rust / WebAssembly最前線
                              • Rust製ツールのmiseでランタイムバージョンを管理する|Taro Yamashita

                                アキッパの山下です。 手元の環境を汚さずに、PHP/Python/Node.jsなどのランタイムバージョンを切り替えたいというニーズでは、Dockerの利用がすっかり主流だと思いますが、シーンによってはPythonのvenvといったツールもまだまだ活躍するシーンは多いのではないでしょうか。 そんなツールの中で、今回はRust製ツールのmiseを紹介します。 ランタイムバージョン管理とは?あらためて、ITシステムやWebサービスを開発・運用していく場合、どのプログラミング言語で構築されているか?だけでなく、そのバージョンは?も重要なポイントです。 稼動しているサーバにインストールされている言語バージョンと、手元の開発環境でバージョンが異なれば、手元で動くのにサーバで動かない(あるいはその逆)が往々にして起こります。 開発環境にサーバと同じバージョンをインストールすれば良いのですが、サーバAで

                                  Rust製ツールのmiseでランタイムバージョンを管理する|Taro Yamashita
                                • Rust製TypeScript Linterにおける型情報Lintルールの模索

                                  Rust製TypeScript LinterであるBiome, Oxc, deno_lintなどは、TypeScriptの型情報を利用するLintルール(型情報Lintルール)[1]を持っていません。本記事では、その背景から、Rust製TypeScript Linterが型情報Lintルールを実現するための手段についてまとめます。 筆者のTSKaigi 2024で利用した下記登壇資料に情報を追加し、文章化したものです。 要約すると、以下になります。 Rust製TypeScript Linterは、安全性をさらに高めてくれるtypescript-eslintの型情報Lintルールが欲しいが、パフォーマンスを犠牲にしたくない。TypeScript Compilerに頼らずに実現するには、Alternative TypeScript Compilerや型推論が必要。型情報Lintルールの実装を型

                                    Rust製TypeScript Linterにおける型情報Lintルールの模索
                                  • Send & Mutex – Cryptical

                                    I saw a question on Reddit, that asks: “why T needs to be Send in order to Mutex<T> to be Sync?”. I think that’s a great question, and in here I’ll try my best to shine some light on that. Send & Sync (intro) These are two marker traits (or auto-traits) implemented automatically by the compiler, that are very important for coding in Rust. They indicate that a type is safe to use (access) between t

                                    • GitHub - polachok/helix-gpui: helix gpui frontend

                                      You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert

                                        GitHub - polachok/helix-gpui: helix gpui frontend
                                      • The borrow checker within · baby steps

                                        This blog is where I post up various half-baked ideas that I have. All PostsCategoriesGitHubTwitterRSS/Atom feeds This post lays out a 4-part roadmap for the borrow checker that I call “the borrow checker within”. These changes are meant to help Rust become a better version of itself, enabling patterns of code which feel like they fit within Rust’s spirit, but run afoul of the letter of its law. I

                                        • WebAssembly・PWAの習作アプリを作成して感じたこと

                                          はじめに この記事では、個人の習作としてwasm-image-resizerという簡易な画像リサイズ・フォーマット変換ツールをWebAssembly + PWA + Reactで作成したので、そのときに私の得た知見を記載したいと思います。 アプリとしては実に単純であんまり面白みもないのですが、半ばちょっとした好奇心と勢いで自分なりに作ってみました。手探りで拙いですが、ソースコードは以下に配布していますので、よかったら見てみてください。 アプリの技術目標 このアプリを通して私が考えた技術目標は以下のとおりです。 フロントエンドとしては言語はTypeScript、Viteをベースにする UIのフレームワークとしてReactを使用 画像変換などのアプリでやりたいコアな処理はRustで記述 wasm-bindgenとwasm-packでWebAssembly化・javascriptパッケージ化を行

                                            WebAssembly・PWAの習作アプリを作成して感じたこと
                                          • Claiming, auto and otherwise · baby steps

                                            This blog is where I post up various half-baked ideas that I have. All PostsCategoriesGitHubTwitterRSS/Atom feeds This blog post proposes adding a third trait, Claim, that would live alongside Copy and Clone. The goal of this trait is to improve Rust’s existing split, where types are categorized as either Copy (for “plain old data”1 that is safe to memcpy) and Clone (for types that require executi

                                            • Announcing Rust 1.79.0 | Rust Blog

                                              The Rust team is happy to announce a new version of Rust, 1.79.0. Rust is a programming language empowering everyone to build reliable and efficient software. If you have a previous version of Rust installed via rustup, you can get 1.79.0 with: $ rustup update stable If you don't have it already, you can get rustup from the appropriate page on our website, and check out the detailed release notes

                                                Announcing Rust 1.79.0 | Rust Blog
                                              • IPC in Rust - a Ping Pong Comparison

                                                I wanted to explore different ways of communicating between different processes executing on the same machine, and doing so as fast as possible. We're focussing on high speed inter-process communication (IPC), but some of these approaches can be extended across a network. We'll do this exploration in Rust. A reminder that since these are independent processes, most approaches you'd take within-pro

                                                • Notion – The all-in-one workspace for your notes, tasks, wikis, and databases.

                                                  A new tool that blends your everyday work apps into one. It's the all-in-one workspace for you and your team

                                                    Notion – The all-in-one workspace for your notes, tasks, wikis, and databases.
                                                  • 999 crates of Rust on the wall

                                                    tl;dr I’ve been comparing crates on crates.io against their upstream repositories in an effect to detect (and, ultimately, help prevent) supply chain attacks like the xz backdoor1, where the code published in a package doesn’t match the code in its repository. The results of these comparisons for the most popular 9992 crates by download count are now available. These come with a bunch of caveats t

                                                    • rust is not about memory safety

                                                      01 june, 2024 most of rust discussions nowadays revolve around memory safety, and how it is safer than C / C++ / zig / go / whatever language is being trashed on twitter that day. while yes, that is true - not that the bar for most of these is particularly high - what I think is the main point of the language is always glossed over: correctness. when one tries to criticize any of the aforementione

                                                        rust is not about memory safety
                                                      • Rust and dynamically-sized thin pointers

                                                        One of Rust's notable differences from C is its requirement that all values have a defined size, which enables runtime bounds-checking and advanced static analysis tooling such as MIRI. For dynamically-sized types (DSTs) this requirement is implemented using thick pointers, such that each pointer to a dynamically-sized value is an (address, size) tuple. Thick pointers are more convenient and easie

                                                        • Rust is for the Engine, Not the Game - Barrett's Club

                                                          Last updated on June 6, 2024. Rust is for the Engine, Not the Game Macros are cool! But, if we're going to create another language anyways... LogLog Games recently posted Leaving Rust gamedev after 3 years, a must-read article for folks who're doing game development in Rust. It focuses on a small indie developer organization and their experiences with Rust development. If you haven't given it a re

                                                            Rust is for the Engine, Not the Game - Barrett's Club
                                                          • Enter paradis — A new chapter in Rust's parallelism story | Andreas Longva

                                                            Rust is a great language for data-parallel problems with relatively simple parallel access patterns. It particularly excels when the data can be split up into contiguous chunks. On the other hand, things can get messy for parallel access patterns that are non-contiguous or less structured. In this post, I will show you an uglier side of parallelism in Rust. Thankfully, it is not a fundamental flaw

                                                            • How to build a plugin system in Rust

                                                              How to build a plugin system in RustMay 29, 2024Software used by businesses often needs to be extensible. For Arroyo, a real-time SQL engine, that means supporting user-defined functions (UDFs). But how can we support dynamic, user-written code in a static language like Rust? This post dives deep into the technical details of building a dynamically-linked, FFI-based plugin system in Rust. Arroyo i

                                                                How to build a plugin system in Rust
                                                              1