# @pure function attribute

**URL:** <https://forums.swift.org/t/pure-function-attribute/34907>\
**Category:** Pitches\
**Created:** [March 29, 2020, 12:57pm UTC](https://forums.swift.org/t/pure-function-attribute/34907 "2020-03-29T12:57:21Z")\
**Posts on this page:** 1\
**Showing post:** 10

<div class="post-metadata">

**Author:** ![xwu](https://avatars.discourse-cdn.com/v4/letter/x/b487fb/32.png) [@xwu](https://forums.swift.org/u/xwu)\
**Post date:** [March 29, 2020, 5:11pm UTC](https://forums.swift.org/t/pure-function-attribute/34907/10 "2020-03-29T17:11:47Z")

</div>

You and I have had this exact conversation before:

> [@Add \`filter\` and \`ifSome(then:)\` to Optional](https://forums.swift.org/t/add-filter-and-ifsome-then-to-optional/8143/12):
>
> It's true that map is borrowed from functional programming, but Swift has no concept of 'pure' functions and has never made such a requirement for map. The Swift Programming Language itself has (or at least, one of its editions once had) an example of map(print), so I think it's fair to say that such usage is 'idiomatic' Swift.

---

_[View the full topic](https://forums.swift.org/t/pure-function-attribute/34907)._
