Commit graph

70 commits

Author SHA1 Message Date
Henrik Tjäder
a5795a8f45 Remove keyword single for all tests 2021-03-03 08:55:19 +01:00
Jorge Aparicio
31b392fe3a CI: replace compiletest-rs with trybuild
We use compiletest to run compile-fail tests but compiletest depends on compiler
internals so it breaks every now and then and requires nightly. With trybuild we
can also run compile-fail tests but it works on stable and it already has
reached version 1.0
2019-11-06 19:05:37 -05:00
Jorge Aparicio
f49bd0a7f5 drop the "multi" test 2019-08-21 10:56:59 +02:00
Jorge Aparicio
0e146f8d11 adapt to changes in rtfm-syntax 2019-08-20 15:17:37 +02:00
Jorge Aparicio
81275bfa4f rtfm-syntax refactor + heterogeneous multi-core support 2019-06-13 23:56:59 +02:00
Jorge Aparicio
0fb2726e6c remove unused check
that was added in #140 but it's no longer required
2019-05-21 14:43:05 +02:00
Jorge Aparicio
d538f5b17c test RFC 147 2019-05-01 20:49:25 +02:00
Jorge Aparicio
d0aaa2a805 update compile-fail tests 2019-05-01 20:49:25 +02:00
Jorge Aparicio
d2fb62f729 update compile-pass tests 2019-05-01 20:49:25 +02:00
Jorge Aparicio
aa7eec0299 check task priority at compile time
before we were checking the priority at runtime. The compile time error message
when the priority is too high is kind of awful though.
2019-04-16 23:04:24 +02:00
Jorge Aparicio
a233808280 fix warnings in cpass test 2019-02-26 23:22:34 +01:00
Jorge Aparicio
72f0cc505a make cfail test actually fail 2019-02-26 23:22:34 +01:00
Jorge Aparicio
c749979c45 add some tests 2019-02-26 23:22:34 +01:00
Jorge Aparicio
73529ea650 reject duplicate arguments in #[interrupt] and #[exception]
This program was being accepted:

``` rust
 #[task(
    capacity = 1,
    capacity = 2,
    priority = 1,
    priority = 2,
)]
fn foo() {}
```

now it will trigger a compiler error
2019-02-23 22:35:29 +01:00
Jorge Aparicio
7ce052be37 cargo fmt 2019-02-16 00:26:07 +01:00
Jorge Aparicio
89c922079e update examples and tests 2019-02-12 15:08:46 +01:00
Jorge Aparicio
557a51ede1 forbid early returns in init 2019-02-12 11:07:15 +01:00
Jorge Aparicio
8e9a91d0b0 properly handle #[cfg] (conditional compilation) on tasks 2018-12-16 19:10:36 +01:00
Jorge Aparicio
4345c10596 properly handle #[cfg] (conditional compilation) on resources 2018-12-16 18:37:36 +01:00
Jorge Aparicio
3413d8d7e8 remove no longer necessary feature gates 2018-12-15 19:08:32 +01:00
Jorge Aparicio
22d758ddac fix codegen 2018-11-04 19:46:49 +01:00
Jorge Aparicio
c631049efc v0.4.0
closes #32
closes #33
2018-11-03 17:16:55 +01:00
Jorge Aparicio
abca829926 more fixes 2018-08-24 16:31:04 +02:00
Jorge Aparicio
efca108103 cargo fmt 2018-04-16 21:32:52 +02:00
Jorge Aparicio
7fdf16eab9 update parser
closes #69

this doesn't change functionality per se but improves diagnostics in some cases. Some hard errors
have becomes warnings, for example: when `resources` is empty, or when `idle.path` is set to the
default `idle` path.
2018-04-16 21:32:29 +02:00
Jorge Aparicio
d30bdcb096 safe &'static mut references via init.resources 2017-12-09 17:17:56 +01:00
Jorge Aparicio
a6dd004113 implement the Resource trait for owned resources
this unbreaks the "generics" example
2017-12-09 17:17:56 +01:00
Jorge Aparicio
62c5c1ae43 make resource proxies not Sync 2017-12-09 16:13:22 +01:00
Jorge Aparicio
8f23fdc934 deny warnings and unsafe code in tests and examples 2017-12-09 15:12:42 +01:00
Jorge Aparicio
9865a7246d make resource proxies !Send 2017-12-09 15:10:29 +01:00
Jorge Aparicio
79e2b7dc2e rename LateResourceValues to LateResources 2017-12-09 13:20:41 +01:00
Jorge Aparicio
8e523d036c fix cfail tests 2017-12-08 13:28:27 +01:00
Jorge Aparicio
e90cf07dd6 fix ci 2017-11-22 09:40:36 +01:00
Jonas Schievink
be1a27ccf9 Add cfail test for late resources 2017-09-22 18:21:12 +02:00
Jonas Schievink
b1777ebd68 Fix warning in wrong-threshold cfail test 2017-09-22 13:46:30 +02:00
Jonas Schievink
21d1f6b9ad Don't use deprecated method to create compiletest config 2017-09-22 13:46:05 +02:00
Jorge Aparicio
271df39bdb Send-ness check is now in rtfm-core 2017-07-27 21:30:24 -05:00
Jorge Aparicio
d396da5950 make task.$T.enabled optional
and move the logic that differentiates interrupts from exceptions from the crate
to the procedural macro logic
2017-07-27 17:08:42 -05:00
Jorge Aparicio
aa22494549 update tests and examples
with task! gone 3 types of errors / gotchas have been eliminated 🎉
2017-07-27 11:40:15 -05:00
Jorge Aparicio
a14b0121b7 add another duplicated-handler cfail test 2017-07-24 22:52:12 -05:00
Jorge Aparicio
4139b47d4b add cfail test: borrow can't escape critical sections 2017-07-23 22:18:44 -05:00
Jorge Aparicio
6ea9cda663 update cfail tests 2017-07-23 20:51:58 -05:00
Jorge Aparicio
23425f2f06 more cfail tests 2017-07-20 16:16:40 -05:00
Jorge Aparicio
97a7e38db7 tasks / idle have exclusive access to Threshold, but do not own the token 2017-07-18 20:03:22 -05:00
Jorge Aparicio
1f1cf84ab4 add cfail tests 2017-07-18 15:14:39 -05:00
Jorge Aparicio
86a360a396 rtfm! macro take 2 2017-07-04 11:26:11 -05:00
Jorge Aparicio
c1a0f8173a require Resource protected data to be Send, make tokens !Send 2017-05-08 13:25:20 -05:00
Jorge Aparicio
fc4cb7d472 replace the ceiling token with a preemption threshold token 2017-05-08 12:05:42 -05:00
Jorge Aparicio
e2bde8d21a make the ceiling part of the task signature
remove the P.as_ceiling method
2017-04-27 19:28:27 -05:00
Jorge Aparicio
aa0347e36c fix cfail tests 2017-04-25 21:55:11 -05:00