Changeset dd3576b for libcfa/src


Ignore:
Timestamp:
Feb 25, 2023, 8:12:47 AM (22 months ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, ast-experimental, master
Children:
b1ad41f
Parents:
f2a1cd2
Message:

update from old to new trait syntax using forall

Location:
libcfa/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/concurrency/mutex_stmt.hfa

    rf2a1cd2 rdd3576b  
    44//-----------------------------------------------------------------------------
    55// is_lock
    6 trait is_lock(L & | sized(L)) {
     6forall(L & | sized(L))
     7trait is_lock {
    78        // For acquiring a lock
    89        void lock( L & );
  • libcfa/src/vec/vec.hfa

    rf2a1cd2 rdd3576b  
    1818#include <math.hfa>
    1919
    20 trait fromint(T) {
     20forall(T)
     21trait fromint {
    2122    void ?{}(T&, int);
    2223};
    23 trait zeroinit(T) {
     24forall(T)
     25trait zeroinit {
    2426    void ?{}(T&, zero_t);
    2527};
    26 trait zero_assign(T) {
     28forall(T)
     29trait zero_assign {
    2730    T ?=?(T&, zero_t);
    2831};
    29 trait subtract(T) {
     32forall(T)
     33trait subtract {
    3034    T ?-?(T, T);
    3135};
    32 trait negate(T) {
     36forall(T)
     37trait negate {
    3338    T -?(T);
    3439};
    35 trait add(T) {
     40forall(T)
     41trait add {
    3642    T ?+?(T, T);
    3743};
    38 trait multiply(T) {
     44forall(T)
     45trait multiply {
    3946    T ?*?(T, T);
    4047};
    41 trait divide(T) {
     48forall(T)
     49trait divide {
    4250    T ?/?(T, T);
    4351};
    44 trait lessthan(T) {
     52forall(T)
     53trait lessthan {
    4554    int ?<?(T, T);
    4655};
    47 trait equality(T) {
     56forall(T)
     57trait equality {
    4858    int ?==?(T, T);
    4959};
    50 trait sqrt(T) {
     60forall(T)
     61trait sqrt {
    5162    T sqrt(T);
    5263};
Note: See TracChangeset for help on using the changeset viewer.