Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
元phperから見たGoの良いところ
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
chiroruxx
April 12, 2024
Technology
120
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
元phperから見たGoの良いところ
2024/04/11 Go Connect #0 で発表した資料です。
chiroruxx
April 12, 2024
More Decks by chiroruxx
See All by chiroruxx
Contextとはなにか
chiroruxx
1
450
初心者エンジニアから中級者エンジニアになるためにオススメの1冊
chiroruxx
0
140
Laravelのパッケージ全部紹介する
chiroruxx
2
150
Gopher のための「自由な話し合い」ワークショップ
chiroruxx
0
54
PHPをGoで動かす
chiroruxx
0
110
Goを使ってTDDを体験しよう!
chiroruxx
1
1.2k
今ならできる!PhpStormプラグイン開発
chiroruxx
0
120
Go Connectへの想い
chiroruxx
0
240
eBPF with PHPをさわる
chiroruxx
0
200
Other Decks in Technology
See All in Technology
[DroidKaigi 2026] Making UI specifications visible: Android UI development in the AI agent era supported by Compose Screenshot Testing and galleries
syarihu
0
520
『止めない』を設計する — 制約の中で、事業の根幹を支える判断
hiroyaterui
0
140
こんなアーキテクチャ図は嫌だ BEYOND THE TIME: 半年後の自分へ贈る15のメッセージ / 15 of Anti-pattern in AWS Architecture Diagrams
naospon
3
210
どんな手を使っても絶対間に合わせるスケジューラ
asari194617
0
1.5k
最新技術に積極チャレンジ!EKS共通基盤のこれまでとこれから
daitak
0
300
bet_ai_day_2026_session02
agenticsec
1
840
DINO-EdgeQuery:Edge-First Polygon Decoding for Building Footprint Extraction from Satellite Imagery
lehupa
0
140
魔法少女がClaude Codeを監視する / ccportal-deck
noriyukitakei
3
120
DGX Sparkを2台使って いろいろ動かす話
sonoda_mj
1
120
生成AI時代の クレデンシャルとパーミッション設計
nrinetcom
PRO
3
1.5k
[RSJ26] Building a VLA Model Based on Self-Distilled Classification
keio_smilab
PRO
0
180
Claude Codeで開発以外の業務も爆速化しよう!
minorun365
PRO
12
9.6k
Featured
See All Featured
The Hidden Cost of Media on the Web [PixelPalooza 2025]
tammyeverts
2
490
BBQ
matthewcrist
89
10k
Dominate Local Search Results - an insider guide to GBP, reviews, and Local SEO
greggifford
PRO
0
320
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
2
490
A designer walks into a library…
pauljervisheath
211
24k
svc-hook: hooking system calls on ARM64 by binary rewriting
retrage
2
550
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
240
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
690
The Anti-SEO Checklist Checklist. Pubcon Cyber Week
ryanjones
0
230
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
37
6.6k
Transcript
元phperから見た Goの良いところ 2024/04/11 Go Connect #0
自己紹介 ちひろ X: @chiroruxxxx 株式会社モリサワ 1年前に転職して
phperからgopherに
Goの良い ところ Goいいな!と思ったポイントを3つほど紹介したいと思います 思ったよりもあんまり・・・というところも紹介します
余談: 八方美人
いいな! と思ったポイント
多値返却・タプル代入
多値返却 タプル代入 Goの根幹を支える機能 多値を返したいことは多い PHPでは配列(マップ)で無理やり多値を返すコードも・・・ 乱用注意
ゼロ値
ゼロ値 便利すぎる nilチェック、デフォ値の設定など メインロジックと離れたコードを削れる Cmp.Or()でより価値が高まるか たまにバグのもとになる
遅延関数呼び出し
遅延関数 呼び出し defer が便利 関数切り出しのタイミングにもなる
思ったよりも・・・ なポイント
型
型 型による恩恵はさほど変わらず 現在のPHPは型のディストピア 少しでも緩い型を書くと静的解析に怒られる Goはジェネリクス・ユニオン・インターセクション型が限定的
今後に期待!
フォーマット
フォーマット 標準のフォーマッタがある(gofmt) プロジェクト横断で同じフォーマットでコードを読める!? ・・・という夢があった プロジェクトごとに違うgolangci-lintの設定
まとめ
まとめ 良かった! 多値返却・タプル代入 ゼロ値 遅延関数呼び出し
思ったよりも・・・ 型 フォーマット