omit the DECLARE line in INLINE_SPEC clauses #70

Open
opened 2026-10-22 14:42:50 +02:00 by EatOreo · 1 comment
Owner

for instance in:

SPEC_INLINE  <{ 
    DECLARE _sumarray
      WITH a: val, sh : share, contents : list Z, size: Z
      ...
  }>
  unsigned sumarray(unsigned a[], int n) {
  ...

the "DECLARE _sumarray" can be infered from the function name

for instance in: ```c SPEC_INLINE <{ DECLARE _sumarray WITH a: val, sh : share, contents : list Z, size: Z ... }> unsigned sumarray(unsigned a[], int n) { ... ``` the "DECLARE _sumarray" can be infered from the function name
Owner

Why not go even further and remove separate _INLINE clauses❓

  /*@
    SPEC spec.v:specification <{
      WITH a: val, sh : share, contents : list Z, size: Z
    ...
    }>
  */
  unsigned sumarray(unsigned a[], int n) {
  ...
Why not go even further and remove separate `_INLINE` clauses❓ ``` /*@ SPEC spec.v:specification <{ WITH a: val, sh : share, contents : list Z, size: Z ... }> */ unsigned sumarray(unsigned a[], int n) { ... ```
marfavi self-assigned this 2026-10-30 13:59:19 +01:00
Sign in to join this conversation.
No milestone
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
code2rocq/crocq#70
No description provided.