Commit Graph

192 Commits

Author SHA1 Message Date
Denis Buzdalov
e8d3d788c1
[ base ] Add some more properties, functions and interface implementations (#2361) 2022-03-23 13:33:13 +00:00
Ohad Kammar
319c7f7b86
Move Syntax.PreorderReasoning into base (#2368) 2022-03-22 20:58:36 +00:00
Joel Berkeley
399d6016a9
[ prelude ] add subtract (#2357) 2022-03-17 18:24:42 +00:00
G. Allais
1c396744d9
[ doc ] :printdef for interface implementations (#2340) 2022-03-07 11:47:20 +00:00
Joel Berkeley
f436388a6b
adopt backend implementations of pow (#2334) 2022-03-03 23:39:25 +00:00
G. Allais
1011cc6162
[ papers ] Tychonoff (Part I) (#2332) 2022-02-24 11:12:53 +00:00
Jan de Muijnck-Hughes
4ba3bb6670
[ fix ] Literate things (#2312)
Co-authored-by: G. Allais <guillaume.allais@ens-lyon.org>
2022-02-18 11:29:52 +00:00
Denis Buzdalov
b727ae4a97 [ new ] Add a Monoid instance of the f a where f is Applicative 2022-02-16 14:23:56 +00:00
Denis Buzdalov
e2487106fd
[ prelude ] Ease Compose compositions (#2324) 2022-02-16 14:19:25 +00:00
madman-bob
0ee9632e45
[ refactor ] Abstract Prelude.elem to work with all Foldables (#2294) 2022-02-01 21:34:29 +00:00
Stefan Höck
44245e1683
[ fix ] issue #2288 (#2289) 2022-01-28 09:01:09 +00:00
G. Allais
ec5afa5065
[ libs ] move propaganda out of contrib (#2213) 2022-01-25 12:25:55 +00:00
James Cook
e82600c4d6
[ opt ] transform rule making List.length tail-recursive. (#2100) 2022-01-24 16:12:29 +00:00
MarcelineVQ
6d10ca09b4 [ base ] add Show for Ordering 2022-01-19 22:12:36 +00:00
Denis Buzdalov
f1941cecac [ cleanup ] Remove piece of dead code from prelude 2021-11-26 10:14:47 +00:00
G. Allais
059f74ad0b
[ fix #1861 ] rewrite_impl is linear (#2150) 2021-11-25 17:07:05 +00:00
Mathew Polzin
1576a578a0
[ cleanup ] Remove unused imports (#2123)
* contrib library unused import removal
* remove a few unused imports.
* another round of unused import removal
* another round of unused import deletion.
* another round of unused import deletion.
2021-11-18 16:47:36 +00:00
Kamil Shakirov
ae411fe756 [ doc ] Mark code blocks as Idris code 2021-11-11 18:55:11 +00:00
G. Allais
15cc8243f7
[ re #2001 ] Make some prelude interfaces total (#2083)
The prelude interfaces that have default definitions for all of
their fields are declared total so that users are forced to think
about meeting the minimal requirements for an implementation to be
valid.
2021-11-02 15:34:52 +00:00
CodingCellist
20fe83de9a
[ doc ] Completely document the Data.List module (#2061) 2021-10-26 17:16:06 +01:00
Denis Buzdalov
c340e0e713 [ cleanup ] Move left autos that are most likely to be passed explicitly 2021-10-25 13:17:03 +01:00
Mathew Polzin
f078d5f5dc
clean up some deprecations (#2057)
* deprecate Data.Nat.Order.decideLTE

* Add properties for LTE/GTE that produce the difference.

* remove deprecated function now that it is available in the base library.

* remove two deprecated lines.

* remove module deprecated since v0.4.0

* fix prelude reference to renamed primitive.

* finish removing Data.Num.Implementations

* remove deprecated dirEntry function.

* remove deprecated fastAppend. Update CHANGELOG.

* replace fastAppend in test case

* replace fastAppend uses in compiler.

* remove new properties that weren't actually very new.
2021-10-24 12:06:57 +01:00
stefan-hoeck
62237f74ea [ fix ] fastConcat for JS backends 2021-10-14 14:58:51 +01:00
André Videla
274954998b
Implement generic interpolation (#1967)
Co-authored-by: Guillaume ALLAIS <guillaume.allais@ens-lyon.org>
2021-10-13 17:26:54 +01:00
Edwin Brady
1e90182311
Version increment to 0.5.1 (#1939)
This is to remove the requirement on Chez >9.5
2021-09-19 20:53:32 +01:00
Edwin Brady
ada3eb4449
Version 0.5.0 (#1931)
* Update version numbers and bootstrap scheme

* Use wall clock time for search timeouts

That was always the intention in any case, rather than the process time.
2021-09-18 16:07:34 +01:00
James Cook
971afa9f5d
Add a transform rule making (++) for List tail-recursive. (#1888) 2021-09-16 15:35:29 +01:00
Denis Buzdalov
5d70c746b1 [ prelude ] Implement Semigroup for ordinary pairs 2021-09-03 18:00:03 +01:00
Guillaume ALLAIS
99b005886f [ fix ] invalid Cast instances
integerToNat is only equal to `believe_me` at runtime, not at compile
time. You'd believe it cannot be a problem given that the implementation
of `Cast` is not exported but the REPL reduces everything.
2021-08-25 12:02:04 +01:00
stefan-hoeck
ed9a21f6bc [ new ] support prim__putStr in browser 2021-08-24 03:44:57 +00:00
Daniel Kröni
370a273b35 Inline Neg implementations 2021-08-17 19:34:52 +01:00
Zoe Stafford
1669fc351b
Refactor %builtin (#1803)
* Stub for future 'identity' optimisation
I plan to add this later, but I'm using for now for
NaturalToInteger and IntegerToNatural

* Refactor `%builtin`
fixes #1799

- automatically optimise all Natural shaped things
- NaturalToInteger and IntegerToNatural now use
  new `Identity` flag (internal use only for now)
  which signals the function is identity at runtime

* Use NaturalToInteger and IntegerToNatural for Nat and Fin
Also define show fin in terms of finToInteger, for speed

* Fix name handling for %builtin

* [ tests ] fixes + #1799

* remove %builtin from libs
Add back after next version

* Use resolved names where convenient
2021-08-03 14:19:17 +01:00
Sventimir
4920601fe9
Add tests for Nat ranges and fix bad range [1,2..1] behaviour. (#1794)
Co-authored-by: Marcin Pastudzki <marcin.pastudzki@gmail.com>
2021-07-28 06:52:59 +01:00
Guillaume ALLAIS
c48fe486fa [ cleanup ] on is meant to be used with 2 arguments
The previous definition means it won't reduce until it's applied to
4 arguments which may have detrimental effects: ``f `on` fst`` would
for instance stay blocked, with some implicit arguments of the form
`DPair a b`. This means that `b` appears in a negative position in
the expression which may lead to positivity checking rejecting a
datatype defined using `on`!

I have decided to leave `g` and `f` on the LHS because I expect `on`
to be used either:
  1. partially applied to two arguments
  2. in a section if only applied to 1 and sections get eta-expanded
     by the parser so that's fine.
2021-07-27 13:58:41 +01:00
Stiopa Koltsov
5a351f4e7e Accept HasIO in onCollect functions
Since most functions work with `HasIO`, it is more convenient to
accept `HasIO` in `onCollect` and `onCollectAny`.
2021-07-17 14:42:34 +01:00
Edwin Brady
4079ae0e25 Merge branch 'master' of https://github.com/AliasQli/Idris2 into AliasQli-master 2021-07-15 21:44:26 +01:00
Stiopa Koltsov
291823c752 Remove prim__getErrno from Prelude.IO
The function is not used, and it is defined incorrectly.
2021-07-14 03:15:49 +01:00
Nick Drozd
9cca3a7d35
Use Not instead of -> Void (#1667) 2021-07-13 15:32:01 +01:00
Stefan Höck
599d0635e9
[ refactor ] JS backend overhaul (#1609) 2021-07-10 11:15:21 +01:00
Nick Drozd
9cb20f3653
Clean up some assert_total instances (#1644) 2021-06-29 22:05:40 +01:00
Stefan Höck
f5bcc81115
[ new ] Add FromChar and FromDouble interfaces to the prelude (#1641) 2021-06-29 08:37:02 +01:00
Stefan Höck
6ed266d306
[ new ] Missing integer type interfaces (#1629)
Co-authored-by: Guillaume ALLAIS <guillaume.allais@ens-lyon.org>
2021-06-28 20:00:10 +01:00
Fabián Heredia Montiel
d5167a0108
[ fix #1581 ] public export Range functions and implementations (#1602)
Since `[a..b]` uses `takeUntil`/`takeBefore` indirectly those too had to
be changed to `public export` clashing with `Data.Stream` definitions.

A small readability refactor was made with the `compare` function from
`EqOrd`.
2021-06-28 16:52:23 +01:00
Tim Engler
05f28724ed
[ fix #1579 ] Nat hack for comparison operators (#1580)
Co-authored-by: Guillaume ALLAIS <guillaume.allais@ens-lyon.org>
2021-06-28 16:48:08 +01:00
Edwin Brady
a93def90a9 Merge github.com:idris-lang/Idris2 into prepare-040 2021-06-23 18:16:36 +01:00
Edwin Brady
5689786b26
Merge pull request #1598 from gallais/show-void
[ fix ] missing Show implementations in libs
2021-06-23 18:11:40 +01:00
Edwin Brady
ae73c39609 Merge github.com:idris-lang/Idris2 into prepare-040 2021-06-23 16:17:40 +01:00
Edwin Brady
c1057a19af
Merge pull request #1489 from buzden/some-uninhabiteds
[ base ] Some lacking implementations for `Uninhabited`
2021-06-23 16:17:32 +01:00
Edwin Brady
a0cfa28621 Update version numbers 2021-06-23 16:15:21 +01:00
Guillaume ALLAIS
21cca08df1 [ fix ] missing Show Void in prelude 2021-06-23 15:33:12 +01:00