I suspect this group is too comming to a slow gradual death...
one will watch as the average amount of posting steadily goes downward.
and one can wonder: maybe I am just impatient?...
but, then I suspect, it is like gradually all of usenet is gradually going
dry, slowly but surely, the posters and the traffic go away...
and one can sit and idly remember the times where there were more posters,
and where one could have interesting conversations...
and, for all it matters, something to make this post somehow relevant
(extension tokens for my compiler, mostly so I can potentially later use
them for funky compiler-specific syntax extensions...):
----
I will define some amount of extension tokens and syntax, which should
hopefully not conflict with other tokens in C.
Braces:
<. .> {. .}
[. .] (. .)
#< > #{ }
#[ ] #( )
#<. .> #{. .}
#[. .] #(. .)
Operators:
+. -. *. /.
%. &. |. ^.
..+ .- .* ./
..% .& .| .^
~. !. .~ .!
...
or, something else, good old vectors half-assedly immitating glsl...
----
#include <stdio.h>
#include <complex.h>
#include <vecnf.h>
int bscc_main()
{
double _Complex ci, cj;
quat p, q, r;
vec3 u, v, w;
vec3 a, b, c;
float x, y, z;
#if 1
u=vec3(1,0,0);
v=vec3(0,1,0);
w=u%v;
// printf("%f %f %f\n", w.x, w.y, w.z);
printf("I %f %f %f %f\n", u.x, u.y, u.z, u.w);
printf("J %f %f %f %f\n", v.x, v.y, v.z, v.w);
printf("K %f %f %f %f\n", w.x, w.y, w.z, w.w);
a=vec3(3,4,5);
printf("A %f %f %f %f\n", a.x, a.y, a.z, a.w);
x=1; y=2; z=3;
x=a^u;
y=a^v;
z=a^w;
printf("%f %f %f\n", x, y, z);
ci=1+2i;
cj=ci*ci;
printf("%f %f\n", creal(ci), cimag(ci));
printf("%f %f\n", creal(cj), cimag(cj));
#endif
p=quat(3,1,0,0);
q=quat(0,5,1,-2);
r=p*q;
// r=q*p;
// p=quat(1,2,0,0);
// q=quat(1,2,0,0);
// r=p*q;
// r=qlerp(p, q, 0.5);
printf("P %g%+gi%+gj%+gk\n", p.w, p.x, p.y, p.z);
printf("Q %g%+gi%+gj%+gk\n", q.w, q.x, q.y, q.z);
printf("R %g%+gi%+gj%+gk\n", r.w, r.x, r.y, r.z);
return(0);
}
int main()
{
bscc_main();
}


|