Basil L. Contovounesios
bedc804da3
Improve function-to-info
...
* dev/examples-to-info.el (function-to-node): Simplify.
(function-to-info): Ditto. Remove gratuitous newlines.
(s-replace): Remove function; no longer used.
* dash-template.texi (Top, Functions): Remove gratuitous newlines.
* dash.texi: Regenerate.
5 years ago
Basil L. Contovounesios
dbbf617c28
Remove dead code from examples-to-info.el
...
* dev/examples-to-info.el (docs--chop-prefix, docs--chop-suffix)
(github-id, function-summary): Remove unused functions.
(function-to-node): Remove redundant conditions.
5 years ago
Basil L. Contovounesios
926eb0b9fc
Add forceful Makefile targets
...
* Makefile (DOCS): New variable listing docs that can be
regenerated with this Makefile.
(maintainer-clean): New target that deletes checked in files that
can be regenerated with this Makefile, as per
(info "(standards) Standard Targets").
(force-docs, force-all): New targets like docs and all,
respectively, that first run maintainer-clean.
Re: #367 .
5 years ago
Basil L. Contovounesios
eedc2affad
Fix docstring Texinfo generation
...
* dev/examples-to-info.el (format-docstring): Generalize @-quoting
by doing it first. Use \< and \> in place of \b for better word
boundary detection. Mark all replacements as fixed and literal.
* dash.texi: Regenerate.
5 years ago
Basil L. Contovounesios
65eeaf6f8b
Fix long-standing typo in examples
...
* dev/examples.el (-tree-mapreduce, -tree-mapreduce-from): Fix typo.
* README.md:
* dash.texi: Regenerate.
5 years ago
Basil L. Contovounesios
46e43c0f71
Fix long-standing typo in Texinfo generation
...
* dev/examples-to-info.el (example-to-string): Don't replace right
brace with left brace.
* dash.texi: Regenerate.
5 years ago
Basil L. Contovounesios
b0bef0f407
Don't set text-quoting-style globally
...
* dev/examples-to-docs.el (dash--describe):
* dev/examples-to-info.el (dash--describe): Bind text-quoting-style
here instead of setting it globally.
5 years ago
Basil L. Contovounesios
5362be78c4
Use actual advertised function signature in manual
...
This is a copy of commit 2aeb4e4f35 of
2021-01-18 "Use actual advertised function signature in README".
* dev/examples-to-info.el (docs--signature): Remove function.
(dash--describe): New function using the same machinery as
describe-function to determine arglists and docstrings.
(defexamples): Use it instead of docs--signature.
* dash.texi: Regenerate.
5 years ago
Basil L. Contovounesios
e0254c56e7
* dash.el (-doto): Fix Edebug spec.
5 years ago
Basil L. Contovounesios
0789fd068c
Fix -some--> docstring and Edebug spec
...
* dash.el (-some-->): Use a valid Edebug spec, not ->. Fix
docstring.
* dev/examples.el (-some-->): Improve tests.
* README.md:
* dev/examples.el: Regenerate docs.
5 years ago
Basil L. Contovounesios
e5e5363650
Merge pull request #367 from HKey/fix-handling-nil
5 years ago
HKey
2a1054794f
Fix handling nils of -some-->
...
* dash.el (-some-->): Fix handling nils in arguments.
* dev/examples.el (-some-->): Add a test case.
* README.md:
* dash.texi: Regenerate docs.
Copyright-paperwork-exempt: yes
5 years ago
Basil L. Contovounesios
8599380511
Optimize -is-prefix? and -is-suffix?
...
* dash.el (-is-prefix?): Stop looping when prefix runs out, even if
list starts with nil elements.
(-is-suffix?): Avoid reversing arguments; just use member.
* dev/examples.el (-is-prefix?, -is-suffix?): Extend tests.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
8bd28878f4
Move pre-commit.sh under dev/
...
* pre-commit.sh: Rename...
* dev/pre-commit.sh: ...to this.
* readme-template.md (Contribute):
* dash-template.texi (Contribute): Adapt accordingly.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
cbd3b293f7
* .elpaignore: Exclude dev/ from GNU ELPA tarball.
5 years ago
Basil L. Contovounesios
a536770b9f
Prefer relative image links in README
...
* readme-template.md: Use relative img link, as recommended by
GitHub's docs.
* README.md: Regenerate.
5 years ago
Basil L. Contovounesios
9ad0d2b972
Extend -map-indexed docs and tests
...
* dash.el (--map): Fix recent typo in docstring.
(--map-indexed): Extend docstring. Prefer push over !cons.
(-map-indexed): Extend docstring.
* dev/examples.el (-map-indexed): Extend tests.
* README.md:
* dash.texi: Regenerate.
5 years ago
Basil L. Contovounesios
525ede2d24
Improve docstring Markdown formatting
...
* dev/examples-to-docs.el (dash--describe): Improve docstring.
(quote-and-downcase, unquote-and-link): Remove functions.
(dash--quote-argnames, dash--quote-metavars, dash--quote-hyperlinks)
(dash--indent-blocks): New formatting functions.
(format-docstring): Rename...
(dash--format-docstring): ...to this. All callers changed. Use new
formatting functions on buffer contents for more sophisticated
Markdown formatting.
* README.md: Regenerate.
5 years ago
Basil L. Contovounesios
2aeb4e4f35
Use actual advertised function signature in README
...
* dev/examples-to-docs.el (docs--signature): Remove function.
(dash--describe): New function using the same machinery as
describe-function to determine arglists and docstrings.
(defexamples): Use it instead of docs--signature.
* README.md: Regenerate.
5 years ago
Basil L. Contovounesios
7fc72d9171
Fix Markdown quoting
...
* dev/examples-to-docs.el (format-docstring): Avoid unquoting
already quoted metavariables. Fix token boundaries.
* README.md: Regenerate.
5 years ago
Basil L. Contovounesios
5d8de451aa
; Fix recent typo in -filter & -remove docstrings
5 years ago
Basil L. Contovounesios
ff5ed7a1ce
Extend -keep docs and tests
...
* dash.el (--keep): Extend docstring. Prefer push over !cons.
(-keep): Extend docstring.
* dev/examples.el (-keep): Extend tests.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
0e5acda7a5
Simplify -non-nil
...
* dash.el (-non-nil): Use --filter for speed.
* dev/examples.el (-non-nil): Extend tests.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
f3ae7bb615
Alias -remove-item to remove
...
* dash.el (-remove-item): Define as an alias of remove for speed.
* dev/examples.el (-remove-item): Extend tests.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
ce4a344229
Eliminate odd? from examples
...
* dev/examples.el (odd?): Remove function.
(-drop-while, -partition-after-pred, -partition-before-pred)
(-each-while, -each-r-while): Replace odd? with built-in
functions (#342 ).
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
4a32a5dc08
Write -remove-last in terms of --remove-last
...
* dash.el (-remove-last): Move logic from here...
(--remove-last): ...to here.
* dev/examples.el (-remove-last): Improve and extend tests.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
f61769dd3a
* dash.el (dash--keywords): Prefer rx.
5 years ago
Basil L. Contovounesios
4fb9613314
Avoid evaluating file-local variables
...
* dev/examples.el: Move font-lock-keywords from "Local Variables"...
* dash.el (dash--keywords): ...to here, for dash-fontify-mode.
5 years ago
Basil L. Contovounesios
3726eb17f3
Improve the examples of -some
...
* dash.el (--some): Simplify slightly. Improve docstring.
(-some): Extend docstring.
* dev/examples.el (-some): Extend tests.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
999cae96f0
Fix short-circuiting of --first
...
* dash.el (--first): Stop looping even if needle is nil. Extend
docstring.
(-first): Extend docstring.
* dev/examples.el (-first): Extend tests.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
db45ee715a
Optimize -remove-first a bit
...
* dash.el (--remove-first): Open code -remove-first using nconc
instead of -concat for speed. Extend docstring.
(-remove-first): Rewrite in terms of --remove-first. Extend
docstring.
* dev/examples.el (-remove-first): Extend tests.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
6f5888c775
Extend --filter and --remove docs and tests
...
* dash.el (--filter, -filter, --remove, -remove): Extend docstrings.
* dev/examples.el (-filter, -remove): Extend tests.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
7a9c937877
Translate non-printable chars in docs
...
* dev/examples-to-docs.el (example-to-string):
* dev/examples-to-info.el (example-to-string): Translate chars like
\^A to their printable representations.
* dev/examples.el (-cut): Evaluate quoted lambda in example.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
9703eacf0c
; Fix Edebug spec in last change
5 years ago
Basil L. Contovounesios
7583e6511b
Revert --map to using mapcar
...
Code in the wild relies on mapcar for working with non-list
sequences, and mapcar can still be faster in some degenerate cases.
* dash.el (--map): Use mapcar again.
Fixes #365 .
5 years ago
Basil L. Contovounesios
2625bc526b
Don't use insert-file-contents-literally
...
* dev/examples-to-docs.el (create-docs-file):
* dev/examples-to-info.el (create-info-file): No need to read files
literally.
5 years ago
Basil L. Contovounesios
0f13e5e0bc
Prefer push over add-to-list
...
* dev/examples-to-docs.el (defexamples, def-example-group):
* dev/examples-to-info.el (defexamples, def-example-group): Replace
unneeded add-to-list with push.
5 years ago
Basil L. Contovounesios
609ac28bab
Improve Texinfo markup when documenting errors
...
* dev/examples-to-docs.el (example-to-string): Simplify.
* dev/examples-to-info.el (example-to-string): Use @error{} instead
of @result{} for errors. Use error-message-string to translate
error lists to their corresponding message.
* dev/examples-to-tests.el (example-to-should): Add support for
checking whole error lists, not just error symbols.
* dev/examples.el (-running-sum, -running-product, -iota): Specify
whole error list, not just error symbol.
* dash.texi: Regenerate.
5 years ago
Basil L. Contovounesios
1ccf08d592
; Fix last change
5 years ago
Basil L. Contovounesios
bf8a46273b
Partially revert last change
...
There is no need to call eval on Emacs 26+, but tests fail in
earlier versions without it, so bring it back, but this time with
lexical-binding, at least.
* dev/examples-to-tests.el (example-to-should): Bring back eval.
5 years ago
Basil L. Contovounesios
d7d0acb0e8
Don't call eval
...
* dev/examples-to-tests.el (example-to-should): No need to call
eval.
(defexamples, def-example-group): Tiny simplifications.
5 years ago
Basil L. Contovounesios
92562909a7
* dash.el (-->): Indent with 1 distinguished arg.
5 years ago
Basil L. Contovounesios
76ace7f9e9
Fix error signaling
...
* dash.el (---partition-all-in-steps-reversed): Rename from this...
(dash--partition-all-in-steps-reversed): ...to this. All callers
changed. Signal wrong-type-argument message conforming to
(info "(elisp) Signaling Errors"). Prefer built-in definitions over
Dash ones where either will do.
(-setq): Signal wrong-number-of-arguments like setq.
(-running-sum, -running-product): Signal wrong-type-argument.
* dev/examples.el (-running-sum, -running-product)
(-partition-in-steps, -partition-all-in-steps, -setq): Update
accordingly.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
ca36c573a4
Allow -lambda with no arguments
...
* dash.el (-lambda): Allow empty arglist. Fix error data signaled.
* dev/examples.el (-lambda): Add tests for this.
* README.md:
* dash.texi: Regenerate docs.
5 years ago
Basil L. Contovounesios
bf8d8767f6
Merge pull request #363 from blc/list
5 years ago
Basil L. Contovounesios
1152febb14
Deprecate variadic -list
...
* dash.el (-list): Change preferred calling convention to a single
required argument.
* dev/examples.el (-list) Rearrange and expand tests accordingly.
* README.md:
* dash.texi: Regenerate docs.
Fixes #225 .
5 years ago
Basil L. Contovounesios
3694ae9305
* dash.el (-iota): Simplify and purify.
...
Re: #215 .
5 years ago
Basil L. Contovounesios
d98f5a02e2
Update for -iota
...
* dash.el (-iota): Tiny simplification.
* dev/examples.el (-iota): Add more tests.
* README.md:
* dash.texi: Regenerate docs.
Re: #207 .
5 years ago
Basil L. Contovounesios
82489971fd
Merge pull request #207 from holomorph/iota
5 years ago
Basil L. Contovounesios
f97563436d
Merge pull request #235
5 years ago