# Option to start REPL in baremodule mode

**URL:** <https://discourse.julialang.org/t/option-to-start-repl-in-baremodule-mode/17244>\
**Category:** Internals & Design\
**Tags:** question\
**Created:** [November 7, 2018, 10:09am UTC](https://discourse.julialang.org/t/option-to-start-repl-in-baremodule-mode/17244 "2018-11-07T10:09:56Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![schlichtanders](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/schlichtanders/32/32145_2.png) [@schlichtanders](https://discourse.julialang.org/u/schlichtanders)\
**Post date:** [November 7, 2018, 10:09am UTC](https://discourse.julialang.org/t/option-to-start-repl-in-baremodule-mode/17244/1 "2018-11-07T10:09:56Z")

</div>

Just stumbled upon the type privacy issue, especially when wanting to overwrite Base.+ and other operators. As long as I working in modules we can use `baremodule` to easily switch between Base.+ and MyPackage.+. However in the julia REPL this seems impossible right now.

- Is it possible to add a `--baremodule` flag (or something similar) to julia executable, which startsup the REPL as a baremodule where Base is not yet in `using` mode?

---

<div class="post-metadata">

**Author:** ![yuyichao](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/yuyichao/32/20_2.png) [@yuyichao](https://discourse.julialang.org/u/yuyichao)\
**Post date:** [November 7, 2018, 12:22pm UTC](https://discourse.julialang.org/t/option-to-start-repl-in-baremodule-mode/17244/2 "2018-11-07T12:22:03Z")

</div>

> [@schlichtanders](#):
>
> As long as I working in modules we can use `baremodule` to easily switch between Base.+ and MyPackage.+. However in the julia REPL this seems impossible right now.

You don’t need baremodule.

```julia
julia> +(a, b) = 23
+ (generic function with 1 method)

julia> 1 + 2
23

julia> Base.:+(1, 2)
3

```

---

<div class="post-metadata">

**Author:** ![schlichtanders](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/schlichtanders/32/32145_2.png) [@schlichtanders](https://discourse.julialang.org/u/schlichtanders)\
**Post date:** [November 8, 2018, 1:31pm UTC](https://discourse.julialang.org/t/option-to-start-repl-in-baremodule-mode/17244/3 "2018-11-08T13:31:23Z")

</div>

thanks. Yeah that is true and is a workaround, however when calling

```julia
using MyPackageWithPlus

```

you will get the usual warning

```julia
WARNING: using MyPackageWithPlus.+ in module Main conflicts with an existing identifier.

```

and nothing is assigned. You have to assign functions yourself.

With a `--baremodule` flag everything would work.
