DataFramesMeta.jl icon indicating copy to clipboard operation
DataFramesMeta.jl copied to clipboard

Good hack for avoid compilation when no columns submitted

Open pdeffebach opened this issue 4 years ago • 1 comments

julia> using DataFrames;

julia> struct A{T} <: Function
           x::T
       end;

julia> (a::A)() = a.x;

julia> df = DataFrame(a = [1], b = [2]);

julia> transform(df, [] => (A(1)) => :c)
1×3 DataFrame
 Row │ a      b      c     
     │ Int64  Int64  Int64 
─────┼─────────────────────
   1 │     1      2      1

pdeffebach avatar Jun 14 '21 17:06 pdeffebach

Need an optimization for Returns here.

pdeffebach avatar Mar 01 '24 15:03 pdeffebach