# How to define Macro for a new Type?

**URL:** <https://forum.devtalk.com/t/how-to-define-macro-for-a-new-type/47300>\
**Category:** Backend Questions/Help\
**Tags:** elixir, types\
**Created:** [28 March 2022 09:09 UTC](https://forum.devtalk.com/t/how-to-define-macro-for-a-new-type/47300 "2022-03-28T09:09:17Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![OvermindDL1](https://forum.devtalk.com/user_avatar/forum.devtalk.com/overminddl1/32/52_2.png) [@OvermindDL1](https://forum.devtalk.com/u/OvermindDL1)\
**Post date:** [28 March 2022 18:34 UTC](https://forum.devtalk.com/t/how-to-define-macro-for-a-new-type/47300/3 "2022-03-28T18:34:19Z")

</div>

Elixir doesn’t really have type dispatch though as it has no static type system, so I’m unsure what any kind of NewType could accomplish with this short of just `{:mytype, values}` or so as the purpose of NewType’s are to specify a unique set of functionality while hiding the original functionality of a specific type.

---

_[View the full topic](https://forum.devtalk.com/t/how-to-define-macro-for-a-new-type/47300)._
