Does Go have lambda expressions or anything similar?

前端 未结 6 1770
青春惊慌失措
青春惊慌失措 2020-12-08 03:36

Does Go support lambda expressions or anything similar?

I want to port a library from another language that uses lambda expressions (Ruby).

6条回答
  •  陌清茗
    陌清茗 (楼主)
    2020-12-08 04:13

    Yes, since it is a fully functional language, but has no fat arrow (=>) or thin arrow (->) as the usual lambda sign, and uses the func keyword for the sake of clarity and simplicity.

提交回复
热议问题