Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

なでしこにRubyの面白い構文とりいれたい件 #1688

Open
kujirahand opened this issue Jul 2, 2024 · 0 comments
Open

なでしこにRubyの面白い構文とりいれたい件 #1688

kujirahand opened this issue Jul 2, 2024 · 0 comments

Comments

@kujirahand
Copy link
Owner

https://gihyo.jp/book/pickup/2022/0007 から抜粋して

  • メソッドの呼び出しの丸かっこが省略できる ... なでしこなら既にできている
  • 数値やnilもすべてオブジェクト
  • if文が値を返す ... これやりたい
  • メソッドの戻り値にreturnを付けなくても良い ... なでしこなら、既にできている
  • エイリアスメソッドが定義されていることがある
  • 配列の添え字に負の値が使える ... 実装したい
  • ループ処理にはeachメソッドとブロックを使う
  • スクリプト言語なのに静的型検査ができる
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant