Skip to content

Conversation

@ezmiller
Copy link
Collaborator

@ezmiller ezmiller commented May 18, 2024

Goal

@joinr pointed out that the Column API MVP merged in #100 had codegen that exported many qualified symbols, which made the generated functions a little bit messier than they need to be.

Also in this PR

A small fix to the docstrings in tablecloth.api.operators. See this diff: https://github.com/scicloj/tablecloth/pull/151/files#diff-079771ab2c8ad3559f9e8c2b23758b662d9062bb2f32a2cf61013595a2c4da93L42-L51

(if (>= ~max-cols cols-count#)
(apply ~fn-sym (apply vector selected-cols#))
(throw (Exception. (str "Exceeded maximum number of columns allowed for operation."))))))]
(~'if (>= ~max-cols cols-count#)
Copy link
Member

@genmeblog genmeblog May 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

>= is missed

(->> args-to-pass#
(apply ~fn-sym)
args-to-pass# (~'concat selected-cols# [~@(drop 3 args)])]
(~'if (>= ~max-cols (~'count selected-cols#))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also here: >=

(fn [ds#]
(~let [ds-with-selected-cols#
(~'let [aggregator#
(~'fn [ds#]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ds# -> ~'ds - it will generate more clean code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants