Commit Graph

2059 Commits

Author SHA1 Message Date
Robert Wright
1875f62248 Remove freeBuffer function
Each backend is now responsible for freeing Buffers in the same way as other objects
2021-06-14 15:06:44 +01:00
Robert Wright
195e690ddc Fix RefC Buffer getInt function to work with large values 2021-06-14 15:06:44 +01:00
Robert Wright
c6a5827319 Add RefC readBufferData/writeBufferData support 2021-06-14 15:06:44 +01:00
Robert Wright
d202139171 Distinguish common C and RefC Buffer functions 2021-06-14 15:06:44 +01:00
Robert Wright
c63f25dac2 Distinguish common C and RefC FFI calls 2021-06-14 15:06:44 +01:00
Robert Wright
85e4df8004 Add filenames to Golden Test missing file error reporting 2021-06-14 12:56:39 +01:00
Mathew Polzin
0209cee41a include the other definition of drop because both are quite useful. 2021-06-14 11:44:38 +01:00
Mathew Polzin
1133658e18 Add missing unlock in signal handling C code. 2021-06-14 11:44:38 +01:00
Mathew Polzin
bdd8f4157b Add drop for Vect. 2021-06-14 11:44:38 +01:00
Nick Drozd
4a0a5759b8
Return Maybe from strengthen (#1540)
Co-authored-by: Fabián Heredia Montiel <303897+fabianhjr@users.noreply.github.com>
2021-06-14 10:59:49 +01:00
André Videla
161ea5d50a
Merge pull request #1521 from LibreCybernetics/add-totality-annotatations
Add totality annotations to `src` and `libs/{prelude, base}`
2021-06-13 19:51:48 +00:00
André Videla
508ef8d0ce
Merge pull request #1527 from LibreCybernetics/color-tests
Add color to tests
2021-06-13 16:41:18 +00:00
Fabián Heredia Montiel
4c99537062 Add color to tests 2021-06-13 10:36:30 -05:00
Edwin Brady
40fa9b43a7
Merge pull request #1547 from edwinb/fix1510
A couple of fixes
2021-06-13 14:51:07 +01:00
Edwin Brady
97ee3d4cd3 Check LHS arguments are polymorphic enough
We already did this, but missed a few cases due to the way arguments are
elaborated. So now, when checking an LHS, we don't allow LHS argument
types to be inferred from the pattern, but rather they must be inferred
from elsewhere. To do this, we keep track of the constraints which would
be solved when inferring the type, and make sure they don't solve any
new metavariables. Fixes #1510, and also now gets the error location
right as a bonus!
2021-06-13 13:31:40 +01:00
Denis Buzdalov
bf0985602f [ totality ] More %default total stuff 2021-06-12 21:06:08 -05:00
Fabián Heredia Montiel
dad4dcdaf8 Add totality annotations to src and libs/{prelude, base} 2021-06-12 21:06:08 -05:00
André Videla
42d4c36833
Merge pull request #1522 from LibreCybernetics/cleanup-src-libraries
Cleanup src libraries (Remove `Libraries.Data.Bool.Extra` and half `Libraries.Data.List1`) since they have been included since v0.3.0
2021-06-12 21:54:34 +00:00
André Videla
9b94108b7b
Merge pull request #1542 from andorp/andorp/contributors-wanted
Contributions wanted section in README.
2021-06-12 20:39:33 +00:00
André Videla
ba92a82c78
Contributors -> Contributions 2021-06-12 21:38:14 +01:00
Andor Penzes
012d7f80ce [ README ] Contributors wanted. 2021-06-12 20:42:00 +01:00
Edwin Brady
19cb2681be Only fully normalise fromInteger on LHS
This reduces surprising undefined name errors on the RHS, as noted in
issue #1541
2021-06-12 14:23:25 +01:00
Edwin Brady
2cf0caefa6
Merge pull request #1539 from edwinb/fix1537
Properly normalise constants on LHS
2021-06-11 13:52:21 +01:00
Edwin Brady
06f69ba177 Fix test output
Because it relies on the source file that I've just fixed for the
linter. I think I've now spent more time pleasing the linter than fixing
the actual bug...
2021-06-11 13:02:38 +01:00
Edwin Brady
f923c3677d Please the linter again 2021-06-11 12:46:08 +01:00
Edwin Brady
38bdbfba84 Please the linter
I still don't think it should be looking in test sources. One day I'll
fix this.
2021-06-11 12:43:34 +01:00
Edwin Brady
663a8381f4 Properly normalise constants on LHS
We need to fully evaluate, not just the public export names, otherwise
we don't pattern match properly and potentially generate catch all
patterns we don't mean.

Fixes #1537
2021-06-11 12:37:45 +01:00
Fabián Heredia Montiel
0df331690a [cleanup] Remove Libraries.Data.Bool.Extra 2021-06-10 08:29:49 -05:00
Fabián Heredia Montiel
2061982699 [cleanup] Remove half of Libraries.Data.List1 2021-06-10 08:29:49 -05:00
Edwin Brady
ec1e7c0db6
Merge pull request #1533 from edwinb/normalise-tweaks
A couple more performance improvements
2021-06-10 13:54:23 +01:00
Edwin Brady
4a0970731e vars can be erased in evalLocal
A small thing, but no need to do that check since we can get it from
locs.
2021-06-10 13:05:28 +01:00
Edwin Brady
a75887ffa6 Update error018 test output 2021-06-10 12:42:54 +01:00
Edwin Brady
18c7e2c4da Merge github.com:idris-lang/Idris2 into normalise-tweaks 2021-06-10 12:22:02 +01:00
Edwin Brady
7d235272e3 Remove redundant converstion checks in Pi types
We've already checked argument and scope types, so only need to check
mulitplicities. This saves a lot of repetition when checking lambdas.
2021-06-10 12:19:41 +01:00
Edwin Brady
a2815506a8 Remove unused 'useMetas' field
This used to be a way for checking for cycles in metavariables, but we
do a proper occurs check now so no longer needed.
2021-06-09 14:37:55 +01:00
CodingCellist
abd5432885
[ fix ] indentation of impossible clauses (#1520) 2021-06-08 17:03:06 +01:00
Robert Wright
aa94dd2351 Add RefC Char pattern matching support 2021-06-07 15:15:37 +01:00
Edwin Brady
f3a44fb240
Merge pull request #1505 from edwinb/conversion-shortcut
Add a 'shortcut' to conversion check
2021-06-05 20:02:58 +01:00
Edwin Brady
d12abbdcb5 Add a 'shortcut' to conversion check
This is an approximate check of arguments - if we can find an argument
that differs at the head, there's no point in checking further. This can
be a significant shortcut when conversion checking two large terms that
only differ very slightly, as it saves checking big arguments
unnecessarily.
2021-06-05 19:02:56 +01:00
Ruslan Feizerakhmanov
7aee7c9b7c
[ new ] --install-with-src; refactoring around FCs (#1450)
Why:

* To implement robust cross-project go-to-definition in LSP
  i.e you can jump to definition of any global name coming
  from library dependencies, as well as from the local project files.

What it does:

*  Modify `FC`s to carry `ModuleIdent` for .idr sources,
   file name for .ipkg sources or nothing for interactive runs.

*  Add `--install-with-src` to install the source code alongside
   the ttc binaries. The source is installed into the same directory
   as the corresponding ttc file. Installed sources are made read-only.

*  As we install the sources pinned to the related ttc files we gain
   the versioning of sources for free.
2021-06-05 12:53:22 +01:00
Stefan Höck
baa6051d69
[ fix ] use twos complement truncation for signed ints (#1471) 2021-06-04 10:35:07 +01:00
Edwin Brady
48f3825266
Merge pull request #1501 from edwinb/hash-fix
Read import hashes correctly
2021-06-03 23:13:10 +01:00
Edwin Brady
5fa272b8bf Read import hashes correctly
Need to use the 8 byte version of Ints for the shortcut version of
reading TTCs too, otherwise we'll read the wrong hash and build things
unnecessarily.
2021-06-03 21:57:10 +01:00
G. Allais
9e7625e613
[ log ] more readable output for elab.ambiguous (#1500) 2021-06-03 18:19:08 +01:00
Johann Rudloff
18e15e2261 [ fix ] Cast CLOCKS_PER_SEC to float before division
The cast to float needs to happen before the division, otherwise integer
division will be performed, and as a result `CLOCKS_PER_NSEC` will
always be 0 if `CLOCKS_PER_SEC` < `NSEC_PER_SEC`.
2021-06-03 17:36:11 +01:00
Denis Buzdalov
2a4197e909
[ doc ] Some documentation on := syntax of let bindings (#1487)
Co-authored-by: Guillaume ALLAIS <guillaume.allais@ens-lyon.org>
2021-06-03 16:49:31 +01:00
Edwin Brady
5aba3b475a
Merge pull request #1499 from edwinb/ambig-lambda
Small pruning fix
2021-06-03 16:48:54 +01:00
Edwin Brady
4a193b3cfd Small pruning fix
Check for lambdas when checking if a type might fit for an ambiguous
name.
2021-06-03 16:10:35 +01:00
G. Allais
c5b10f0b52
[ doc ] for the linear pair constructor (#1492)
Co-authored-by: Mathew Polzin <matt.polzin@gmail.com>
2021-06-03 13:04:56 +01:00
madman-bob
98d67499db
RefC Integer Support (#1480)
* Add utility functions to treat All as a heterogeneous container
* Distinguish RefC Int and Bits types
* Change RefC Integers to be arbitrary precision
* Add RefC Bits maths operations
* Make RefC div and mod Euclidean
* Add RefC bit-ops tests
* Add RefC integer comparison tests
* Add RefC IntN support
2021-06-03 10:44:42 +01:00