https://github.com/JuliaLang/julia
Raw File
Tip revision: 7083691c79321b1857cdb67cd21e349ea6fbe549 authored by Isaiah Norton on 10 April 2015, 03:13:27 UTC
fix #10765: don't try to copy isDeclaration Function*
Tip revision: 7083691
i18n.jl
module I18n

export locale

LOCALE = nothing
CALLBACKS = Function[]

function locale()
    if LOCALE === nothing
        # XXX:TBD return default locale
        return ""
    end
    LOCALE
end

function locale(s::ByteString)
    global LOCALE = s
    # XXX:TBD call setlocale
    for cb in CALLBACKS
        cb()
    end
end

end # module
back to top