# Internals & Design

**URL:** https://discourse.julialang.org/c/dev/5.md?page=60

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

**Page:** 61

---

## [Regex, PCRE2, and the \`PCRE2\_UCP\` / \`(\*UCP)\` flag](https://discourse.julialang.org/t/regex-pcre2-and-the-pcre2-ucp-ucp-flag/10930)

<div class="topic-metadata">

**Author:** [@ScottPJones](https://discourse.julialang.org/u/ScottPJones)\
**Replies:** 16\
**Last updated:** [May 17, 2018, 7:24pm UTC](https://discourse.julialang.org/t/regex-pcre2-and-the-pcre2-ucp-ucp-flag/10930 "2018-05-17T19:24:28Z")

</div>

In the discussion on GitHub: #27084 it seems people are gravitating towards setting the PCRE2\_UCP flag by default. I would strongly recommend against that, and from their comments, it looks like the authors of PCRE2 als…

---

## [Splitting more things out of base](https://discourse.julialang.org/t/splitting-more-things-out-of-base/10958)

<div class="topic-metadata">

**Author:** [@foobar\_lv2](https://discourse.julialang.org/u/foobar_lv2)\
**Replies:** 27\
**Last updated:** [May 17, 2018, 5:53pm UTC](https://discourse.julialang.org/t/splitting-more-things-out-of-base/10958 "2018-05-17T17:53:53Z")

</div>

FWIW, I would actually prefer a smaller Base namespace, with e.g. linear algebra as modules (neither external packages nor base), and a much larger library of modules provided. So more python-style in that respect. This …

---

## [Make fails at recipe julia-sysimg-release, no clue why](https://discourse.julialang.org/t/make-fails-at-recipe-julia-sysimg-release-no-clue-why/10950)

<div class="topic-metadata">

**Author:** [@digital\_carver](https://discourse.julialang.org/u/digital_carver)\
**Replies:** 5\
**Last updated:** [May 17, 2018, 1:56pm UTC](https://discourse.julialang.org/t/make-fails-at-recipe-julia-sysimg-release-no-clue-why/10950 "2018-05-17T13:56:13Z")

</div>

I edited some docs locally and ran make docs as suggested by Contributing.md. It ran for several minutes, and errored out with this: JULIA usr/lib/julia/sys-o.a coreio.jl exports.jl essentials.jl ctypes.jl gcutils.j…

---

## [Add reduction \`none()\` as syntactic sugar in place of \`!any()\`](https://discourse.julialang.org/t/add-reduction-none-as-syntactic-sugar-in-place-of-any/10859)

<div class="topic-metadata">

**Author:** [@lucatrv](https://discourse.julialang.org/u/lucatrv)\
**Replies:** 4\
**Last updated:** [May 13, 2018, 5:26pm UTC](https://discourse.julialang.org/t/add-reduction-none-as-syntactic-sugar-in-place-of-any/10859 "2018-05-13T17:26:58Z")

</div>

none() would work as follows: none(\[false, false, true, false\]) =\> false none(\[false, false, false, false\]) =\> true

---

## [Sprintf with %g](https://discourse.julialang.org/t/sprintf-with-g/10857)

<div class="topic-metadata">

**Author:** [@iwelch](https://discourse.julialang.org/u/iwelch)\
**Replies:** 4\
**Last updated:** [May 12, 2018, 10:45pm UTC](https://discourse.julialang.org/t/sprintf-with-g/10857 "2018-05-12T22:45:52Z")

</div>

apologies for disturbing. it is so close to 1.0 that I wanted to make sure that the following julia behavior is what you wanted and not a bug: #include \<stdio.h\> int main() { printf("'%12.10g'\\n", 1e-2); printf("'…

---

## [Language restriction to solve 15276?](https://discourse.julialang.org/t/language-restriction-to-solve-15276/10625)

<div class="topic-metadata">

**Author:** [@Stephen\_Vavasis](https://discourse.julialang.org/u/Stephen_Vavasis)\
**Replies:** 48\
**Last updated:** [May 11, 2018, 6:06pm UTC](https://discourse.julialang.org/t/language-restriction-to-solve-15276/10625 "2018-05-11T18:06:10Z")

</div>

One of the most common complaints arising in this group is issue 15276, performance of captured variables in closures · Issue #15276 · JuliaLang/julia · GitHub, which seems to cause all kinds of baffling performance hits…

---

## [Implementation Hiding Proposal](https://discourse.julialang.org/t/implementation-hiding-proposal/10816)

<div class="topic-metadata">

**Author:** [@polypus74](https://discourse.julialang.org/u/polypus74)\
**Replies:** 19\
**Last updated:** [May 10, 2018, 7:32pm UTC](https://discourse.julialang.org/t/implementation-hiding-proposal/10816 "2018-05-10T19:32:21Z")

</div>

Julia is now my favorite language by a wide margin, and aside from the minor quibble of pancakecaseidentifiers, i can hardly fault it. There is one thing which does bother me however, and that is modules, import/export …

---

## [Formal list of changes to AST in v0.7](https://discourse.julialang.org/t/formal-list-of-changes-to-ast-in-v0-7/10595)

<div class="topic-metadata">

**Author:** [@chakravala](https://discourse.julialang.org/u/chakravala)\
**Replies:** 1\
**Last updated:** [May 9, 2018, 5:30pm UTC](https://discourse.julialang.org/t/formal-list-of-changes-to-ast-in-v0-7/10595 "2018-05-09T17:30:01Z")

</div>

It would probably help a lot if there were a dedicated list for changes to the AST in v0.7, since some packages are implicitly intertwined with the AST, making it difficult to find all the potential issues immediately.

---

## [Bug with \`import\` on Windows?](https://discourse.julialang.org/t/bug-with-import-on-windows/10798)

<div class="topic-metadata">

**Author:** [@chakravala](https://discourse.julialang.org/u/chakravala)\
**Replies:** 2\
**Last updated:** [May 9, 2018, 2:47pm UTC](https://discourse.julialang.org/t/bug-with-import-on-windows/10798 "2018-05-09T14:47:34Z")

</div>

This is an issue that seems to affect Windows users: julia\> module ModPlus +(r...) = Base.:+(r...) end ModPlus julia\> import ModPlus: + julia\> module ModTimes \*(r...) = Base.:\*(r...) …

---

## [Networked REPL?](https://discourse.julialang.org/t/networked-repl/2085)

<div class="topic-metadata">

**Author:** [@jballanc](https://discourse.julialang.org/u/jballanc)\
**Replies:** 35\
**Last updated:** [May 9, 2018, 12:23pm UTC](https://discourse.julialang.org/t/networked-repl/2085 "2018-05-09T12:23:28Z")

</div>

Not to pull this thread too far off-topic, but for a while I’ve been contemplating writing a Julia equivalent of Clojure’s nREPL (networkedREPL). The idea is to split a REPL into front-end (handling code-entry, history,…

---

## [Global variables as thread local storage](https://discourse.julialang.org/t/global-variables-as-thread-local-storage/3587)

<div class="topic-metadata">

**Author:** [@ScottPJones](https://discourse.julialang.org/u/ScottPJones)\
**Replies:** 1\
**Last updated:** [May 7, 2018, 10:00am UTC](https://discourse.julialang.org/t/global-variables-as-thread-local-storage/3587 "2018-05-07T10:00:58Z")

</div>

Is there any plan to add some syntax to mark global variables as being in thread-local storage? (as in C and C++) There are a number of things in Base (BigFloats, @printf, etc.) and in packages (DecFP) where global vari…

---

## [Anonymous function calls with remotecall is not lexically scoped & MPI vs libuv](https://discourse.julialang.org/t/anonymous-function-calls-with-remotecall-is-not-lexically-scoped-mpi-vs-libuv/10749)

<div class="topic-metadata">

**Author:** [@cnliao](https://discourse.julialang.org/u/cnliao)\
**Replies:** 2\
**Last updated:** [May 7, 2018, 3:39am UTC](https://discourse.julialang.org/t/anonymous-function-calls-with-remotecall-is-not-lexically-scoped-mpi-vs-libuv/10749 "2018-05-07T03:39:53Z")

</div>

When using remotecall the following behavior is observed on Julia stable v0.6.2: julia\> addprocs(1) 1-element Array{Int64,1}: 2 julia\> wait(@spawnat 2 global x = 0) Future(2, 1, 3, Nullable{Any}()) julia\> f = ()-\>print…

---

## [Flaw in Regex support for String](https://discourse.julialang.org/t/flaw-in-regex-support-for-string/9667)

<div class="topic-metadata">

**Author:** [@ScottPJones](https://discourse.julialang.org/u/ScottPJones)\
**Replies:** 38\
**Last updated:** [May 4, 2018, 10:12pm UTC](https://discourse.julialang.org/t/flaw-in-regex-support-for-string/9667 "2018-05-04T22:12:53Z")

</div>

I believe there is a flaw with the Regex support in Base. Since #24999, String does not necessarily have a valid UTF-8 string. However, regex.jl has the following defaults: const DEFAULT\_COMPILER\_OPTS = PCRE.UTF | PCR…

---

## [Precompilation speedup using distributed caching?](https://discourse.julialang.org/t/precompilation-speedup-using-distributed-caching/10693)

<div class="topic-metadata">

**Author:** [@airpmb](https://discourse.julialang.org/u/airpmb)\
**Replies:** 0\
**Last updated:** [May 4, 2018, 5:40am UTC](https://discourse.julialang.org/t/precompilation-speedup-using-distributed-caching/10693 "2018-05-04T05:40:46Z")

</div>

First off, let me disclaim that this idea partially involves one of the 2 Hard Things in CS \[1\] (actually maybe the other of them depending how you want to interpret it) and so is probably cursed from the get-go. But it …

---

## [Possibility of \`local import\` statements in future?](https://discourse.julialang.org/t/possibility-of-local-import-statements-in-future/10611)

<div class="topic-metadata">

**Author:** [@chakravala](https://discourse.julialang.org/u/chakravala)\
**Replies:** 63\
**Last updated:** [May 2, 2018, 9:54pm UTC](https://discourse.julialang.org/t/possibility-of-local-import-statements-in-future/10611 "2018-05-02T21:54:28Z")

</div>

Is there any possibility that Julia will have local import in the future? I’m aware some people think this is a silly idea; however, this would actually solve a very real problem some users might face. Namely, people wa…

---

## [Composing types with non-concrete fields](https://discourse.julialang.org/t/composing-types-with-non-concrete-fields/10678)

<div class="topic-metadata">

**Author:** [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Replies:** 1\
**Last updated:** [May 3, 2018, 10:51am UTC](https://discourse.julialang.org/t/composing-types-with-non-concrete-fields/10678 "2018-05-03T10:51:08Z")

</div>

Consider the MWE struct Foo x::Any # NOT CONCRETE end struct Bar{Ty, Tz} y::Ty z::Tz # but fully parametrized here end f(b::Bar) = b.y + 1 # this function only uses the concrete field b = Bar(1, Fo…

---

## [Testing for type stability regressions](https://discourse.julialang.org/t/testing-for-type-stability-regressions/10629)

<div class="topic-metadata">

**Author:** [@Raf](https://discourse.julialang.org/u/Raf)\
**Replies:** 7\
**Last updated:** [May 2, 2018, 11:20am UTC](https://discourse.julialang.org/t/testing-for-type-stability-regressions/10629 "2018-05-02T11:20:42Z")

</div>

Is there a standard way of testing for regressions in type stability? Currently I manually check there are no unions etc in @code\_warntype, but it would be preferable if that was a test.

---

## [LOAD\_PATH in 0.7 / nightly](https://discourse.julialang.org/t/load-path-in-0-7-nightly/10634)

<div class="topic-metadata">

**Author:** [@alee](https://discourse.julialang.org/u/alee)\
**Replies:** 5\
**Last updated:** [May 1, 2018, 12:07pm UTC](https://discourse.julialang.org/t/load-path-in-0-7-nightly/10634 "2018-05-01T12:07:17Z")

</div>

When testing code on a nightly release of Julia, the existence of push!(LOAD\_PATH, "directory") in ~/.juliarc.jl does not have any effect on the LOAD\_PATH variable in the running Julia session. Is there a way to set u…

---

## [Function name conflict: ADL / function merging?](https://discourse.julialang.org/t/function-name-conflict-adl-function-merging/10335)

<div class="topic-metadata">

**Author:** [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Replies:** 212\
**Last updated:** [April 30, 2018, 11:26pm UTC](https://discourse.julialang.org/t/function-name-conflict-adl-function-merging/10335 "2018-04-30T23:26:44Z")

</div>

Is there any reason why Julia needs me to fully qualify the function name when the argument types are clear and there shouldn’t be any problem with multiple dispatch? Case 1: load JuliaDB before defining Foo julia\> usi…

---

## [Why not always keyword?](https://discourse.julialang.org/t/why-not-always-keyword/10600)

<div class="topic-metadata">

**Author:** [@foobar\_lv2](https://discourse.julialang.org/u/foobar_lv2)\
**Replies:** 2\
**Last updated:** [April 28, 2018, 7:46pm UTC](https://discourse.julialang.org/t/why-not-always-keyword/10600 "2018-04-28T19:46:53Z")

</div>

Now that keyword arguments are becoming faster, I was wondering: Why not allow calling positional arguments with keywords? In cases that are not entirely inferred, keyword calling would of course be slower. The only sem…

---

## [Memory management and low-level free/malloc interaction](https://discourse.julialang.org/t/memory-management-and-low-level-free-malloc-interaction/10588)

<div class="topic-metadata">

**Author:** [@lobingera](https://discourse.julialang.org/u/lobingera)\
**Replies:** 0\
**Last updated:** [April 28, 2018, 8:53am UTC](https://discourse.julialang.org/t/memory-management-and-low-level-free-malloc-interaction/10588 "2018-04-28T08:53:26Z")

</div>

I’m trying to make some sense of Memory leak when destroying a surface · Issue #225 · JuliaGraphics/Cairo.jl · GitHub and CairoScript should probably not use finalizers · Issue #215 · JuliaGraphics/Cairo.jl · GitHub whic…

---

## [@schedule considered harmful](https://discourse.julialang.org/t/schedule-considered-harmful/10540)

<div class="topic-metadata">

**Author:** [@non-Jedi](https://discourse.julialang.org/u/non-Jedi)\
**Replies:** 8\
**Last updated:** [April 27, 2018, 6:16pm UTC](https://discourse.julialang.org/t/schedule-considered-harmful/10540 "2018-04-27T18:16:16Z")

</div>

I read this article from hacker news about asyncronicity today and decided to see how well the concepts there mapped to scheduled Tasks in Julia (I haven’t had occasion to use Tasks myself yet). To my gratification, …

---

## [Possibly unused \`extra\` field in \`Regex\` struct](https://discourse.julialang.org/t/possibly-unused-extra-field-in-regex-struct/10479)

<div class="topic-metadata">

**Author:** [@ScottPJones](https://discourse.julialang.org/u/ScottPJones)\
**Replies:** 0\
**Last updated:** [April 22, 2018, 12:24pm UTC](https://discourse.julialang.org/t/possibly-unused-extra-field-in-regex-struct/10479 "2018-04-22T12:24:16Z")

</div>

There is a field extra::Ptr{Void} in the Regex struct in julia/base/regex.jl. I was wondering if anybody knew what it was for, as it doesn’t seem to be used at all in the Julia code, and doesn’t seem to be in the PCRE A…

---

## [Merging composite types - multiple inheritance of fields/mixins](https://discourse.julialang.org/t/merging-composite-types-multiple-inheritance-of-fields-mixins/10458)

<div class="topic-metadata">

**Author:** [@Raf](https://discourse.julialang.org/u/Raf)\
**Replies:** 3\
**Last updated:** [April 21, 2018, 11:23pm UTC](https://discourse.julialang.org/t/merging-composite-types-multiple-inheritance-of-fields-mixins/10458 "2018-04-21T23:23:28Z")

</div>

This has been talked about a lot before - the lack of mixin functionality in julia. But I’ve been thinking about mixins a lot – for merging existing composite types to balance modularity with simplicity when using lots…

---

## [Should a.b lower to getproperty(a, Val{:b})?](https://discourse.julialang.org/t/should-a-b-lower-to-getproperty-a-val-b/10449)

<div class="topic-metadata">

**Author:** [@benninkrs](https://discourse.julialang.org/u/benninkrs)\
**Replies:** 4\
**Last updated:** [April 20, 2018, 8:17pm UTC](https://discourse.julialang.org/t/should-a-b-lower-to-getproperty-a-val-b/10449 "2018-04-20T20:17:01Z")

</div>

I am very happy that in 0.7 the expression a.b lowers to an overloadable function. But I am a bit surprised that it lowers to Base.getproperty(a, :b) and not Base.getproperty(a, Val{:b}). It seems that the latter would b…

---

## [Future of Base.Threads](https://discourse.julialang.org/t/future-of-base-threads/10440)

<div class="topic-metadata">

**Author:** [@bkamins](https://discourse.julialang.org/u/bkamins)\
**Replies:** 1\
**Last updated:** [April 20, 2018, 5:26pm UTC](https://discourse.julialang.org/t/future-of-base-threads/10440 "2018-04-20T17:26:10Z")

</div>

In Julia 0.7 packages are moved out of Base to standard library. Are there plans to move Threads module to standard library also or it will stay in Base?

---

## [Real, AbstractFloat and Integer with Missing?](https://discourse.julialang.org/t/real-abstractfloat-and-integer-with-missing/10402)

<div class="topic-metadata">

**Author:** [@iwelch](https://discourse.julialang.org/u/iwelch)\
**Replies:** 8\
**Last updated:** [April 18, 2018, 8:31pm UTC](https://discourse.julialang.org/t/real-abstractfloat-and-integer-with-missing/10402 "2018-04-18T20:31:44Z")

</div>

dear Julia developers— If I understand correctly, “Missing” has become an important part of Julia’s future. (keeping 1.0 delayed, too.) I think this makes a lot of sense. Right now, we have “Real”, “AbstractFloat”, a…

---

## [Method specificity gotcha](https://discourse.julialang.org/t/method-specificity-gotcha/10349)

<div class="topic-metadata">

**Author:** [@tkoolen](https://discourse.julialang.org/u/tkoolen)\
**Replies:** 4\
**Last updated:** [April 15, 2018, 7:08pm UTC](https://discourse.julialang.org/t/method-specificity-gotcha/10349 "2018-04-15T19:08:34Z")

</div>

I just spent a lot of time debugging what came down to the following: struct Foo{T\<:Integer} end f(::Type{F}) where {T, F\<:Foo{T}} = 1 f(::Type{F}) where {F\<:Foo} = 2 I expected f(Foo{Int}) to return 1 and f(Foo) to r…

---

## [Bikeshedding mapslices](https://discourse.julialang.org/t/bikeshedding-mapslices/3998)

<div class="topic-metadata">

**Author:** [@bramtayl](https://discourse.julialang.org/u/bramtayl)\
**Replies:** 18\
**Last updated:** [April 14, 2018, 6:49pm UTC](https://discourse.julialang.org/t/bikeshedding-mapslices/3998 "2018-04-14T18:49:52Z")

</div>

I’m trying to improve the performance of mapslices, which is needed for in https://github.com/JuliaLang/julia/issues/3893#issuecomment-304924903. The only changes I’ve made are to rename things so I understand (a little)…

---

## [How to print array contents in v0.7 (Base.showarray in v0.7)](https://discourse.julialang.org/t/how-to-print-array-contents-in-v0-7-base-showarray-in-v0-7/10303)

<div class="topic-metadata">

**Author:** [@Roger-luo](https://discourse.julialang.org/u/Roger-luo)\
**Replies:** 17\
**Last updated:** [April 13, 2018, 1:09pm UTC](https://discourse.julialang.org/t/how-to-print-array-contents-in-v0-7-base-showarray-in-v0-7/10303 "2018-04-13T13:09:21Z")

</div>

In v0.6 there is showarray, but it seems that it is changed in v0.7, how should I print some self-made type that implemented Array interface in v0.7?

[Previous page](https://discourse.julialang.org/c/dev/5.md?page=59)

[Next page](https://discourse.julialang.org/c/dev/5.md?page=61)
