# Allowing the object.method(args...) syntax as an alias for method(object, args ...)

**URL:** <https://discourse.julialang.org/t/allowing-the-object-method-args-syntax-as-an-alias-for-method-object-args/62051>\
**Category:** Internals & Design\
**Tags:** question, design\
**Created:** [May 29, 2021, 5:09pm UTC](https://discourse.julialang.org/t/allowing-the-object-method-args-syntax-as-an-alias-for-method-object-args/62051 "2021-05-29T17:09:54Z")\
**Posts on this page:** 1\
**Showing post:** 55

<div class="post-metadata">

**Author:** ![jzr](https://avatars.discourse-cdn.com/v4/letter/j/eb9ed0/32.png) [@jzr](https://discourse.julialang.org/u/jzr)\
**Post date:** [May 31, 2021, 7:50pm UTC](https://discourse.julialang.org/t/allowing-the-object-method-args-syntax-as-an-alias-for-method-object-args/62051/55 "2021-05-31T19:50:04Z")

</div>

> [@Tamas\_Papp](#):
>
> In most cases you don’t have to navigate tons of methods, just a small vocabulary. For example, consider [arrays](https://docs.julialang.org/en/v1/manual/interfaces/#man-interface-array), one of the core building blocks of the language: a user would learn about `size` and `[]` ( `getindex` , `setindex!` ), and cover 90% of use cases. The remaining few verbs ( `similar` , `axes` ) complete the picture.
> 
> Or consider [Optim.jl](https://github.com/JuliaNLSolvers/Optim.jl), a powerful optimization package written in native Julia. It exports _two_ functions: `optimize` and `maximize` .
> 
> Julia is noun-, not verb-heavy.

It’s true that at the bottom there are often only a few functions that a library needs, but new programmers can be misled by this. Because of multiple dispatch, there are often many higher-level functions that can automatically use the few core functions. And, I believe that proliferation of verbs (e.g. [IterTools.jl](https://juliacollections.github.io/IterTools.jl/latest/)) that work on a simple interface is a very good thing. The alternative to _many_ functions is _few_ functions with [messy semantics](https://discourse.julialang.org/t/what-is-the-difference-between-rand-and-sample/52297/8), and that should be avoided.

The way to have clear and composable APIs is to have a lot of distinguishable functions with clear contracts. In Julia, those functions can all act on many data types automatically, but that should not obscure the guiding principle that a function should do one thing clearly.

I want more verbs!

---

_[View the full topic](https://discourse.julialang.org/t/allowing-the-object-method-args-syntax-as-an-alias-for-method-object-args/62051)._
