Better HN
topnewbestaskshowjobs
Log inSign up

bieganek

21 karma · joined Oct 9, 2020 (6y ago) · 3 submissions

Submissions

comment 6y ago · link · parent

I think the previous poster's use of the phrase "reach into your package" was a bit colorful. You're never actually modifying the internal code of a library. You're only extending a generic function from a library to work on your own custom type. So that extension only affects code that uses your new custom type. It's akin to using class inheritance in OOP languages.

comment 6y ago · link · parent

> Long registry lookup times (2-5mins) when starting a new session

I'm not sure what you are referring to here. Yes, sometimes after you've installed new packages, the Julia VS Code Language Server has to do some re-indexing which can take some time, but they've improved this and you can still program and use the integrated REPL while this is occurring.

> Ctrl-click navigation does not work to lookup definitations in libraries

In VS Code, F12 (Go to Definition) does work. You can also use `@edit foo(x)` in the REPL.

> Filters and maps are not lazy

Use Iterators.filter or use generator expressions.

> Package management is done as a part of script execution

I'm also not sure what this refers to, but the package manager in Julia is one of the best things about Julia.

> Editors (Juno) do not check types at runtime when the information is readily available

The VS Code Julia extension has a linter that is pretty helpful. It's not perfect, but they're actively working on developing it.

> DataFrames.jl: Transform does nonsense (use map instead)

The new select and transform functions in DataFrames.jl are actually quite powerful and useful.

> DataFrames.jl: No transpose

Transpose is not a generic concept for a table. Sure, it might make sense in specific cases, but in general it doesn't make sense to transpose a table.

comment 6y ago · link · parent

Julia code almost never has semicolons. Semicolons can be used at the REPL to suppress printing, but actual Julia code does not normally use semicolons.

I personally like the "end"s because I like the symmetry and they're prettier than curly braces. Also, there are some syntax color themes that color the "end"s in a darker color in order to de-emphasize the "end"s, which can be nice depending on your taste.