Commit Graph

475 Commits

Author SHA1 Message Date
Niklas Larsson
473b8ee740 Windows test fixes
Translate node error codes
Strip 'b' from flags
Simplify directory wrangling in chez016
2021-04-12 18:47:57 +02:00
Raoul Hidalgo Charman
1211f860b6
Fix issues with use of unix sockets (#1284)
This change adds logic to set up sockaddr correctly for connect and
bind, handles the AF_UNIX case for getSockAddr and expands the existing
test to cover unix sockets.
2021-04-12 11:22:45 +01:00
John Mager
c3ff63ae5f Use absolute path to pass around Idris executable
Rather than tracking how far we are from the project root in the various
Makefile commands, it's much easier to reference the build target with
with an absolute path.
2021-04-11 20:52:36 +01:00
Sören Tempel
c725b11c89 Flush standard out after writing prompt to it
On Unix-like operating systems stdio.h is usually line-buffered. As
putStr uses fputs(3) from stdio.h internally, output will be written to
standard out after a newline character is written to the buffer. Since
the prompt does not contain a newline, it will only be written to
standard output after the user presses return. I encountered this issue
on Alpine Linux which uses musl libc (instead of glibc). However, I
believe this issue is likely also reproducible with glibc. This commit
fixes this issue by flushing standard output after writing the prompt to
it. Surprisingly, `src/Idris/IDEMode/REPL.idr` already does this
correctly, `src/Idris/REPL.idr` does not though.
2021-04-09 15:17:00 +01:00
G. Allais
b7bdd0a99f
Various improvements (#1286) 2021-04-09 13:02:37 +01:00
Stefan Höck
61c43e5337
[ new ] Add Bifoldable and Bitraversable interfaces to Prelude (#1265) 2021-04-08 17:25:37 +01:00
Ohad Kammar
b65907f770
Support Multi-declarations (#1280) 2021-04-07 12:21:17 +01:00
Kamiλ Shakirov
2ac4bea220
[ install ] Check if 'realpath' exists for Chez and Racket backends (#1210) 2021-04-06 15:42:04 +01:00
Mathew Polzin
178f26ec17
[ re #1162 ] Test without install (#1240)
Co-authored-by: Guillaume ALLAIS <guillaume.allais@ens-lyon.org>
2021-04-05 11:27:56 +01:00
Edwin Brady
12f40f538f Use correct multiplicity in scope of lets
The scope should be checked at the same multiplicity as the enclosing
expression.
2021-04-04 18:10:34 +01:00
Kamil Shakirov
b27001136b [ tests ] Ignore test artifacts 2021-04-01 10:06:14 +01:00
Guillaume ALLAIS
99b87c8156 [ fix #1248 ] Bring qualified names back for data & record types 2021-03-31 23:17:53 +01:00
Atomotron
a1e7221c32
[ fix #1200 ] Switch scheme backend to flonum functions (#1203)
Co-authored-by: Guillaume ALLAIS <guillaume.allais@ens-lyon.org>
2021-03-31 23:17:41 +01:00
Zoe Stafford
f255026d1b
[ fix #1220 ] Update arity of constuctors to reflect erased args (#1225) 2021-03-29 15:08:06 +01:00
G. Allais
238eb62da6
[ fix #1230 ] Better error messages for out-of-scope identifiers (#1233) 2021-03-29 10:45:48 +01:00
CodingCellist
ec77ad21ab
[ re #1185 ] Add primitive for obtaining number of processors (#1209)
Co-authored-by: Guillaume ALLAIS <guillaume.allais@ens-lyon.org>
2021-03-26 18:27:25 +00:00
Guillaume ALLAIS
2df49ebdd4 [ fix #1224 ] moduleIdent must be capitalised 2021-03-25 15:59:46 +00:00
Guillaume ALLAIS
00929deed6 [ cosmetic ] nicer error messages for uncaught exceptions 2021-03-25 15:59:46 +00:00
Denis Buzdalov
8abd60535b [ fix ] Ability for data types to be operators was restored 2021-03-25 14:16:47 +00:00
G. Allais
97fb5d7b94
[ fix #893 ] proof gadget for with clauses (#1222) 2021-03-25 10:02:06 +00:00
G. Allais
21f2913527
[ fix #710 ] Enforce assumptions about capitalised idents (#1207)
Given we keep getting tripped up by this, here we go:

* Namespaces
* Data names
* Record names
* Data constructor names (except for operators)
* Record constructor names (except for operators)
* Interface constructor names (except for operators)
2021-03-22 13:22:52 +00:00
Guillaume ALLAIS
f600182999 [ close #31 ] test case for the issue 2021-03-18 10:38:48 +00:00
G. Allais
f959987a51
[ fix #834 ] Fix implicitsAs for local definitions (#1199) 2021-03-17 10:54:25 +00:00
André Videla
405c266b5e
[ refactor ] Multiline error report (#1155) 2021-03-16 14:10:45 +00:00
Stefan Höck
591797ebaf
[ new ] Support overloaded floating point literals (#1177) 2021-03-16 14:08:50 +00:00
Guillaume ALLAIS
80f8a0f8fe [ re #1185 ] add threads option to test runner 2021-03-16 14:03:46 +00:00
CodingCellist
89a84a34a4
Patch CVs and sleep in Racket (#1059) 2021-03-15 13:43:12 +00:00
Stefan Höck
1784593abb
[ new ] Applicative and Monad for Pair (#1188) 2021-03-15 13:42:04 +00:00
Matúš Tejiščák
f4a790ded4
Identify prefix and postfix record projections (#1183)
`.proj` and `proj` are identically defined but separate functions.
This patch fixes it by defining `.proj` only once, and adding `proj = (.proj)`
for every projection.
2021-03-15 13:40:13 +00:00
Raoul Hidalgo Charman
3e85e23638
Namespace checks for resugaring (#1161)
This avoids resugaring to the wrong type when there are user defined
symbols which conflicts with builtins such as Pair.

Changed the test linear002 which was relying on this behaviour for a
user defined Unit.

Fixes #634.
2021-03-15 13:34:54 +00:00
Michael Messer
d08c0c78b3
Change :doc to use PTerm instead of Name (#1178) 2021-03-12 09:46:46 +00:00
Edwin Brady
17cdc7fa88
Merge pull request #1171 from edwinb/fix1163
Correct multiplicities when checking Pi binders
2021-03-09 18:36:08 +00:00
Mathew Polzin
06586d401a
Add a test package to the Idris 2 project (#1162) 2021-03-09 18:27:05 +00:00
Edwin Brady
04a0f5001f Correct multiplicities when checking Pi binders
We've always just used 0, which isn't correct if the function is going
to be used in a runtime pattern match. Now calculate correctly so that
we're explicit about which type level variables are used at runtime.

This might cause some programs to fail to compile, if they use functions
that calculate Pi types. The solution is to make those functions
explicitly 0 multiplicity. If that doesn't work, you may have been
accidentally trying to use compile-time only data at run time!

Fixes #1163
2021-03-09 17:23:05 +00:00
Ruslan Feizerahmanov
50c60185a7
[ auto ] Ignore hidden names in Core.Context.getSearchData (#1143)
Co-authored-by: Guillaume ALLAIS <guillaume.allais@ens-lyon.org>
2021-03-09 14:13:29 +00:00
Stefan Höck
8d4321eb9a
Add Data.Bits to base (#1033) 2021-03-04 20:59:56 +00:00
Stefan Höck
4c7d0db4bc
[ fix #1148 ] Support hyphenated package names (#1151) 2021-03-04 19:09:15 +00:00
Edwin Brady
c9de4d9f9f Remove more trailing whitespace 2021-03-03 14:36:33 +00:00
Edwin Brady
6a29fab245 Remove trailing whitespace in tests
Keep the linter happy
2021-03-03 13:55:30 +00:00
Edwin Brady
6887a5f95f Record local hints in delayed elaborators
We might not have set up search problems yet when delaying an
elaborator, so we need to know what the local hints were at the point of
delay.
2021-03-03 13:49:32 +00:00
Edwin Brady
a00fc25109
Merge pull request #1146 from edwinb/fix1140
Check current holes only at end of elaboration
2021-03-01 20:51:46 +00:00
Edwin Brady
1d965627c9 Check current holes only at end of elaboration
Fixes #1140 - when checking holes were solved, we checked all of them,
but there may still be some open if there's a local definition.
2021-03-01 19:11:15 +00:00
G. Allais
cee7e38894
[ new ] Proof search from 'Applications of Applicative Proof Search' (#1093) 2021-03-01 08:29:43 +00:00
Edwin Brady
37cc095f7a Merge github.com:idris-lang/Idris2 into versions 2021-02-27 18:00:18 +00:00
Edwin Brady
1d8166b1b2 Version number constraints in 'depends' field
Now reporting an error if we can't find a package that satisfies the
constraints. The version number field can still be a string (as it used
to be) but will give a deprecation warning - and the old style version
string wasn't used anyway.

Version constraints can have an upper and/or lower bound, which can be
inclusive or not.
2021-02-27 17:58:52 +00:00
André Videla
aa27ccbdb6
Merge pull request #1097 from andylokandy/multiline
Implement multi-line string
2021-02-26 21:50:54 +00:00
G. Allais
59de5f1326
[ fix #762 ] Different case tree building strategy (#1125) 2021-02-26 09:33:07 +00:00
Andy Lok
01c5011653 improve error report 2021-02-25 20:14:26 +08:00
Andy Lok
5fed5c2b7a Merge branch 'master' of https://github.com/idris-lang/Idris2 into multiline 2021-02-25 19:52:42 +08:00
Andy Lok
8c23f5944b address comment 2021-02-25 18:43:42 +08:00